Networking :: Route Traffic From A Single Host Through A Specific Interface?

Aug 21, 2010

I have a linux router with 2 physical ISPs and a VPN tunnel that all my traffic passes through. I would like to setup a rule to redirect all traffic from one internal IP address (10.0.0.x) through the physical link only. My current script is as follows.

iptables -F
iptables -X
echo 1 > /proc/sys/net/ipv4/ip_forward

[code]....

My goal is to do something similar to the mangle on the tor traffic, but for an entire host.

View 2 Replies


ADVERTISEMENT

Networking :: IPtables: Route Outgoing Traffic From Internal Host To Only Go A Internet Interface?

Nov 21, 2010

My Ubuntu Box has 3 interfaces. eth0 (Internal 192.168.1.0/24)eth1 (External ISP DHCP)eth2 (External ISP Static IP)I need the outgoing traffic to internet for 1 of the internal pc (192.168.1.10) to only go only go through eth2

View 4 Replies View Related

Networking :: Route All Traffic Received By An Interface To Another And Vice Versa?

Mar 2, 2011

The task I am trying to complete is the virtualization of an IPv6 router created using two fedora machines. Here is the physical setup I have now...

PC1:eth0 <------> network
PC1:eth1 <------> PC2:eth0
PC1:eth2 <------> PC2:eth1

PC1 runs radvd to provide router advertisements to the network and a DHCPv6 server for stateful addresses.Each interface is configured on a separate subnet. PC2 runs a DNS server on eth0. PC2:eth1 is used as an IPv6 client for testing purposes. The connections from PC1 to PC2 are just crossover cables.I've created virtual machines of both PCs and have created 4 virtual adapters on the host machine for each of the local-only interfaces.Now I have this:

PC1:eth0 = HOST eth0
PC1:eth1 = HOST vboxnet0
PC1:eth2 = HOST vboxnet1

[code]....

View 2 Replies View Related

Networking :: Route Add With Specific Interface?

Apr 18, 2009

I have an Asterisk-server with 2 interfaces, a WAN-interface (eth1) and a LAN-interface (eth0).

SETUP : IAX-provider(internet) --> firewall --> Asterisk-server --> switch --> clients_on_LAN

So everything coming from the IAX-provider on port 4569 is forwarded to the Asterisk-server's WAN-interface (eth1). This needs then be routed to an internal SIP-phone (an IVR-system will define which one) via eth0. When a call is initiated from an internal SIP-phone (they register to the IP-address assigned to eth0) it needs to be routed via eth1 to the gateway (192.168.4.250). Asterisk will setup an IAX-channel on WAN-interface (eth1) to the IAX-provider (via gateway). So... will this work :

Code:

route add -net ip_IAXprovider netmask 255.255.255.0 gw 192.168.4.250 dev eth1

Code:

route add -net 192.168.4.0 netmask 255.255.255.0 dev eth0 (no gateway needed for the LAN-interface, communications to the gateway need to go via the WAN-interface !)

View 4 Replies View Related

CentOS 5 Networking :: Route Add With Specific Interface?

Apr 19, 2009

I have an Asterisk-server with 2 interfaces, a WAN-interface (eth1) and a LAN-interface (eth0).

SETUP :

IAX-provider(internet) --> firewall --> Asterisk-server --> switch --> clients_on_LAN

So everything coming from the IAX-provider on port 4569 is forwarded to the Asterisk-server's WAN-interface (eth1).
This needs then be routed to an internal SIP-phone (an IVR-system will define which one) via eth0.

When a call is initiated from an internal SIP-phone (they register to the IP-address assigned to eth0) it needs to be routed via eth1 to the gateway (192.168.4.250). Asterisk will setup an IAX-channel on WAN-interface (eth1) to the IAX-provider (via gateway).

So... will this work :

route add -net ip_IAXprovider netmask 255.255.255.0 gw 192.168.4.250 dev eth1

View 9 Replies View Related

Networking :: Force TCP Traffic Out Over Specific Interface / When IP Is Bound To Another Local NIC

Aug 12, 2010

I'm hoping some of the Linux network experts can help me with this problem.

Situation: I have a technology which is a WebLogic JEE application that communicates to an Oracle database. Everything is installed in a single Linux virtual machine running in VirtualBox. Traffic from the JEE application goes via JDBC over TCP to the local running database. What I want to do is test a new database firewall server that wants all traffic destined for the database to flow via another virtual machine running the DB Firewall software.So therefore want I need to do is have DB traffic forced out over one interface only to return on another interface on the same VM listening on a different address.

