Date: Sun, 16 Jul 2000 22:44:34 -0700 From: fred@timogen.com To: "Matthew Seaman" <m.seaman@infracaninophile.co.uk> Cc: <freebsd-questions@FreeBSD.ORG> Subject: Re: which script will be executed when the adsl IP up Message-ID: <003901bfefb2$2c480dc0$905aa53d@fred> References: <007201bfef6b$e615f100$7f05a8c0@fred> <20020714101710.GA25158@happy-idiot-talk.infracaninophi>
next in thread | previous in thread | raw e-mail | index | archive | help
Greate! Thanks. ----- Original Message ----- From: "Matthew Seaman" <m.seaman@infracaninophile.co.uk> To: <fred@timogen.com> Cc: <freebsd-questions@FreeBSD.ORG> 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, fred@timogen.com 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 majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?003901bfefb2$2c480dc0$905aa53d>