LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 12-26-2006, 08:03 PM   #1
jgoddard
LQ Newbie
 
Registered: Jun 2005
Distribution: Redhat, Fedora, Debian, Ubuntu
Posts: 6

Rep: Reputation: 0
Connecting to DHCP


I've used Redhat and Fedora quite a bit, but am totally new to Debian. I
I have just installed Debian on a server in my office (command line interface only, no desktop), and I cannot get an IP from my DHCP. I have a router in place with the ip address 192.168.9.254 and the other computers in my office can all request IPs and get them fine.

I am thinking that my debian server has a firewall in place that is blocking the request or something. Whenever I do a /etc/init.d/networking start it freezes on this line:

DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 6

And it tries it over and over and over and then stops and fails.

How can I tell if I have a firewall in place and disable it? I've done an apt-get remove iptables and it removed iptables.
 
Old 12-27-2006, 05:42 AM   #2
archtoad6
Senior Member
 
Registered: Oct 2004
Location: Houston, TX (usa)
Distribution: MEPIS, Debian, Knoppix,
Posts: 4,727
Blog Entries: 15

Rep: Reputation: 234Reputation: 234Reputation: 234
Ancient rule of trouble shooting: "1st, check power cord."

Well obviously you have done that, but what about your physical ethernet connection? -- Have you checked the lights at both ends of that?

Assuming that is okay, run:
Code:
ifconfig -a

As to your firewall Q, ironically iptables -L is the normal way to check your firewall rules. It's also the normal way to insert rules into the netfilter module, so rebooting should have cleared the firewall. (You did reboot after the iptables-ectomy, didn't you?)
 
Old 12-27-2006, 08:41 AM   #3
AwesomeMachine
LQ Guru
 
Registered: Jan 2005
Location: USA and Italy
Distribution: Debian testing/sid; OpenSuSE; Fedora; Mint
Posts: 5,524

Rep: Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015
Make sure:

/etc/network/interfaces

has these lines:

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
iface eth0 inet dhcp

Then do as root:

ifup eth0

If you have more than one network interface in the server, there should be:

eth0

and

eth1

In which case you need to plug the cable into the other NIC interface. Check the cable, too. You should generally not use a crossover cable between a router and NIC. When you butt up the ends on a crossover cable all the colors line up. On a straight through cable the colors are reversed, one plug from the other.
 
Old 12-27-2006, 11:12 AM   #4
jgoddard
LQ Newbie
 
Registered: Jun 2005
Distribution: Redhat, Fedora, Debian, Ubuntu
Posts: 6

Original Poster
Rep: Reputation: 0
Thanks guys, I had that stuff all entered in my ifconfig...

But, I've put in my ubuntu CD and it loaded up fine, and I'm posting this message with it, so the network hardware / connection / wiring is working fine. There must be something with my debian install that isn't working.

When I put my Debian CD 1 in the drive to install it goes through the setup process and when it gets to the autoconfiguring of DHCP it fails... so why would Ubuntu work from the live cd right away, but Debian not be able to connect to my network during the install?

(I don't have the Debian network install CD - I had the 14 CDs burned and mailed to me.)

In looking at my networking files from the Ubuntu Live CD, in resolv.conf it has:

nameserver 192.168.9.254

and in /etc/network/interfaces is has:

auto lo
iface lo inet loopback

auto eth0
iface eth0 inet dhcp

auto eth1
iface eth1 inet dhcp

auto eth2
iface eth2 inet dhcp

auto ath0
iface ath0 inet dhcp

auto wlan0
iface wlan0 inet dhcp

but only eth0 is active and working (I only have 1 network port)

I had these entered in my resolv.conf and interfaces file, are there any other files that I should check and use for my debian install?

Last edited by jgoddard; 12-27-2006 at 11:17 AM.
 
Old 12-27-2006, 11:20 AM   #5
jgoddard
LQ Newbie
 
Registered: Jun 2005
Distribution: Redhat, Fedora, Debian, Ubuntu
Posts: 6

Original Poster
Rep: Reputation: 0
Also, when going into System > Administration > Networking in the Ubuntu GUI, in the Connections tabs it shows Ethernet connection and says "The interface eth0 is active", on the General tab it has ubuntu as my hostname, and the domain name is left blank. the DNS tab has 192.168.9.254 as the DNS Server and nothing in the Search Domains textbox. Finally the Hosts tab has my localhost 127.0.0.1 and 127.0.1.1 (ubuntu) as well as a bunch of IPV6 entries.
 
Old 12-27-2006, 10:23 PM   #6
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Northeast Ohio
Distribution: linuxdebian
Posts: 7,249
Blog Entries: 5

Rep: Reputation: 191Reputation: 191
14 CD's so thjat leads me to believe you are trying to install Debian Stable 3.1r4. It may not support the network card in your machine. you could try telling Debian to install the 2.6 kernel (2.6.8-3) by using the linux26 command at the boot prompt of the install.

or you could download the Debian Etch installer with the 2.6.18 Kernel at install.. much better chance of it detecting your hardware properly and getting your network card to work.. If you have broadband connection just grab the 100MB Netinstall iso.. http://www.debian.org/devel/debian-installer/
 
Old 12-28-2006, 12:29 AM   #7
jgoddard
LQ Newbie
 
Registered: Jun 2005
Distribution: Redhat, Fedora, Debian, Ubuntu
Posts: 6

Original Poster
Rep: Reputation: 0
I got it to work!

Sorry I didn't post an update, but after I had connected to the internet with the ubuntu live cd, I took out the ubuntu CD and restarted the computer to try some more to get it to work, and when it restarted the computer it received an IP from the router during the startup. So when the debian install wouldn't work, all I did was run the Ubuntu live cd and then restart the computer and it worked... I don't know why that would have made a difference, maybe the router was ignoring my server's mac address until ubuntu got it's attention, then it gave an IP to my debian install?

I then formatted and re-installed debian just to make sure it still worked, and this time when I did the install it went smoothly and got an IP right away.

Any explanations would be appreciated but I'm just glad it's working now.
 
Old 12-28-2006, 02:50 AM   #8
operator10001
Member
 
Registered: Mar 2006
Distribution: debian sarge
Posts: 222

Rep: Reputation: 30
sometimes live cd's can change the bios settings. to understand this better goto:
/etc/network.
 
Old 12-28-2006, 03:19 AM   #9
blackhole54
Senior Member
 
Registered: Mar 2006
Posts: 1,896

Rep: Reputation: 61
Quote:
Originally Posted by operator10001
sometimes live cd's can change the bios settings. to understand this better goto:
/etc/network.
Hugh? Can you elaborate please?
 
Old 12-28-2006, 11:28 AM   #10
jgoddard
LQ Newbie
 
Registered: Jun 2005
Distribution: Redhat, Fedora, Debian, Ubuntu
Posts: 6

Original Poster
Rep: Reputation: 0
There are some differences there, there is an if-up.d if-down.d directories but they're empty, but the /etc/network/interfacs file is the same as I had it.
 
  


Reply

Tags
debian


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Connecting with DHCP automatically. HiIamBill Linux - Networking 2 07-22-2006 04:58 PM
Connecting to AP, but DHCP doesn't work NeoChaosX Linux - Networking 2 02-24-2006 03:25 PM
Connecting to DHCP... Tuxluver Linux - Wireless Networking 3 09-01-2005 11:34 AM
Connecting to internet through DHCP Tr@ce Linux - Newbie 6 02-18-2005 07:36 AM
problems connecting to dhcp server qanopus Linux - General 15 12-20-2002 02:43 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 02:58 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration