network card wont get dhcp ip address from my ISP

Posted on 2005-04-22
Medium Priority
Last Modified: 2012-05-05
my network card in my fedora 3 linux system wont get a dynamic ip from my isp when connected to a switch ?

ive got two routers connected to the switch which work fine and get ip's but the linux system doesnt want to get an ip when connected to the switch?

if i connect it to the modem directly then it will but not going through the switch?
anyone know if they experienced such issues?

ive got the ifcfg-eth1 setup with dhcp on boot

Question by:aot2002
LVL 16

Accepted Solution

JammyPak earned 600 total points
ID: 13845589
how many IP addresses is your ISP willing to give you?

just to make sure I get it
you have a modem from your isp connected to a switch, and then you've connected 2 routers into that switch - and they have been given dynamic addresses, and now you're plugging your pc into the same switch, but it's not getting an address

Assisted Solution

fixnix earned 200 total points
ID: 13845646
The switch shouldn't be an issue if it's working properly.  To find out for sure,
assign an IP manually (/sbin/ifconfig eth1 x.x.x.x broadcast y.y.y.y netmask z.z.z.z up)
    where:  x.x.x.x = Valid IP from your ISP's IP pool
                y.y.y.y =  Broadcast addy
                z.z.z.z = Netmask ( if you have a 32 IP block from your ISP for example)

and set the gateway address (/sbin/route add default gw w.w.w.w) (obviously w.w.w.w is your gateway/router's address...prolly the 1st IP in your IP pool)

then see if you can ping the gateway/router and access the internet.  If not, then there is some other connectivity problem (bad patch cable (replace), misconfigured switch port (if a managed switch), broken switch port (try another port), improper speed negotiation between switch and nic (try manually setting speed), etc) and isn't DHCP related.

Expert Comment

ID: 13846471
Also make sure one of the routers isn't also acting as a DHCP server on your segment.  Try unplugging the routers from the switch, so that it's just the cable modem and Linux box plugged into the switch.  If that still doesn't work, but plugging the cable modem into the Linux box does, then it's either a problem with the cable modem, a bad cable / switch port, or some other local problem (or possibly an intermittent issue with the upstream provider).  Note that some cable modems will maintain a table (arp) of the devices connected to it, and get unhappy about trying to connect multiple devices directly to it or switching between multiple devices.
Get your Conversational Ransomware Defense e‑book

This e-book gives you an insight into the ransomware threat and reviews the fundamentals of top-notch ransomware preparedness and recovery. To help you protect yourself and your organization. The initial infection may be inevitable, so the best protection is to be fully prepared.


Author Comment

ID: 13847513
>>how many IP addresses is your ISP willing to give you?

I called them they said up to 6 computers and right now i have two routers taking up 2 spots so that leaves me with 4 left.
yes you have the correct setup layout ...

i will attempt the other tries tonight for you


Author Comment

ID: 13851604
is there a command to restart a network service in linux?

Assisted Solution

macker- earned 200 total points
ID: 13854584
service or network?

/etc/rc.d/init.d/network restart

will restart network under RedHat o/s's.  other o/s's may place the init script in a slightly different place, or work better with "service network restart"

Author Comment

ID: 13855183
thanks well it was a problem with my ISP only giving me two computer address's and they were susposed to allow up to 5 !

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The purpose of this article is to demonstrate how we can use conditional statements using Python.
Fine Tune your automatic Updates for Ubuntu / Debian
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
Suggested Courses
Course of the Month13 days, 23 hours left to enroll

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question