IP address is not getting assigned if I plugin the LAN cable after machine bootsup

IP address is not getting assigned if I plugin the LAN cable after machine bootsup

Post by santa19992.. » Mon, 18 Apr 2005 00:32:02



IP address is not getting assigned my Linux machine if I plugin the LAN
cable once machine bootsup (first machine booted, then plugged in the
LAN cable). If I plugin the cable first and rebooted the machine, then
the machine gets assigned IP address, what was the reason the IP
address not getting assigned in the first case. is there any problem
with my configuration?.

In case of Windows it works in above both cases, IP address gets
assigned whether I pluin the cable before or after machine boots up.

Thanks.

 
 
 

IP address is not getting assigned if I plugin the LAN cable after machine bootsup

Post by David Dorwar » Mon, 18 Apr 2005 00:47:46



> IP address is not getting assigned my Linux machine if I plugin the LAN
> cable once machine bootsup (first machine booted, then plugged in the
> LAN cable).

Then presumably you aren't running software the listens for a cable being
connected and then make a DHCP request.

http://www.stud.uni-hamburg.de/users/lennart/projects/ifplugd/#overview

Quote:> If I plugin the cable first and rebooted the machine, then
> the machine gets assigned IP address, what was the reason the IP
> address not getting assigned in the first case.

There was nothing available to assign an ip when the machine requested one.

--
David Dorward       <http://blog.dorward.me.uk/>   <http://dorward.me.uk/>
                     Home is where the ~/.bashrc is

 
 
 

IP address is not getting assigned if I plugin the LAN cable after machine bootsup

Post by James Knot » Mon, 18 Apr 2005 04:31:39



> IP address is not getting assigned my Linux machine if I plugin the LAN
> cable once machine bootsup (first machine booted, then plugged in the
> LAN cable). If I plugin the cable first and rebooted the machine, then
> the machine gets assigned IP address, what was the reason the IP
> address not getting assigned in the first case. is there any problem
> with my configuration?.

> In case of Windows it works in above both cases, IP address gets
> assigned whether I pluin the cable before or after machine boots up.

> Thanks.

I assume you're using dhcp.  If so, when the computer boots, it requests an
ip address from a dhcp server.  If the computer is not connected, it can't
get that address.  However, you can always restart the interface, to get
the address after connecting to the cable.   XP can detect when the cable
is connected and then request a dhcp address.  Some earlier versions of
Windows didn't.  In SuSE Linux, you can use Yast to configure the network
adapter to detect when it's connected and then activate it.
 
 
 

IP address is not getting assigned if I plugin the LAN cable after machine bootsup

Post by James Knot » Mon, 18 Apr 2005 05:19:25



> In case of Windows it works in above both cases, IP address gets
> assigned whether I pluin the cable before or after machine boots up.

Further on this:

As an experiment, instead of connecting that Windows box directly into the
router or wherever you're getting the IP from, try connecting it to a
switch, with nothing else plugged into it.  Then after a couple of minutes,
plug the switch into the router, and see if you now have an IP address.
You likely won't, because as soon as you plug into the switch, the computer
considers the NIC to be connected and then makes a dhcp request, which will
not be received by any dhcp server.  When the router is then plugged in
after that, there is no way of telling the computer, that the dhcp server
is now available.

 
 
 

IP address is not getting assigned if I plugin the LAN cable after machine bootsup

Post by Jim Berwic » Mon, 18 Apr 2005 10:59:11



Quote:> the machine gets assigned IP address, what was the reason the IP
> address not getting assigned in the first case. is there any problem
> with my configuration?.

The problem is nothing is telling your computer the cable is plugged in and
to try to get an address now.  You can force this by doing ifdown eth0
(assuming eth0 is your NIC), then ifup eth0.
 
 
 

IP address is not getting assigned if I plugin the LAN cable after machine bootsup

Post by Coenraad Loubse » Tue, 19 Apr 2005 21:20:34



> IP address is not getting assigned my Linux machine if I plugin the LAN
> cable once machine bootsup (first machine booted, then plugged in the
> LAN cable). If I plugin the cable first and rebooted the machine, then
> the machine gets assigned IP address, what was the reason the IP
> address not getting assigned in the first case. is there any problem
> with my configuration?.

> In case of Windows it works in above both cases, IP address gets
> assigned whether I pluin the cable before or after machine boots up.

> Thanks.

or
"rcnetwork reload"

or dhcp.. pump what theres this command to renew the dhcp address,,, can
never remember it

 
 
 

IP address is not getting assigned if I plugin the LAN cable after machine bootsup

Post by santa19992.. » Wed, 20 Apr 2005 02:24:45


Which Linux version detect automatic plugin and out just like Windows,
Please let me know, I am using RH 9.x presently, Is there any Linux
flavour out there to detect the Network cable plugin automatically?.
Thanks.
 
 
 