JEE application running in WebLogic bound to 192.168.111.12 (eth1 a VirtualBox hostonly interface). Makes a request for 10.0.111.12 (eth2 a VirtualBox internal interface) which the database is listening on. Because both IPs are on local interfaces, Linux is going to handle the traffic and not route the 10.x traffic via the 192.x interface.I also have running the database firewall server which has a bridge (br0) between the HostOnly network and the Internal network.Both systems are running Oracle Enterprise Linux R5U4, which is basically the same as RedHat.What I want to do is have the request for 10.0.111.12 forced out via 192.168.111.12, bridged over the br0 connection and back into 10.0.111.12 and to the database. My networking knowledge is pretty good, but i'm stuck right now on the right way to do this. I'm pretty sure it is possible, I just need clear advice.

Reason for setup: Ideally I would build the system with the database on a separate machine so that I can easily route the traffic. Unfortunately we have many VirtualBox based demonstration systems with both the application and database installed on the same VM and therefore the amount of work to migrate these two dual VMs is going to be significant, also many of these VMs are demonstrated from laptops which have limited resources and creating a new database VM reduces overall performance. If I can create a way to force the traffic in this manner off and back onto the same VM via the other VM bridge, it would be fantastic.

View 7 Replies View Related

Networking :: Configure A Network Route To A Host For Testing Network Interface?

Aug 30, 2010

today I tried to configure a network route to a host for testing my network interface. Code: route add 192.168.1.15 eth0 As I have to eth interfaces and both interface got their IP from DHCP (192.168.1.11 and 192.168.1.12) and are in the same subnet, I shut the other interface down:

