[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Fetchmail + cron + dialup



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Thu, Sep 30, 2004 at 12:57:00PM +0200, Robert Golovniov wrote:
> Hello,
> 
> What is the best way to configure fetchmail to regularly check for new 
> mail on a dialup account? I tried doing it with a simple cron job like 
> "pon && fetchmail && poff" but the last command for some reasons never 
> worked. I also tried running pppd in "on-demand" mode, but somehow this 
> did not work either. Is there a "normal" or "professional" way of doing 
> it? Many thanks!
> 
> -- 
>            -=Robert & Beata Golovniov | Lviv. Topolna-West=-
Hi Rob,
I have a small script that checks the machine in online before it runs
fetchmail. So the cron jobs runs constantly but fechmail only runs when
on line.
 #-------------------------------------------------------------------
 IP=$(/sbin/ifconfig ppp0 2>&1 |grep inet|cut -f2 -d:|cut -d' ' -f1)
 if [ $IP ]; then
 	# online
	fetchmail
 fi
 #------------------------------------------------------------------
 -kev
- -- 

        (__)
        (oo)
  /------\/
 / |    ||
*  /\---/\
   ~~   ~~
...."Have you mooed today?"...
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (GNU/Linux)

iD8DBQFBXFU4AWAAuqdWA9cRAlmJAKCJAYa5pfye3ZNhXZ6CBqCLzEzAYACdGYsn
iNeDWjl+Tqc24PvcrWe361U=
=U7CC
-----END PGP SIGNATURE-----



Reply to: