Zimbra offers Open Source email server software and shared calendar for Linux and the Mac
Go Back   Zimbra :: Forums > Zimbra Collaboration Suite > Administrators

Welcome to the Zimbra :: Forums!
Welcome, if you would like to post a comment please register. We also encourage you to explore all things Zimbra with our team and members of the community.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 09-02-2009, 08:13 AM
Advanced Member
 
Posts: 204
Default Find accounts hidden in GAL

I'm trying to produce a list of accounts that have been hidden in the GAL. Can't find a way in the Admin interface, so I'm on the CLI. I know I can get the information with:

zmprov gaa -v

However, I want to only list accounts that are hidden from GAL. I can't simply pipe "grep 'zimbraHideInGal: TRUE'", since that just shows that line. Does anyone have some suggestions to how best to do this?
Reply With Quote
  #2 (permalink)  
Old 09-02-2009, 09:59 AM
Moderator
 
Posts: 1,554
Default

heres a quick and dirty way to do it

Code:
#!/bin/bash
for i in `zmprov gaa`
do
echo $i
zmprov ga $i | grep 'zimbraHideInGal: TRUE'
done
that will ech each account, and if it finds that attribute echo it below it so the output might look like

Code:
user1@domain.tld
user2@domain.tld
user3@domain.tld
zimbraHideInGal: TRUE
user4@domain.tld
useful if you're only hunting for a handful in a small account base. with a little work i'm sure you could use an if case to exclude the ones with false.
Reply With Quote
  #3 (permalink)  
Old 09-02-2009, 08:49 PM
Trained Alumni
 
Posts: 70
Default

You can do it with an LDAP search using zmprov which is a little less work.
Quote:
zmprov sa zimbraHideInGal="TRUE"
Additionally, in the admin interface you can enter
Quote:
(zimbraHideInGal="TRUE")
in the search field. When you do a search within ()'s it treats it as an LDAP search
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads

Why Join?

Registering let's you ask questions, makes it easier to search, displays any files attached to posts, and notifies you about replies.

blog.zimbra.com




 

SEO by vBSEO ©2011, Crawlability, Inc.