Linux - NetworkingThis 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.
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.
My configuration includes a computer hooked up to a router, which is hooked up to a high-speed Internet modem. When I installed Debian under this configuration, I had no problems with networking, but lately I've been trying to take the router out of the loop, and dhcp isn't working for some reason:
Code:
##########################################
# What happens when I try to bring up eth0
# with the router bypassed - NOT SUCCESSFUL:
##########################################
lomza:/# ifup eth0
Internet Software Consortium DHCP Client 2.0pl5
Copyright 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium.
All rights reserved.
Please contribute if you find this software useful.
For info, please visit <snipped url cause lq.org doesn't like it>
sit0: unknown hardware address type 776
sit0: unknown hardware address type 776
Listening on LPF/eth0/...
Sending on LPF/eth0/...
Sending on Socket/fallback/fallback-net
DHCPREQUEST on eth0 to 255.255.255.255 port 67
DHCPREQUEST on eth0 to 255.255.255.255 port 67
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 4
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 4
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 4
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 8
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 21
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 20
No DHCPOFFERS received.
Trying recorded lease 192.168.0.101
PING 192.168.0.1 (192.168.0.1) 56(84) bytes of data.
--- 192.168.0.1 ping statistics ---
1 packets transmitted, 0 received, 100% packet loss, time 0ms
bound: renewal in 298195 seconds.
###################################
# What happens when I bring up eth0
# with the router (which was the
# setup at time of install) - SUCCESSFUL:
###################################
lomza:/# ifup eth0
Internet Software Consortium DHCP Client 2.0pl5
Copyright 1995, 1996, 1997, 1998, 1999 The Internet Software Consortium.
All rights reserved.
Please contribute if you find this software useful.
For info, please visit <snipped url>
sit0: unknown hardware address type 776
sit0: unknown hardware address type 776
Listening on LPF/eth0/...
Sending on LPF/eth0/...
Sending on Socket/fallback/fallback-net
DHCPREQUEST on eth0 to 255.255.255.255 port 67
DHCPACK from 192.168.0.1
bound to 192.168.0.101 -- renewal in 302400 seconds.
My /etc/network/interfaces file looks fine:
Code:
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
auto eth0
iface eth0 inet dhcp
you have the gateway set up for 192.168.0.1 which was probably your gateway when you had the router set up but will not be when you have it directly to your highspeed connection. You need fix this and it will work. when using dhcp don't use a set gateway or netmask and use the dns servers for your isp.
Futhermore, if your broadband connection is DSL then you will need to configure pppoe (or pppoa depending on service) too. This isn't required for a cable modem.
I was under the impression that the dhcp-client is supposed to set up the gateway and such. I'm just curious: mAineAc, did you have the same problem, change the gateway, and then have it work?
Anyways, turns out there's a simple solution in the DHCP mini-HOWTO (see section 3.10.7): http://www.ibiblio.org/mdw/HOWTO/DHC...ROUBLESHOOTING
which says to restart your cable modem (cut its power then plug it back in), because otherwise it memorizes the "ethernet address of your network card", which was my router at first, but then changed to my computer's network card. (I'm not sure what they mean by "ethernet address" though; maybe they mean the hardware address?)
Originally posted by nazdrowie
Sending on Socket/fallback/fallback-net
DHCPREQUEST on eth0 to 255.255.255.255 port 67
DHCPACK from 192.168.0.1
bound to 192.168.0.101 -- renewal in 302400
I was going by what you posted. This section shows it looking for 192.168.0.1 which is bound to 192.168.0.101. THis would not be the case if you were hooked up to your cable modem. This is the case if you were hooked up to your router. I was just assuming you had a static gateway set, which you can do with dhcp. But like you had found out it was just 'remembering' that and needed to be reset.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.