LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
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 06-09-2009, 01:30 PM   #1
propofol
Member
 
Registered: Nov 2007
Location: Seattle
Distribution: Debian Wheezy & Jessie; Ubuntu
Posts: 334

Rep: Reputation: 60
Static IP address forgotten in Sid


I recently did a full upgrade of debian sid and found that the static ip I have assigned in /etc/network/interfaces is overridden during the boot process by dhclient. Looking at /var/log/daemon.log my original ip is assigned and then later on there is a message from dhclient requesting a new address.

Why does dhclient get invoked and how do I stop it from reassigning a new ip address?

Regards,
Stefan
 
Old 06-09-2009, 01:52 PM   #2
pliqui
Member
 
Registered: Feb 2007
Location: Caracas, Venezuela
Distribution: Debian x64
Posts: 156

Rep: Reputation: 17
Do a
Quote:
egrep -v '(^$|^#)' /etc/network/interfaces
to see what you have in your interfaces file
 
Old 06-09-2009, 02:02 PM   #3
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Northeast Ohio
Distribution: linuxdebian
Posts: 7,249
Blog Entries: 5

Rep: Reputation: 191Reputation: 191
or a simple (less typing)

cat /etc/network/interfaces
 
Old 06-09-2009, 09:26 PM   #4
propofol
Member
 
Registered: Nov 2007
Location: Seattle
Distribution: Debian Wheezy & Jessie; Ubuntu
Posts: 334

Original Poster
Rep: Reputation: 60
My /etc/network/interfaces file looks like this:

Code:
# The primary network interface
allow-hotplug eth0
auto eth0
iface eth0 inet static
  name Ethernet LAN card
  address 192.168.2.27
  netmask 255.255.255.0
  broadcast 192.168.2.255
  network 192.168.2.0
  gateway 192.168.2.5
During boot-up this apears in the /var/log/daemon.log file:
Code:
........
Jun  9 09:20:49 gx270d dhclient: DHCPOFFER from 192.168.2.5
Jun  9 09:20:49 gx270d dhclient: DHCPREQUEST on eth0 to 255.255.255.255 port 67
Jun  9 09:20:49 gx270d dhclient: DHCPACK from 192.168.2.5
Jun  9 09:20:49 gx270d dhclient: bound to 192.168.2.208 -- renewal in 35756 seconds.
...........
I am not sure why dhclient gets invoked in the first place.

Regards,
Stefan
 
Old 06-10-2009, 08:39 AM   #5
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Northeast Ohio
Distribution: linuxdebian
Posts: 7,249
Blog Entries: 5

Rep: Reputation: 191Reputation: 191
I would alter your interfaces file.. as follows


Code:
# The primary network interface
# name Ethernet LAN card
# allow-hotplug eth0
auto eth0
iface eth0 inet static
  address 192.168.2.27
  netmask 255.255.255.0
  broadcast 192.168.2.255
  network 192.168.2.0
  gateway 192.168.2.5
You do not need both allow-hotplug and the auto statement, choose one or the other. I've had better luck using the auto statement for fixed interfaces.

name is not a valid option in the interfaces file as far as I can tell, either remove that line or comment it out.

Last edited by farslayer; 06-10-2009 at 08:42 AM.
 
Old 06-10-2009, 10:05 AM   #6
propofol
Member
 
Registered: Nov 2007
Location: Seattle
Distribution: Debian Wheezy & Jessie; Ubuntu
Posts: 334

Original Poster
Rep: Reputation: 60
Thanks for the reply,

I have changed my interfaces file however the same thing still happens during the boot process: the correct static address is assigned initially & then dhclient gets invoked and reassigns a dynamic IP address to eth0.

Regards,
Stefan
 
Old 06-10-2009, 02:26 PM   #7
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Northeast Ohio
Distribution: linuxdebian
Posts: 7,249
Blog Entries: 5

Rep: Reputation: 191Reputation: 191
Maybe this is a bug that has popped into sid...
 
Old 06-11-2009, 01:13 AM   #8
propofol
Member
 
Registered: Nov 2007
Location: Seattle
Distribution: Debian Wheezy & Jessie; Ubuntu
Posts: 334

Original Poster
Rep: Reputation: 60
Thanks for the advice farslayer - I have finally found the culprit.

After much googling it seems that network-manager has caused similar problems. Except that I have already uninstalled it. It turned out that the problem was that I have recently tried out e17. This installed a network manager: exalt-daemon. A simple
Code:
update-rc.d -f exalt-daemon remove
fixed my problem. No more dhclient calls.

Regards,
Stefan
 
Old 06-11-2009, 10:37 AM   #9
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Northeast Ohio
Distribution: linuxdebian
Posts: 7,249
Blog Entries: 5

Rep: Reputation: 191Reputation: 191
Glad you tracked down the culprit, Ii was unaware of that option (exalt)..

I still don't believe it should have ignored the Interfaces file like it was doing, that's just rude application behavior imho.

If forced to have a network management daemon I prefer wicd..

Last edited by farslayer; 06-11-2009 at 10:38 AM.
 
  


Reply



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
If configuring a Fixed IP Address cannot access internet, what I have forgotten to do sheepy Linux - Networking 5 05-05-2009 09:37 AM
? about static ip address 200mg Linux - Newbie 3 11-06-2008 01:12 PM
Set IP address to static from DHCP assigned address jborn Linux - Networking 4 02-02-2007 08:38 PM
[SOLVED] Converting static IP-address to dynamic IP-address Blue_Ice Linux - Networking 3 07-20-2006 03:35 AM
Getting static IP address etc. chapzilla Linux - Newbie 2 06-16-2003 11:40 AM

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

All times are GMT -5. The time now is 08:52 AM.

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