LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 03-31-2005, 06:58 PM   #1
peter_mclein
LQ Newbie
 
Registered: Mar 2005
Posts: 3

Rep: Reputation: 0
Unhappy I'm not able to add new routes


Hi!
I have next problem.
When I try to add a new route or delete a route to my Linux Server 2.4.21-20.EL i686 i386 GNU/Linux
I get next error


#route add -net 127.0.0.0

SIOCADDRT: Invalid argument


[root@webdev root]# route del -net 169.254.0.0

SIOCDELRT: Invalid argument


What would be wrong?
 
Old 03-31-2005, 08:34 PM   #2
DoubleOTeC
Member
 
Registered: Aug 2003
Location: Dominica
Distribution: RedHat, FC1, FC3, FC4
Posts: 266

Rep: Reputation: 30
this may occur, if you have no suitable network device; ie, if you don't have a network device that is within the class of address or network for which you are trying to add the route.

Do you have a local interface? ("lo")

What's the output of /sbin/route?
 
Old 04-01-2005, 03:57 AM   #3
3-1415
LQ Newbie
 
Registered: Jul 2004
Location: Kyiv
Distribution: Mandrake, ASP, Slackware, W2k
Posts: 19

Rep: Reputation: 0
Try this way:
route add -net 127.0.0.0/8

if You have more then 1 net interface you have to specify which interface this rule for
Example:
route add -net 127.0.0.0/8 dev eth0 <- I apply the rule for eth0 interface

Anyway RTFM (#man route, #man ifconfig, #man ip)

Good luck!
 
Old 04-04-2005, 09:08 AM   #4
peter_mclein
LQ Newbie
 
Registered: Mar 2005
Posts: 3

Original Poster
Rep: Reputation: 0
aboute route

Hi!.
This is the output for /sbin/route

Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
default 159.16.83.65 255.255.255.255 UGH 0 0 0 eth0
159.16.83.64 * 255.255.255.240 U 0 0 0 eth0
169.254.0.0 * 255.255.0.0 U 0 0 0 eth0
default 159.16.83.65 0.0.0.0 UG 0 0 0 eth0


And the command
route add -net 127.0.0.0/8 dev eth0
works..

Why need to put the slash 8 ?


And how can I delete this route from my table
169.254.0.0 * 255.255.0.0 U 0 0 0 eth0

I try.

[root@webdev root]# route del -net 169.254.0.0 netmask 255.255.255.240
SIOCDELRT: No such process
[root@webdev root]# route del -net 169.254.0.0 netmask 255.255.255.240 dev eth0
SIOCDELRT: No such process




Last edited by peter_mclein; 04-04-2005 at 09:19 AM.
 
Old 04-04-2005, 09:37 AM   #5
aznluvsmc
Member
 
Registered: Aug 2004
Location: Newmarket, Ontario
Distribution: OpenSuse 10.2
Posts: 184

Rep: Reputation: 30
Look at the IP address and subnet mask you entered. They don't match your routing table. It should be:

route del 159.16.83.64 netmask 255.255.255.240

Secondly, I don't think it's necessary to delete the 169.254.x.x route as all Linux's have this route. It's the reserved APIPA IP range.
 
  


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
Routes Obie Linux - Networking 16 04-28-2005 10:15 PM
deleting routes Julian_Thong Linux - Networking 4 08-19-2004 07:38 AM
routes himyuza *BSD 6 08-03-2004 10:41 AM
I need some routes |Drakehash| Linux - Newbie 1 06-08-2003 12:22 AM
I need some routes |Drakehash| Linux - Networking 1 06-07-2003 02:36 PM

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

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