it is two scripts an empty_queue.sh and a fill_queue.sh and a members script If you need intructions please tell me

1047 $  cat empty_queue.sh
#!/bin/bash

# a script to remove everyone in the members script located in the same directory as this file
# to the Q 3901
# can be called from a script

#Local/[EMAIL PROTECTED]
#Local/[EMAIL PROTECTED]
#Local/[EMAIL PROTECTED]

for wild in `/usr/sbin/asterisk -r -x "show queue 3901"| grep -a dynamic | awk '{ print $1 }'`;
        do
        /usr/sbin/asterisk -r -x "remove queue member "$wild" from 3901"| grep -a interface;
        done

1048 $  cat fill_queue.sh
#!/bin/bash

# a script to add everyone in the members script located in the same directory as this file
# to the Q 3901
# can be called from a script

#Local/[EMAIL PROTECTED]
#Local/[EMAIL PROTECTED]
#Local/[EMAIL PROTECTED]

for wild in `cat /home/cmayfield/members `;
        do
        /usr/sbin/asterisk -r -x "add queue member "$wild" to 3901"| grep -a interface;
        done

1049 $  cat members
Local/[EMAIL PROTECTED]
Local/[EMAIL PROTECTED]

1050 $  crontab -l
#at 8:1 and 8:11 it will fill the queue and it is nondistructive
1,11     8       *       *       1-5       sh /home/cmayfield/fill_queue.sh | mail -s "fill_queue" [EMAIL PROTECTED]
#at 5:31 and 5:36 it will empty the queue and it is nondistructive
31,36    17       *       *       1-5       sh /home/cmayfield/empty_queue.sh | mail -s "empty_queue" [EMAIL PROTECTED]

On 5/2/06, Tomislav Parčina <[EMAIL PROTECTED]> wrote:
In article < [EMAIL PROTECTED]>, [EMAIL PROTECTED] says...
> that is a nice function
> I use a cronjob to logout everyone each evening if anyone wants that script
> I would love to provide it.

Please send the script to the list.



--
Tomislav Parčina
Lama Computers Split
Stinice 12, 21000 Split
Tel.: +385(21)495148
SIP: [EMAIL PROTECTED]
e-mail: tparcina#lama.hr
http://www.lama.hr
_______________________________________________
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users



--
$15.95/Month DreamHost Hosting SALE
60 GB Disk Storage, 1.6 TB Transfer
Transfer Increases 16 GB Weekly
http://www.dreamhost.com/r.cgi?ap0ught/shared/
Use discount code caralena for $40 off all these low prices
_______________________________________________
--Bandwidth and Colocation provided by Easynews.com --

Asterisk-Users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Reply via email to