LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 08-31-2006, 12:55 AM   #1
MarleyGPN
Member
 
Registered: Apr 2003
Location: Vail, CO
Posts: 73

Rep: Reputation: 15
Prevent dhcpcd from changing default gateway?


Hi there,

I have Slackware 10.2 installed with kernel version 2.6.17, with three network interfaces. eth0, eth1, and eth2. eth0 is hooked up to my private lan, and it is set statically. eth1 is connected to my university and is configured using dhcpcd. eth2 is connected to Comcast and is also configured using dhcpcd. I would like the Comcast (eth2) to be the default gateway. Every time my university ip address changes it takes over the default gateway. Is there any way to configure dhcpcd to ignore the default gateway from the dhcp server? Also is there a way to configure it to ignore the dns server entries in the dhcp request?

Thanks,
MarleyGPN
 
Old 08-31-2006, 01:21 AM   #2
Micro420
Senior Member
 
Registered: Aug 2003
Location: Berkeley, CA
Distribution: Mac OS X Leopard 10.6.2, Windows 2003 Server/Vista/7/XP/2000/NT/98, Ubuntux64, CentOS4.8/5.4
Posts: 2,986

Rep: Reputation: 45
Funny,I was also dealing with this problem at work today with a user's laptop using Ubuntu 5.10.

We found that the profiles and settings for the interfaces (eth0, eth1, eth2, etc...) were located in /etc/network/interfaces. Additionally, gnome's networking profiles were located in /etc/gnome-system-tools/networking/profiles.xml. Just change the settings in there and it will force it to be static to whatever is in the file.

With slackware, maybe the profiles are in /etc/sysconfig/network. This should get you in the right direction.
 
Old 09-01-2006, 01:12 PM   #3
Micro420
Senior Member
 
Registered: Aug 2003
Location: Berkeley, CA
Distribution: Mac OS X Leopard 10.6.2, Windows 2003 Server/Vista/7/XP/2000/NT/98, Ubuntux64, CentOS4.8/5.4
Posts: 2,986

Rep: Reputation: 45
I also want to add that the DNS can be forced to stay the same by editing the /etc/resolv.conf file
 
Old 09-01-2006, 01:37 PM   #4
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 79
From "man dhcpcd":
Code:
       -G [gateway]
              Prevents  dhcpcd from installing default routes provided by DHCP
              server.  If optional gateway ip address  parameter  is  supplied
              then use it for default route.

       -R     Prevents  dhcpcd  from  replacing  existing <etcDir>/resolv.conf
              file.
 
  


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
tcpdump, dhcpcd and recieving many listings of addresses and the correct gateway and starlypt Linux - Networking 1 09-16-2005 08:04 PM
dhcpcd not adding default route cpsully69 Linux - Networking 2 09-07-2004 09:09 PM
Mandrake 8.2 Startup File? and Changing the Default Gateway N4N01D Mandriva 0 08-04-2004 08:12 AM
change default dhcp client to dhcpcd waffe Debian 2 05-11-2004 09:11 PM
How to prevent loading the default driver(b44) simon780 Slackware 3 03-30-2004 08:54 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 04:13 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