Code: ifconfig eth1 down Then I tried to test the interface by doing a ping to 192.168.1.15.
Problem: When I unplug the cable from eth0 (and eth1 is still plugged) the ping still works. Somehow my linux (it's debian) powers up again eth0 and pings over this port.

How can I stop my linux doing this. I just want to have the route added only on the one interface - not the other. Is it maybe some case of a default-gateway?

View 5 Replies View Related

Debian Configuration :: Routng Traffic To A Website Via A Specific Interface

Jul 30, 2011

I am running Debian Squeeze on an old pc (AMD K62-500) which serves as my multiwan router and torrent box. Internet uplink is provided via a dsl line and 2 wireless canopy modules.

Setup has been generally fine except when connecting/downloading as free user from sites like rapidshare, hotfile, filesonic, etc. The problem arises when I am connected to these sites using the wireless uplinks because of the shared public ip. I don't really download that much using direct download methods so I don't really see myself being a premium user from these sites.

If these sites are on a specific ip or ip range, an entry on the static routing table would have been fine but when I tried using ping, a different ip would appear to reply each time.

I wonder if there can be a solution like using iptables where in traffic to and from these sites will only use the NIC connected to the dsl line.

View 1 Replies View Related

Networking :: Definition: "a Process That Replaces A Series Of Related, Specific Routes In A Route Table With A More Generic Route"

Oct 21, 2010

I got this definition:"a process that replaces a series of related, specific routes in a route table with a more generic route." honestly I found it not so clear.. I want to know if this definition is correct and also more details about this subject..

View 1 Replies View Related

Networking :: How To Route Traffic To The Vpn

May 11, 2010

I've succesfullly connected to my vpn with kvpnc, but none of my traffic is going through the vpn! I dont know how to route traffic to the vpn. for instance, when I go to whatsmyip.com it still has my previous ip.

View 1 Replies View Related

Networking :: Route Internet Traffic Over Second IP Address?

Mar 4, 2010

My ISP has given me 3 IP addresses to use for the internet (76.148.200.3, 76.148.200.4 and 76.148.200.5).

If I do a "wget whatismyip.com" or netcat into another server, I am appearing as 76.148.200.3.How do I change my route (command line) in linux to route internet traffic through 76.148.200.5?

Code:
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
# The loopback network interface
auto lo
code....

View 9 Replies View Related

Networking :: Route Internet Traffic Over Tun0?

Mar 28, 2010

I have eth0 and tun0. tun0 is a VPN tunnel going over eth0. Everything on the other end is setup and working fine, when I type Code: traceroute 4.2.2.1 I see my the ping is going over 192.168.2.99 (eth0). When I then type Code: route add -net 4.2.2.1 netmask 255.255.255.255 dev tun0 traceroute 4.2.2.1 I see ping is going over 10.8.0.1 (tun0) instead of eth0, so that is working

What does not work however is when I do Code: route add -net 0.0.0.0 netmask 0.0.0.0 dev tun0 traceroute 4.2.2.1 I get no ping! I believe the problem is because all traffic is routing over tun0, which means even the VPN tun0 needs to go through eth0, it can no longer do this. Is there a way around this where I can route everything except for 114.77.31.26 (which is my VPN gateway for tun0)?

View 18 Replies View Related

Networking :: Route All System Traffic To Localhost?

Mar 18, 2011

I just installed a fresh copy of debian (no GUI). I want all my traffic on bash (such as when I do ping or dig or wget, basically whatever) to be sent to localhost:8080. How can I do that? I've a ssh port forward setup that will forward all traffic arriving at my localhost:8080 to another server.

View 4 Replies View Related

Ubuntu Networking :: Route Traffic From Wlan0 Through Eth0?

Dec 10, 2010

I'm running Linux Mint 10 . I have a wireless PCMCIA card (Linksys WPC 11 ver.3) that I've put into master mode, and I'm trying to set up my laptop as a wireless hotspot. I am very confident that I want to do this and have no interest in using a wireless router....I say that because that topic inevitably comes up with posts like this. The problem I'm having is I don't understand how to get wlan0 and eth0 to "talk" to each other...That is, I don't know how to set it up so that traffic from wlan0 goes through eth0, so that devices that connect to my hotspot can access the internet.I've seen a few guides about this, but they were either much broader in scope (i.e. much more complex), or for other distributions, etc, and it's too much for me to follow as a linux .

View 6 Replies View Related

Networking :: Using Route Tool To Forward Traffic Between Two Nics?

May 10, 2011

I am trying to set up a Linux box that can act as a router (and firewall later). I have a Debian 5 installation and it has two nics in it. I am trying to use the linux route command to set up a route between the two interfaces. I am finding it difficult to do. Let me explain how I am trying to set up my network: I have the ethernet cable from my modem connecting to eth0 of my Debian box, then I have eth1 connecting to a switch, which I connect all my computers and other devices to. I want to have two different ip address schemes for the devices. So here is my interfaces file:

Code:

#eth0 connects to modem
allow-hotplug eth0
iface eth0 inet static

[code]....

So I am wondering, to get my ethernet traffic from eth0 to eth1 and vice versa, do I need to make it so the Gateway for Destination 192.168.1.0 is 10.1.1.1, and for Destination 10.0.0.0, Gateway 192.168.1.0? I have looked at the linux manpage for route and I am still confused. I have also looked at the Debian networking page, but it is still unclear to me how to do this. how I am to use the route command to get this working? Or am I not even supposed to use the route command?

View 4 Replies View Related

Networking :: Unable To Route Traffic Based On Packet Content

May 7, 2011

My linux machine is connected to the outside internet, and I have a minecraft server running on an internal machine (192.168.1.201). Right now, I am forwarding port 80 on the linux machine to 192.168.1.30, which is working.

iptables -t nat -I PREROUTING -i eth0 -d 192.168.1.30 -j DNAT --to-destination 192.168.1.201
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
iptables -A PREROUTING -t nat -i eth0 -p tcp --dport 80 -m state --state NEW,ESTABLISHED,RELATED -j DNAT --to 192.168.1.201

______________________________

I want to filter out the GET/POST requests and forward them to port 8080. I can't seem to get that working.

I've tried this:

iptables -A INPUT -d 192.168.1.30 -p tcp --dport 80 -m string --algo bm --string 'GET' -j REDIRECT --to-ports 8080

View 1 Replies View Related

Networking :: Most Common Method To Route Network Traffic As A Router/proxy

Apr 22, 2011

I am using Debian 5 and I have some networking experience, however I want to learn to do this the best way possible. I have a Debian box with two nics and I want to connect that to a switch and use my Debian box as a router basically, as well as having a firewall setup within that too.

Should I use iptables to set up nat or the route command or what? I just want to know the group of tools to use in order to set up my network. Network diagram: Internet <------> Debian Box <----> switch <----> hosts I found some guides but they are for linux 2.4 and i'm not sure if they are right.

View 1 Replies View Related

Networking :: No Route To Host

Aug 21, 2009

I use linux.

I have below error, no route to host.

View 6 Replies View Related

Networking :: Route Only For A Specific Port And Target?

Mar 14, 2011

I have to route some packages over the right interface.I default route everything for the target-network over one network-interface. That works perfectly. But i have to route packages for one specific host and one specific port over another network-interface. I tried many things with the route-command, but i think there's no possibility to route only one port? May i can do this with iptables? I only found ways to forward some packages, which are coming in over one interface. But in my case all packages go out over one interface.

View 13 Replies View Related

Networking :: Trace Route On A Specific Port?

Dec 4, 2009

I've got a few systems which forward ports to one another all over the place, and somewhere along the line a port forward fails. I want to trace the route of a connection on a specific port to see where the connection hits a wall, to see what system is causing the problem. I've tried `tracetoure -T -p <port>` but it doesn't output anything about the ports it hits, stops when it hits the address I supplied even though it is forwarded elsewhere, and there doesn't seem to be a verbose mode. interstingly, if I specify a different source port via the '-s' option, the trace keeps hopping to * * * * and never get anywhere (at least to 27 hops then I CTRL+C)

View 6 Replies View Related

Networking :: Route For IP And Port Trough Specified Interface?

Aug 13, 2010

I have two NIC, one is ethernet and second is via modem. On the eth0, most of no standard ports are blocked, so I need to connect to specified port on some IP, through ppp0 (modem), to use ssh connection on non standard port to that IP. For other ports on that IP and all other IPs I want to use eth0.

View 1 Replies View Related

Networking :: Can Ssh From A Computer But Not Into It - No Route To Host

Apr 11, 2010

I have 3 computers on a local home network. Computer 1 is not receiving incoming anything from other computers on the network, and I don't know why. The regular internet works fine.

Computer 1 can ping and ssh into either 2 or 3. 2 can ping and ssh into 3 and vice versa. But nothing can ping OR ssh into 1. Trying to do so says "no route to host".

All computers are running Ubuntu Karmic.

View 7 Replies View Related

Networking :: No Route To Host - Put Can Ping?

May 9, 2011

I have a server that I can ping, and I can connect remotely with ssh to it. But when I try to connect to apache (port 80) I get "no route to host". But I can connect to localhost It's not just my client system that is having this problem but also systems that are on the same subnet There is no firewall running on the server route on the server

[Code]...

View 9 Replies View Related

Networking :: Sendmail - No Route To Host ?

Feb 22, 2011

We have a Red Hat Linux server that sends email out daily. It points to and Exchange server for smtp. It works fine, however, at least once a day, an email will fail and in the maillog I see "No route to host". After a few minutes, everything is working fine. The Linux server and Exchange are on the same VLAN and IP subnet.

View 2 Replies View Related

Networking :: Have 2 Internet Providers At Office And Want To Use A Single Router To Route Them Both?

Jul 8, 2011

I have a weird issue with source routing on a linux box.The plan goes like this:I have 2 internet providers at my office and i want to use a single router to route them both ( i don't need load balancing or failover). I just want access to either provider based on the ip i use on my pc. The first provider, let's call it RDS, is simple: i've got an RDS_IP, RDS_MASK and RDS_GW.The second provider is complicated, we'll call it INES. I have a INES_IP, INES_MASK, INES_GW and they also gave me a subnet of public ip's: ILAN_NET which i have to route myself through INES_IP.I also have a third nic with an local ip: LAN_NET and an alias for the INES subnet: ILAN_NETthe router has dhcp enabled, giving by default ip's from LAN_NET and using the default gw, RDSI have snat for the LAN_NET to go through RDS.

If i enter an ip from the ILAN_NET, instead of routing in through the INES_GW, it also goes through RDS_GW.the routing i've used for about 5 months has worked perfectly untill one day, when it just stopped. this is my setup:ip route add $RDS_MASK dev $RDS_IF src $RDS_IP table rdsip route add default via $RDS_GW table rdsip route add $INES_MASK dev $INES_IF src $INES_IP table inesip route add default via $INES_GW table inesip route add default via $RDS_GWip rule add from $RDS_IP table rdsip rule add from $INES_IP table inesip route add $LAN_NET dev $LAN_IF table rdsip route add 127.0.0.0/8 dev lo table rdsip route add $ILAN_NET dev $ILAN_IF table inesip route add 127.0.0.0/8 dev lo table ineswhat puzzles me the most is that this setup has worked, and now it doesn't .... without any changes on the router.I've tried everything save for a format/reinstall.

View 2 Replies View Related

Networking :: Sending Packets To The Local Interface Through A Route?

Oct 13, 2010

I want to build a topology of this kind:

|eth0 (a.a.a.a) |
Linux PC |<----------------> | ROUTER
|eth1 (b.b.b.b) |
|<----------------->|

the linux machine has two interfaces eth0 (a.a.a.a) and eth1 (b.b.b.b) connnected to two interfaces of a router. Now that if I send any packet destined to b.b.b.b from a.a.a.a interface on the linux machine, it should take the folowing path: eth0->router->eth1 . and it should be the same for vice versa.

View 1 Replies View Related

Fedora Networking :: No Route To Host Using Showmount On 12?

Feb 14, 2010

I have two system, an Intel Core2 Duo system running the 32-bit version of Fedora 12, and a MacBook Pro running the 64-bit version of Fedora 12. I'm using the Gnome desktop on each system. I have enabled all the services I believe are necessary to support NFS including nfs, rpcbind, rpcgssd, rpcidmapd, and rpcsvcgssd on each system. I have added an entry to my /etc/exports file to export my home on each system, and if I type this command:

$ showmount -e localhost

I get a result like this:

Export list for localhost:

/home/tron 192.168.200.101,192.168.200.100

However when I issue this type of command:

$ showmount -e <remote host name>

I get this kind of result: rpc mount export: RPC: Unable to receive; errno = No route to host Research on the Internet indicates this is usually due to a firewall problem. However, I use the Firewall Configuration application to the disable the firewall on both systems, and I continue to get the same result. What is needed so I can get this two machines to display their exported file shares remotely? It turns out I did not disable the firewall when I thought I had. Now that I'm certain the firewall is disabled on both systems, I'm able to get the showmount command to succeed.

View 5 Replies View Related

Ubuntu Networking :: Can't Ssh Into Computer - Says No Route To Host

Apr 11, 2010

I have 3 computers on a local home network. Computer 1 is not receiving incoming anything from other computers on the network, and I don't know why. The regular internet works fine. Computer 1 can ping and ssh into either 2 or 3. 2 can ping and ssh into 3 and vice versa. But nothing can ping OR ssh into 1. Trying to do so says "no route to host". All computers are running Ubuntu Karmic. I don't even know where to start figuring out what's causing this, but it's probably something simple. I'm using the IPs I found listed in my wireless router's web-based control panel.

View 9 Replies View Related

Networking :: Lamboot Error On Rsh: No Route To Host

Apr 3, 2010

I am using Fedora-10 on 64-bit quad-core xeon processors. I ran ssh-keygen and established passwordless connection between host-client and created a host file named lamhosts as follows:

172.16.122.11 cpu=4
172.16.122.21 cpu=4

where 11 is the host server and 21 is one of the nodes. When I executed 'lamboot -v lamhosts', it failed to boot nodes ssi:boot:base:linear: Failed to boot n1 (172.16.122.21). By googling, I found the error but couldn't yet find a solution.

View 1 Replies View Related

Networking :: No Route To Host Using Showmount On Fedora 12

Feb 13, 2010

I have two system, an Intel Core2 Duo system running the 32-bit version of Fedora 12, and a MacBook Pro running the 64-bit version of Fedora 12.

I'm using the Gnome desktop on each system. I have enabled all the services I believe are necessary to support NFS including nfs, rpcbind, rpcgssd, rpcidmapd, and rpcsvcgssd on each system.

I have added an entry to my /etc/exports file to export my home on each system, and if I type this command:
$ showmount -e localhost

I get a result like this: Export list for localhost: /home/tron 192.168.200.101,192.168.200.100

However when I issue this type of command: $ showmount -e <remote host name>

I get this kind of result: rpc mount export: RPC: Unable to receive; errno = No route to host

Research on the Internet indicates this is usually due to a firewall problem. However, I use the Firewall Configuration application to the disable the firewall on both systems, and I continue to get the same result.

What is needed so I can get this two machines to display their exported file shares remotely?

View 44 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved