On 11/24/2010 07:57 AM, Sergio Minini (NETKEY) wrote:
Hi Eric, I can certainly use some help with that.
Maybe I can put it in the wiki after it.
Thanks!
-Sergio
On 11/24/2010 07:35 AM, Sergio Minini (NETKEY) wrote:
Hi list,
i have a "customer" who hasn't paid for several months.
I want to suspend/block all sending/checking for his domain, but still
accept mails for it.
I know i can do it on an account basis from vqadmin and check the
disable options for each account. Is there a way to do it for the whole
domain?
I also use spamdyke for blocking non locals and spam filtering.
Thanks for your tips and thoughts.
-Sergio
---------------------------------------------------------------------------------
I don't know of any domain controls for this per se.
I think it'd be fairly simple to write a script that would process each
account in a domain, and invoke /home/vpopmail/bin/vmoduser to make the
changes. Let us know if you need a hand with that.
This is off the cuff, and should be tested before running in production:
#!/bin/sh
# script to change settings for all users in a domain
# it'd be a nice enhancement to pass the domain as $1
domain=mydomain.com
vpmdir=/home/vpopmail
acctlist=$(find $vpmdir/domains/$domain -mindepth 1 -maxdepth 1 -type d)
for acctpath in $acctlist; do
account=${acctpath##*/}
address=$acco...@$domain
echo "changing $address"
$vpmdir/bin/vmoduser -p -s -w -i -r $address
done
Simpler than I thought. Might make a nice utility if were generalized a bit.
--
-Eric 'shubes'
---------------------------------------------------------------------------------
Qmailtoaster is sponsored by Vickers Consulting Group
(www.vickersconsulting.com)
Vickers Consulting Group offers Qmailtoaster support and installations.
If you need professional help with your setup, contact them today!
---------------------------------------------------------------------------------
Please visit qmailtoaster.com for the latest news, updates, and packages.
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]