LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-17-2009, 01:29 PM   #1
imprise
LQ Newbie
 
Registered: May 2009
Distribution: SUSE
Posts: 20

Rep: Reputation: 0
Adding default gateway...


I am using SUSE Linux.

What is the difference between executing "route add default gw" and editing /etc/sysconfig/network/routes file?

Thanks
 
Old 05-17-2009, 02:09 PM   #2
NeddySeagoon
Gentoo support team
 
Registered: May 2009
Location: 56N 3W
Distribution: Gentoo
Posts: 178

Rep: Reputation: 40
imprise,

With the route add command, you have to do it every boot.
When you edit the /etc/sysconfig/network/routes file, the route is applied when the system is started.
 
Old 05-17-2009, 02:10 PM   #3
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 11,516

Rep: Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501
Running "route add default gw ..." will set the default gateway until you reboot. It will be lost on system startup, while setting it in /etc/sysconfig/network/routes will survive reboots.

Regards
 
  


Reply


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
normal default gateway reapperas with openvpn redirect-gateway jonnytabpni Linux - Networking 2 04-23-2009 03:11 PM
adding more gateway hariiyer Linux - Networking 6 12-28-2005 07:23 AM
Adding different gateway to the second NIC jomy Linux - Networking 3 12-25-2004 03:36 AM
Adding a gateway robotik Linux - Wireless Networking 5 10-20-2004 04:38 AM
Automatically adding default gateway when booting enjoyzj Linux - Networking 2 04-13-2004 05:05 PM


All times are GMT -5. The time now is 03:52 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration