How can I get a list of all "account alias" ?

Discuss your pilot or production implementation with other Zimbra admins or our engineers.
sdrury
Advanced member
Advanced member
Posts: 163
Joined: Fri Sep 12, 2014 11:42 pm

How can I get a list of all "account alias" ?

Post by sdrury »

Phil, very helpful so money back guarantee not required!!
Thanks again.
Sean.
2234msallee
Posts: 16
Joined: Sat Sep 13, 2014 12:27 am

How can I get a list of all "account alias" ?

Post by 2234msallee »

Here is one more option, building on the same theme. To list just the distribution lists for one domain, and the members of each list:
for i in `zmprov gadl domain.com`; do echo ""; echo "$i:"; zmprov gdl $i | grep 'Forwarding' | awk '{print $2}'; done > aliases.txt
The output looks like:
list1@domain.com:

user1@domain.com

user2@domain.com
list2@domain.com:

user3@domain.com

user4@domain.com
2234msallee
Posts: 16
Joined: Sat Sep 13, 2014 12:27 am

How can I get a list of all "account alias" ?

Post by 2234msallee »

Can anyone recommend a way to take the output of the 'list aliases' commands suggested here, and format it into an HTML table? Or does Zimbra have some administrative web URL that can allow certain groups of users to view this information? Our users need to be able to look up who is on which distribution list.
nitendra
Posts: 1
Joined: Sat Sep 13, 2014 1:41 am

How can I get a list of all "account alias" ?

Post by nitendra »

ldapsearch -x -H ldapurl -b 'ou=people,dc=domain,dc=com' "zimbraMailAlias=*@domain" | grep mail: | cut -d" " -f2
User avatar
maumar
Outstanding Member
Outstanding Member
Posts: 390
Joined: Fri Sep 12, 2014 10:28 pm

Re: How can I get a list of all "account alias" ?

Post by maumar »

this is ok for mr

Code: Select all


zmprov  sa  -v '(|(objectClass=zimbraDistributionList)(objectClass=zimbraAccount))'  \
    | egrep '^(# name |# distributionList|zimbraMailAlias)'  \
    | cat -s   | \
    sed 's/^zimbraMailAlias:/               /; s/^# name /Mailbox: /; s/^cn: /Name: /; s/^# distributionList /MailingList: /' > /tmp/alias.list


Post Reply