Date: Fri, 27 Jul 2001 07:54:41 -0500 From: Mike Meyer <mwm@mired.org> To: Noah Dunker <ndunker@jccc.net>, dude@shell.schulte.org Cc: questions@freebsd.org Subject: RE: DHCP client IP Message-ID: <15201.25745.612595.527152@guru.mired.org> In-Reply-To: <6823823@toto.iv>
next in thread | previous in thread | raw e-mail | index | archive | help
Noah Dunker <ndunker@jccc.net> types: > Just in case... I forgot to explain how it works... > > It just uploads a file (by default, it's called ip.html) to a web-server > that you can FTP into. > > You can go there, and it'll show you the ifconfig information for your NIC, > so you know what it's IP address changed to. It would be better to use a dynamic DNS system. It's the same idea - your system tells a system at a known IP what it's IP is - but instead of putting it on an ftp server, you put it in a DNS server, so you can access things by name. If you don't care what the name is, take a look at <URL: http://www.dyndns.org/ >. <mike > > Noah Dunker > Systems Analyst/Technician > Johnson County Community College > > > ------------ > > I hacked a script called "setip" I found on freshmeat. It's meant for ppp > dialups. > > This works fine. put it in Cron to run every 5 minutes. > > make sure your .netrc file has the FTP information to FTP in with your > username and password. > > yes, it's really a hacked kludge, but it works for me! > > #!/usr/local/bin/bash > if [ `ifconfig ep0 | wc -l ` -gt 1 ] > then > if [ "`cat ~/.ipaddr`" != "`ifconfig ep0`" ] > then > date > ~/.ip.dat > ifconfig tun0 >> ~/.ip.dat > ifconfig tun0 > ~/.ipaddr > ftp host.mydomain.com << EOTEXT > /dev/null > lcd /home/myaccount > cd /home/myaccount/public_html > put .ip.dat ip.html > EOTEXT > echo "PUT" > fi > fi > > > > -----Original Message----- > From: J [mailto:dude@shell.schulte.org] > Sent: Thursday, July 26, 2001 4:32 PM > To: Jonathan Chen > Cc: questions@FreeBSD.ORG > Subject: Re: DHCP client IP > > > I think you got me wrong. The client works fine. The only problem is, i > cant use remote access on it because i dont know what it's IP address is. > That's why i was asking if there was a way to guess what the next IP > address would be. > > thanks again. > > _______________________________________________ > > /"\ ASCII Ribbon campaign against E-Mail > \ / in gratuitous HTML and Microsoft > X proprietary formats. > / \ > > > On Fri, 27 Jul 2001, Jonathan Chen wrote: > > Date: Fri, 27 Jul 2001 09:16:52 +1200 > From: Jonathan Chen <jonathan.chen@itouch.co.nz> > To: J <dude@shell.schulte.org> > Cc: questions@FreeBSD.ORG > Subject: Re: DHCP client IP > > On Thu, Jul 26, 2001 at 02:15:30PM -0500, J wrote: > > I've recently installed FreeBSD on one of the computers in my college's > > lab. All computers here are DHCP clients, and their IP addres is never > > static. Is there a way to predict the next IP address? Also, if the > > computer doesnt get logged off, will this prevent the IP address from > > regulating? Please cc: > > In /etc/rc.conf: > > ifconfig_xl0="DHCP" > > Change the xl0 to your NIC interface... > -- Mike Meyer <mwm@mired.org> http://www.mired.org/home/mwm/ Independent WWW/Perforce/FreeBSD/Unix consultant, email for more information. 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?15201.25745.612595.527152>