Greate! Thanks.
----- Original Message ----- From: "Matthew Seaman" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Sunday, July 14, 2002 3:17 AM Subject: Re: which script will be executed when the adsl IP up > On Sun, Jul 16, 2000 at 02:21:54PM -0700, [EMAIL PROTECTED] wrote: > > > I have use the adsl to connect the internet. As the ppp link > > will be disconnect, I want the gateway the send me the new IPaddress > > to my mail box. Could u tell me, when the ADSL link is up, which > > scripts will be executed. > > > In linux that shoud be /etc/ppp/ip-up, I donnot know what is in > > FreeBSD. > > You can use the /etc/ppp/ppp.linkup and /etc/ppp/ppp.linkdown files to > cause commands to be executed when your link goes up or down. For > instance, assuming that your ppp.conf is based on the default version, > this ppp.linkup file will e-mail root an empty message with your new > IP number in the subject line: > > # > # Stuff to run when the PPP link comes up. > # > papchap: > !bg mail -s "PPP link up IP = MYADDR" root </dev/null > # > # That's All Folks! > # > > The special token "MYADDR" is replaced by the new IP number. The > ppp(8) man page has details of all such tokens in the description of > the `!bg' command in the extensive "PPP COMMAND LIST" section. > > Cheers, > > Matthew > > -- > Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks > Savill Way > Tel: +44 1628 476614 Marlow > Fax: +44 0870 0522645 Bucks., SL7 1TH UK > To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-questions" in the body of the message