Mailing List Message #99999
From: Ejaz <>
Subject: RE: removing commungate mail boxes
Date: Fri, 30 Apr 2010 06:42:07 -0700
To: <CGatePro>
X-Mailer: Microsoft Office Outlook 11



From: Ejaz []
Sent: Monday, April 26, 2010 9:32 PM
To: ''
Subject: removing commungate mail boxes


I am very new to the communigate pro,  I am trying to delete  some users from the communigate pro through CLI script , but I wont succeded, up on excuting  the script I got the following message,  so please any can help in this to fix the problem.



Here is the script,


/usr/bin perl –w

 use CLI;

my $CGServerAddress = '';  #redefine this value

my $Login = "Postmaster";

my $Password='xxxxx';  #put here the postmaster password   

#die "You should configure the script before you run it" if($Password eq '***');

my $cli = new CGP::CLI( { PeerAddr => $CGServerAddress,

                          PeerPort => 106,

                          login    => $Login,

                          password => $Password } )

   || die "*** Can't connect to CGPro via IMAP.\n";                                

$AccountList = $cli->ListAccounts('');

  foreach(keys %$AccountList) { print "$_\n";


  my $Domain = "xxxxx";

  if($cli->DeleteAccount("$AccountList\@$Domain")) {

    print "Account \"$AccountList\@$Domain\" deleted.\n";

  } else {

    print "Unable to delete \"$AccountList\@$Domain\": ".$cli->getErrMessage."\n";




--------------------------------------------------------------end ----------------------------------------------------------------------------------

Up on running the above, I have the following error appears ,

bash-3.00# ./delacc


Unable to delete "HASH(0x83a22e4)": Syntax Error


Unable to delete "HASH(0x83a22e4)": Syntax Error



This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
Subscribe (FEED) Subscribe (DIGEST) Subscribe (INDEX) Unsubscribe Mail to Listmaster