To send to large domains use these 2 batchs( addfwd & addfwd2all) :
you need to customize addfwd2all.bat to add your own domains (domains as on
your hdd :-)
place the two files at the root level of your imail drive
then run addfwd2all
ACHTUNG ! :   the batch will overwrite te previously placed file eaxh time
it run by example the night to update daily your new users
The next version will check if the file exist before copying ..

Enjoy :-)


1- ADDFWD.BAT
==================================================
echo on
rem this file must be placed in your user dir on imail server !
rem example: d:\imail\mydomain\users

rem changing to the right directory
%1
cd %2\%4\users
rem checking argument exist
IF aaa%1%2%3%4 EQU aaa GOTO ERROR

rem building userlist
dir /B /AD >dirici.txt

rem copy the source .fwd to each user directory
date /T >addfwd.%4.log
time /T >>addfwd.%4.log
FOR /F "eol= tokens=1,* delims=/" %%i in (dirici.txt) do echo
%%i>>addfwd.%4.log && copy %3 .\%%i >>addfwd.%4.log
date /T >>addfwd.%4.log
time /T >>addfwd.%4.log
GOTO END

:ERROR
echo no source file specified
echo please use syntax: [addfwd imaildrive imaildir fwdfile tragetdomain]

:END
cd\
echo that's all folks for more info or debugging see addfwd.log

==================================================
2. ADDFWD2ALL.BAT
==================================================
set addfwddrive=e:
set addfwddir=e:\imail
set addfwdfile=e:\test.fwd

call addfwd.bat %addfwddrive% %addfwddir% %addfwdfile% domain1
call addfwd.bat %addfwddrive% %addfwddir% %addfwdfile% domain2
rem ...

==================================================

these two batch are located (for me) at the root of my imail drive
i use these batch to update my 8 domains in 3/4 minutes (only 6000 users
...)

----- Original Message -----
From: Kelly Britt <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, May 05, 2000 3:13 PM
Subject: RE: [IMail Forum] creating all .Fwd files in your users dir


> How could we modify this in we use a large # of multiple domains with
nested
> users
> example
> d:\imail\domain1\users
> d:\imail\domain2\users
>
>
>
> > -----Original Message-----
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED]]On Behalf Of Guazzo
> > Jean-Jacques
> > Sent: Friday, May 05, 2000 4:32 AM
> > To: [EMAIL PROTECTED]
> > Subject: Re: [IMail Forum] creating all .Fwd files in your users dir
> >
> >
> > here i join a small batch who do the job for you
> > the batch copy a .fwd file to all your users dir
> > be quite! :
> > if you maked a rule to filter all mails containing ILOVEYOU in
> > the subject  and
> > send them to a mailbox called potentially_infected
> > and you add a potentially_infected.fwd file in your user dir to
> > forward you the
> > mail for inspection (with the batch ..:-)
> > dont forward to a user on the same domain as your users ! (the
> > rule will loop
> > the mail ...)
> >
> >
> > BATCH BEGIN
> > ==========================================================
> >
> > echo off
> > rem this file must be placed in your user dir on imail server !
> > rem example: d:\imail\mydomain\users
> >
> >
> > rem checking argument exist
> > IF aaa%1 EQU aaa GOTO ERROR
> >
> > rem building userlist based on directory only
> > dir /B /AD >dirici.txt
> >
> > rem copy the source .fwd file to each user directory
> > FOR /F "eol= tokens=1,* delims=/" %%i in (dirici.txt) do echo
> > %%i>>addfwd.log &&
> > copy %1 .\%%i >>addfwd.log
> > GOTO END
> >
> > :ERROR
> > cls
> > echo no source file specified
> > echo please use syntax: [addfwd sourcefile.fwd]
> >
> > :END
> > cls
> > echo that's all folks for more info or debugging see addfwd.log
> >
> > ==========================================================
> > BATCH END
> >
> > Please visit http://www.ipswitch.com/support/mailing-lists.html
> > to be removed from this list.
> >
>
> Please visit http://www.ipswitch.com/support/mailing-lists.html
> to be removed from this list.
>

Please visit http://www.ipswitch.com/support/mailing-lists.html 
to be removed from this list.

Reply via email to