I tried to add a route like this, however as shown an error is thrown :
The 10.132.81.161 gateway is used as a gateway for another interface in the server (eno50).
Why is the error above thrown when I try to add that line? Is it because that gateway is not initiated as a default gateway in the routing table?
:confused:
Hi:
I donīt know how to add route gateway and when restart the machine lose this route and put other.
In SCO ver 5.6 Enterprise write:
etc\route delete gateway
route add gateway 199.199.1.1.
so , netstat -rn to see if has change -> all ok
Restart -> !!!... (2 Replies)
Hello ,
We have 3 rs/6000 server's running aix on our local network, so each time I try to ping one of these servers we get a "network is down" error , I've been instructed to use to route add command which is ...
#route add server.ip router.ip
after this the ping command works fine ,... (6 Replies)
I have two networks connected by cisco routers. My first subnet is 192.168.0.0 and my second is 192.168.1.0.
My SCO unix machine is on the 192.168.1.0 subnet with an IP of 192.168.1.231. It can see the entire .1.0 subnet but nothing on the other network.
My cicso router(gateway) to the other... (6 Replies)
Hello all!
We have two fedora routers one at each site. What we are trying to do worked using freesco but not on fedora, i'm not very good at scripting and need a little guidence. Basicly what we are trying to do is if the primary line dies, the router will change it's routes to go through our... (0 Replies)
We are unable to bring one of our linux boxes into the network once it was restarted. But once we stop and start the network service. We are able to ping the gateway and get into network. After a minute or two we get the following reponse for the ping command
64 bytes from 124.168.215.40:... (6 Replies)
Hi,
I am trying to add route command in Solaris 10 machine in the following fashion:
route add -host 10.8.112.10 180.144.1.250 -interface lo0:1
this command fails with an error "lo0:1: bad value"
I want to add a route to 10.8.112.10 that picks 180.144.1.250 as the gateway via the... (3 Replies)
Just want to know if someone has a clue about what could be happening here:
I have an AIX box with four NICs in Ether channel connected to a Cisco Switch.
When I try to ping the default gateway, sometimes it works, but sometimes it doesn't work unless it has a defined static route.
Thanks... (1 Reply)
I have setup a Linux machine on my server but for some reason Im unable to reach my default gateway. This is causing me to not communicate with the outside world (unable to connect to CentOS repos)
# ifconfig
enp0s3: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet... (3 Replies)
Hi all,
i have a rhel 6.2 with a default gateway.
This server is an Intranet office with no internet access.
DNS are already configured and it's possible to resolve my target.
My goal is to link my application (apache forward) only to http://mytarget.yyy through a new gateway (That does... (0 Replies)
Dear friends
I use RedHat 6.5, which sets the gateway in the configuration file / etc / sysconfig / network as GATEWAY = 192.168.1.26, and the gateway in the configuration file / etc / sysconfig / network-scripts / ifcfg-eth11 as GATEWAY = 192.168.1.256. The two gateways are different.... (6 Replies)
Discussion started by: tanpeng
6 Replies
LEARN ABOUT PLAN9
routing
routing(7P) Protocols routing(7P)NAME
routing - system support for packet network routing
DESCRIPTION
The network facilities provide general packet routing. The routing interface described here can be used to maintain the system's IPv4 rout-
ing table. It has been maintained for compatibility with older applications. The recommended interface for maintaining the system's routing
tables is the routing socket, described at route(7P). The routing socket can be used to manipulate both the IPv4 and IPv6 routing tables
of the system. Routing table maintenance may be implemented in applications processes.
A simple set of data structures compose a "routing table" used in selecting the appropriate network interface when transmitting packets.
This table contains a single entry for each route to a specific network or host. The routing table was designed to support routing for the
Internet Protocol (IP), but its implementation is protocol independent and thus it may serve other protocols as well. User programs may
manipulate this data base with the aid of two ioctl(2) commands, SIOCADDRT and SIOCDELRT. These commands allow the addition and deletion of
a single routing table entry, respectively. Routing table manipulations may only be carried out by privileged user.
A routing table entry has the following form, as defined in /usr/include/net/route.h:
struct rtentry {
unit_t rt_hash; /* to speed lookups */
struct sockaddr rt_dst; /* key */
struct sockaddr rt_gateway; /* value */
short rt_flags; /* up/down?, host/net */
short rt_refcnt; /* # held references */
unit_t rt_use; /* raw # packets forwarded */
/*
* The kernel does not use this field, and without it the structure is
* datamodel independent.
*/
#if !defined(_KERNEL)
struct ifnet *rt_ifp; /* the answer: interface to use */
#endif /* !defined(_KERNEL) */
};
with rt_flags defined from:
#define RTF_UP 0x1 /* route usable */
#define RTF_GATEWAY 0x2 /* destination is a gateway */
#define RTF_HOST 0x4 /* host entry (net otherwise) */
There are three types of routing table entries: those for a specific host, those for all hosts on a specific network, and those for any
destination not matched by entries of the first two types, called a wildcard route.
Each network interface installs a routing table entry when it is initialized. Normally the interface specifies if the route through it
is a "direct" connection to the destination host or network. If the route is direct, the transport layer of a protocol family usually
requests the packet be sent to the same host specified in the packet. Otherwise, the interface may be requested to address the packet to an
entity different from the eventual recipient; essentially, the packet is forwarded.
Routing table entries installed by a user process may not specify the hash, reference count, use, or interface fields; these are filled in
by the routing routines. If a route is in use when it is deleted, meaning its rt_refcnt is non-zero, the resources associated with it will
not be reclaimed until all references to it are removed.
User processes read the routing tables through the /dev/ip device.
The rt_use field contains the number of packets sent along the route. This value is used to select among multiple routes to the same desti-
nation. When multiple routes to the same destination exist, the least used route is selected.
A wildcard routing entry is specified with a zero destination address value. Wildcard routes are used only when the system fails to find a
route to the destination host and network. The combination of wildcard routes and routing redirects can provide an economical mechanism for
routing traffic.
ERRORS
EEXIST A request was made to duplicate an existing entry.
ESRCH A request was made to delete a non-existent entry.
ENOBUFS Insufficient resources were available to install a new route.
ENOMEM Insufficient resources were available to install a new route.
ENETUNREACH The gateway is not directly reachable. For example, it does not match the destination/subnet on any of the network
interfaces.
FILES
/dev/ip IP device driver
SEE ALSO route(1M), ioctl(2), route(7P)SunOS 5.10 9 Nov 1999 routing(7P)