it is two scripts an empty_queue.sh and a fill_queue.sh and a members script If you need intructions please tell me<br><br>1047 $ cat empty_queue.sh<br>#!/bin/bash<br><br># a script to remove everyone in the members script located in the same directory as this file
<br># to the Q 3901<br># can be called from a script<br><br>#Local/3201@from-internal<br>#Local/3288@from-internal<br>#Local/3204@from-internal<br><br>for wild in `/usr/sbin/asterisk -r -x "show queue 3901"| grep -a dynamic | awk '{ print $1 }'`;
<br> do<br> /usr/sbin/asterisk -r -x "remove queue member "$wild" from 3901"| grep -a interface;<br> done<br><br>1048 $ cat fill_queue.sh<br>#!/bin/bash<br><br># a script to add everyone in the members script located in the same directory as this file
<br># to the Q 3901<br># can be called from a script<br><br>#Local/3201@from-internal<br>#Local/3288@from-internal<br>#Local/3204@from-internal<br><br>for wild in `cat /home/cmayfield/members `;<br> do<br> /usr/sbin/asterisk -r -x "add queue member "$wild" to 3901"| grep -a interface;
<br> done<br><br>1049 $ cat members<br>Local/3204@from-internal<br>Local/3288@from-internal<br><br>1050 $ crontab -l<br>#at 8:1 and 8:11 it will fill the queue and it is nondistructive<br>1,11 8 * * 1-5 sh /home/cmayfield/fill_queue.sh | mail -s "fill_queue"
<a href="mailto:cmayfield@primary.net" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">cmayfield@primary.net</a><br>#at 5:31 and 5:36 it will empty the queue and it is nondistructive<br>31,36 17 * * 1-5 sh /home/cmayfield/empty_queue.sh | mail -s "empty_queue"
<a href="mailto:cmayfield@primary.net" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">cmayfield@primary.net</a><br><br><div><span class="gmail_quote">On 5/2/06, <b class="gmail_sendername">Tomislav Parčina
</b> <<a href="mailto:tparcina@lama.hr">tparcina@lama.hr</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">In article <
<a href="mailto:10fe83740604251430j7445d344x8c85d6cba7cb6761@mail.gmail.com">10fe83740604251430j7445d344x8c85d6cba7cb6761@mail.gmail.com</a>>, <a href="mailto:cmayfield@primary.net">cmayfield@primary.net</a> says...<br>
> that is a nice function<br>> I use a cronjob to logout everyone each evening if anyone wants that script<br>> I would love to provide it.<br><br>Please send the script to the list.<br><br><br><br>--<br>Tomislav Parčina
<br>Lama Computers Split<br>Stinice 12, 21000 Split<br>Tel.: +385(21)495148<br>SIP: <a href="mailto:tomo@pbx.lama.hr">tomo@pbx.lama.hr</a><br>e-mail: tparcina#lama.hr<br><a href="http://www.lama.hr">http://www.lama.hr</a>
<br>_______________________________________________<br>--Bandwidth and Colocation provided by <a href="http://Easynews.com">Easynews.com</a> --<br><br>Asterisk-Users mailing list<br>To UNSUBSCRIBE or update options visit:
<br> <a href="http://lists.digium.com/mailman/listinfo/asterisk-users">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br></blockquote></div><br><br clear="all"><br>-- <br>$15.95/Month DreamHost Hosting SALE
<br>60 GB Disk Storage, 1.6 TB Transfer<br>Transfer Increases 16 GB Weekly<br><a href="http://www.dreamhost.com/r.cgi?ap0ught/shared/">http://www.dreamhost.com/r.cgi?ap0ught/shared/</a><br>Use discount code caralena for $40 off all these low prices