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 04-27-2009, 06:13 AM
Senior Member
 
Posts: 55
Question Problem with COS

Hi all,

I create some COS to organize my site. Then, I had written a script to
update a distribution list by COS and I have added in the /etc/cron.weekly.
The script is below and the sintaxe is “update_list mycos”.

During my test the script runs perfect. Today when I verify the lists I saw
that my lists are wrong and I observed that in Admin GUI COS is empty
when I click in “Class of Service”, but in the right menu I can open my
six COS.

Why my COS hidden? How do I fix this? How do I verify the integrity of
COS? My script is in function of COS.

Best regards,
Bibo

#!/bin/sh
# You must be zimbra user to run this script.
#
CosType=$1
LIST=${CosType}-l@mydomain.br
ID=`zmprov gc ${CosType} | grep zimbraId: | awk '{ print $2 }'`
# remove all users from list
members=`zmprov gdl ${LIST} | grep Address | awk '{ print $2 }'`
for i in ${members}; do
zmprov rdlm ${LIST} ${i}
done
# update list
list=`zmprov sa zimbraMailStatus=enabled and zimbraAccountStatus=active and zimbraCOSid=${ID}`
for i in ${list}; do
zmprov adlm ${LIST} ${i}
done
Reply With Quote
  #2 (permalink)  
Old 04-27-2009, 08:23 AM
Senior Member
 
Posts: 55
Default

Hi,

I don´t understand why Admin GUI doesn´t show the COS.
But I identified the error in the script. This sintaxe below doesn´t work.

list=`zmprov sa zimbraMailStatus=enabled and zimbraAccountStatus=active and zimbraCOSid=${ID}`

How do I do sintaxe with "and" in zmprov command?

Best regards,
Bibo
Reply With Quote
  #3 (permalink)  
Old 10-20-2010, 09:34 AM
Junior Member
 
Posts: 6
Default

You just need to delet the "and" and the "=":

list=`zmprov sa zimbraMailStatus enabled zimbraAccountStatus active zimbraCOSid ${ID}`

As Zimbra user type "zmprov help" to know how tu use zmprov.
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.