Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
04-05-2002, 09:22 AM
|
#1
|
Member
Registered: Apr 2002
Location: Clevedon, UK
Distribution: SUSE 8.2, 9.2, 10.0 OSS
Posts: 57
Rep:
|
Obtain IP when DHCP is down
Hope someone can help.
When a DHCP server is down, is it possible for a client machine to bypass the LONG delay in waiting for an IP and carry on and boot up. It currently takes about 2-3 minutes for it to work out that the DHCP server is not available.
I have a PC that has a DHCP server running that I sometimes don't want to turn on (it's upstairs), but just want to just go into my PC downstairs.
Sorry if this doesn't make sense, its a bit hard to explain.
|
|
|
04-05-2002, 10:00 AM
|
#2
|
Moderator
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417
|
well it naturally depends which dhcp client you are using. if you're on pump, you should edit (or create) an /etc/pump.conf containing a suitable timeout= line. check the manpage for more info. I've been trying to suss out quickly how to do it with dhcpcd, but the manpage doesn't mention a config file to edit. you can specify a timeout on a command line iwth the -t option. you might want to look at the /sbin/ifup script to find out what's going on. (the dhcp client will be called from inside there. in there there are options to use the dhcpcd timeout from a preset environment varible, but i'm not really sure where that's meant to have come from. you could always just hardcode the value inside that script, or i guess you could add it to /etc/rc.sysinit or something...
|
|
|
04-05-2002, 08:48 PM
|
#3
|
Member
Registered: Aug 2001
Location: Off the coast of Madadascar
Posts: 498
Rep:
|
Whats funny is by default Windows does a better job at downed DHCP servers by giving out it s -->RESERVED!<-- ip address 169.x.x.x
Strange ehh.
|
|
|
04-06-2002, 05:27 AM
|
#4
|
LQ Guru
Registered: Aug 2001
Location: Dublin, Ireland
Distribution: Slackware
Posts: 5,700
Rep:
|
Yeah, but the DOS based windows have to be rebooted to configure it with a static as its not really compliant with the RFC for dhcp, but really runs off of BOOTP. Also, you might want to change your /etc/sysconfig/network-scripts/ifcg-eth0 file and take it off dhcp. You can invoke the client from the command line easily enough with dhcpcd, or put that in rc.local, which runs last, and if you check the man page on dhcpcd, I'm pretty certain there's an option you can pass it to shorten the time-out wait period to something reasonable like 10 seconds instead of the default... 60 I think?
Cheers,
Finegan
|
|
|
04-06-2002, 06:00 AM
|
#5
|
Moderator
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417
|
i guess that'd be where the DHCP_TIMEOUT values go then, that are checked for by ifup.
|
|
|
04-06-2002, 06:05 AM
|
#6
|
LQ Guru
Registered: Aug 2001
Location: Dublin, Ireland
Distribution: Slackware
Posts: 5,700
Rep:
|
Quote:
Originally posted by acid_kewpie
i guess that'd be where the DHCP_TIMEOUT values go then, that are checked for by ifup.
|
<Begin Homer Slap>
Doh!
</End Homer Slap>
I knew there was a cute /etc/sysconfig script for it. I always duck using those. I gotta stop posting mixtures of the two.
Cheers,
Finegan
|
|
|
04-12-2002, 10:46 AM
|
#7
|
Member
Registered: Apr 2002
Location: Clevedon, UK
Distribution: SUSE 8.2, 9.2, 10.0 OSS
Posts: 57
Original Poster
Rep:
|
sorry, been away this week.
thanks everyone ... i'll try tinkering with a few settings this weekend (if i get chance) and let you know.

|
|
|
04-15-2002, 06:50 AM
|
#8
|
Member
Registered: Apr 2002
Location: Clevedon, UK
Distribution: SUSE 8.2, 9.2, 10.0 OSS
Posts: 57
Original Poster
Rep:
|
I first tried putting DHCP_TIMEOUT=10 in the ifcfg.eth0 file, but it had no effect.
I then had a browse at the /etc/rc.sysinit file (which I think is similar to the autoexec.bat / config.sys files), and I noticed a section dealing with DHCP. One line seemed to have options that are passed to the called DHCPCD command, so I added:
-t 10
to set a time-out of 10 seconds, and hey-presto it worked !!
Cool.
One quick ?, is there a similar command like WINIPCFG or IPCONFIG that I can run to check out the IP address in RHLinux?
Once again, thanks for all your help.
Andy
|
|
|
04-15-2002, 07:02 AM
|
#9
|
Senior Member
Registered: Dec 2001
Location: The Netherlands
Distribution: Ubuntu
Posts: 1,316
Rep:
|
Try ifconfig.
If you want to see all the information retrieved by the dhcpc then there should be a file in the /etc/dhcpc directory called dhcpcd-<interface>.info
The name depends on how things are configured but just look around and I'm sure you'll find it.
|
|
|
04-15-2002, 07:04 AM
|
#10
|
LQ Newbie
Registered: Apr 2002
Distribution: Mandrake 9.0 (at the moment)
Posts: 28
Rep:
|
ifconfig does a similar job to WINIPCFG or IPCONFIG on windows.
You can normally only run it as root though, and it does a load more stuff than either of the windows utils - so be careful!
Running it without command line arguments should be safe enough - it brings up a list of all your network adaptors, so on a typical machine it would bring up eth0, ppp0 (if you're dialed up to the net) and lo0 (the loopback adaptor) - and along with the list - you get all the info about each adaptor, including the IP address.
Enjoy!
Bry
|
|
|
04-16-2002, 03:25 AM
|
#11
|
Member
Registered: Apr 2002
Location: Clevedon, UK
Distribution: SUSE 8.2, 9.2, 10.0 OSS
Posts: 57
Original Poster
Rep:
|
Cheers guys.
|
|
|
All times are GMT -5. The time now is 07:20 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|