From owner-freebsd-questions Tue Feb 16 9:34:18 1999 Received: from ns.clientlogic.com (ns.clientlogic.com [207.51.66.75]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id JAA13734 for ; Tue, 16 Feb 1999 09:34:13 -0800 (PST) (envelope-from ChrisMic@clientlogic.com) Received: by site0s1 with Internet Mail Service (5.5.2448.0) id ; Tue, 16 Feb 1999 12:35:21 -0500 Message-ID: <6C37EE640B78D2118D2F00A0C90FCB441A5EF8@site2s1> From: Christopher Michaels To: "'Sean J. Schluntz'" , FreeBSD Questions Subject: RE: Help with user ppp and launching a script Date: Tue, 16 Feb 1999 12:34:45 -0500 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2448.0) Content-Type: text/plain Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG I'm not too sure about answering 100% of your question, but you should be able to do something along the lines of the following. #1 in /etc/ppp/ you can have a file called ppp.linkup. Just add a section for your isp with the same name as your section in ppp.conf #2 i suppose you could write a script that parses the output of the nslookup or host commands and then uses the hostname -s command. #3 then if you kill -HUP sendmail to reread it's configuration it MAY pickup the different hostname. It all sounds good on paper but honestly don't know if it'll work in practice. Hopefully this will put you on the right track, or at the very least someone else on the list will add more info to this posting. -Chris > -----Original Message----- > From: Sean J. Schluntz [SMTP:schluntz@pacbell.net] > Sent: Tuesday, February 16, 1999 12:13 PM > To: FreeBSD Questions > Subject: Help with user ppp and launching a script > > Is there any way to launch a script from the user ppp after it connects? > Here's my problem: > > I dial in to PacBell on an ISDN line. It an auto dial from one of the > computers in my house so it can go up and down depending on when my wife, > daughter or my self are using it. The dialing and the channeling of my > vpn to the one IP address on the FreeBSD box (v2.2.6) all work great. > > The problem is that when something like sendmail tries to send out a > message, some of the sites it tries to send to refuse connection because > it says "Hi I'm blaa.org" (my internal domain) and the receiving server > says "Can't resolve you, *click*). > > What I need to do is have a script run from PPP automatically that when > the connection is make I can do a reverse look up on the IP address > assigned by PacBell (changes almost every time) and then set my computer > name based on that information (the then bounce sendmail so it will > recognize the change.) > > Any idea on how I can accomplish this? Thanks! Please reply directly as > I am not on the list. > > -Sean > > --- > Sean J. Schluntz schluntz@agames.com > Sr. Office Systems Administrator 408-434-5804 > Atari Games Corporation http://www.agames.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message