User Reports: Difference between revisions
(Adding Templates: 4.5, Unsupported, Article Footer, and Category:Administration) |
No edit summary |
||
(One intermediate revision by one other user not shown) | |||
Line 1: | Line 1: | ||
{{ | {{Archive}}{{Unsupported}} | ||
{{Unsupported}} | {{Article Infobox|{{admin}}|||{{ZCS 4.5}}}}Zimbra doesn't seem to have good ways of counting users by COS or domains. I've written a couple of scripts to make that easier. | ||
Zimbra doesn't seem to have good ways of counting users by COS or domains. I've written a couple of scripts to make that easier. | |||
Be warned that these can take a long time to run if you have a lot of users | Be warned that these can take a long time to run if you have a lot of users | ||
Latest revision as of 17:28, 24 March 2015
- This is archive documentation, which means it is not supported or valid for recent versions of Zimbra Collaboration.
- This article is a Community contribution and may include unsupported customizations.
Article Information |
---|
This article applies to the following ZCS versions. |
Zimbra doesn't seem to have good ways of counting users by COS or domains. I've written a couple of scripts to make that easier. Be warned that these can take a long time to run if you have a lot of users
The following script will generate a report of total users in each COS. This may be useful for Zimbra customers who are billed based on accounts with different feature levels:
#!/bin/sh tmpfile=`mktemp` account_list=`zmprov gaa` for cos_name in `zmprov gac` ; do cos_id=`zmprov gc $cos_name | grep zimbraId | cut -f2 -d\ ` cos_count=0 for account in $account_list ; do account_cos_id=`zmprov ga $account | grep $cos_id | cut -f2 -d\ ` if [ "$account_cos_id" = "$cos_id" ] ; then let cos_count=cos_count+1 fi done echo "$cos_name has $cos_count accounts." >> $tmpfile done cat $tmpfile rm -f $tmpfile