IP address is not getting assigned if I plugin the LAN cable after machine bootsup

Post by Unru » Wed, 20 Apr 2005 02:55:17



>Which Linux version detect automatic plugin and out just like Windows,
>Please let me know, I am using RH 9.x presently, Is there any Linux
>flavour out there to detect the Network cable plugin automatically?.
>Thanks.

No, there is nothing to detect. What you can do is to write a little cron
scrpit to test if the cable is in, and if the network is not configured to
configure it. That is probably what windows does.
 
 
 

IP address is not getting assigned if I plugin the LAN cable after machine bootsup

Post by Tauno Voipi » Wed, 20 Apr 2005 04:30:26



> Which Linux version detect automatic plugin and out just like Windows,
> Please let me know, I am using RH 9.x presently, Is there any Linux
> flavour out there to detect the Network cable plugin automatically?.
> Thanks.

You need the interface plug daemon. Google for 'ifplugd'.

HTH

--

Tauno Voipio
tauno voipio (at) iki fi

 
 
 

IP address is not getting assigned if I plugin the LAN cable after machine bootsup

Post by Coenraad Loubse » Thu, 21 Apr 2005 04:34:31




>>Which Linux version detect automatic plugin and out just like Windows,
>>Please let me know, I am using RH 9.x presently, Is there any Linux
>>flavour out there to detect the Network cable plugin automatically?.
>>Thanks.

> No, there is nothing to detect. What you can do is to write a little cron
> scrpit to test if the cable is in, and if the network is not configured to
> configure it. That is probably what windows does.

No I doubt it!

I am pretty damn sure there is a hardware call that detects if theres
connectivity or not. IE to see if the little light on the nic is on or not.

BTW ISNT IT ANNOYING THAT windows resets all network connections when
the cable connection is interrupted!? AAArgh!!!

AArgh!

AAAAaaargh!

Hate SOFTWARE

 
 
 

IP address is not getting assigned if I plugin the LAN cable after machine bootsup

Post by prg » Thu, 21 Apr 2005 05:13:57



> Which Linux version detect automatic plugin and out just like
Windows,
> Please let me know, I am using RH 9.x presently, Is there any Linux
> flavour out there to detect the Network cable plugin automatically?.

T.V.'s pointer is what you're looking for.

Mandrake/Mindiva?  Suse?  Non RPM distros?  Can't recall.

In any case, you can get ifplugd's rpm for RH9 here:
http://rpm.pbone.net/index.php3/stat/4/idpl/1771247/com/ifplugd-0.27-...

Get more info about ifpugd here:
http://www.stud.uni-hamburg.de/users/lennart/projects/ifplugd/

Note that:
[q]
It is primarily intended for usage with laptops.
[eq]

Now, if you really want "just like Windows", then Redmond has something
you'll be interested in;)

Last is mentioned because some Linux users/distros have expressed
"surprise" when it was installed on desktop/servers.  Don't recall what
the issues were/are.  Ie., be careful what you ask for;)

hth,
prg

 
 
 

1. Correct IP configuration for machine with dynamically-assigned IP address?

Hi,

I am using Linux 2.0.33 with ppp-2.3.5, and I am trying to unravel my
nightmarish network configuration. I used to have my hostname aliased to
the loopback address and everything seemed to work OK. Then I learnt
that this was a "bad thing" and so I tried to correct the issue - anyway
I'd like to resolve my hostname to my REAL IP addres when such a thing
is available. The problem now is that some of the network-aware daemons
such as lpd and pppd are now giving me errors.

lpd is flatly refusing to run - it reads my hostname, can't find an IP
address in the /etc/hosts file to match it and then quits. pppd is
working, but it is also adding strange messages to the syslog such as

Cannot determine ethernet address for proxy ARP

whatever that means - I don't HAVE any ethernet hardware so I don't see
why it is looking for anything remotely ethernet-related.  Sendmail is
also trying to resolve my hostname into an IP address.

There has to be a tidy solution to this - there must be lots of Linux
boxes out there that only network though ppp.
Can anyone help, please?

Cheers,
Chris.

2. Thread safety confusion pl help

3. Assigning a second IP address to am Ethernet card???

4. System info thro' commands

5. Getting a DHCP assigned IP Address at startup.

6. dcopserver don't start

7. Why I am getting two IP addresses when I connect to my work through VPN

8. Getting rcmd/rsh to work between SCO and Solaris

9. Cable Modem with 1 IP address to Home LAN HOW TO

10. PPP connection not assigning ip address & default route

11. dip can not get dynamic IP address assigned by annex server

12. Not assigned IP address with PPP

13. PPP Server not assigning IP addresses