var sidebar_align = 'right';
var content_container_margin = parseInt('350px');
var sidebar_width = parseInt('330px');
Need help regarding network routing
Hey Guys I've been using the method below so that this IP (22.214.171.124) will always be connect to eth0:0's IP
route add -net 126.96.36.199 gw 94.xx.xx.254 netmask 255.255.255.0 dev eth0:0
But it only works for port80 of 188.8.131.52 (i think). How do i do it for other port like 443?
Thanks alot (I'm willing to pay $10 to those who help me)
Last edited by kohkindachi; 05-15-2011 at
You can't do this (at all) with routing. You could create an IPTables forwarding rule, though...
You should be able to cobble together what you need from this page:
I've no idea how to dit
I'll be paying someone who can help me
Doing this with "dev eth0:0" is not the right way to do it.
where y.y.y.y is your IP that you want to use to reach that subnet.
ip route add 184.108.40.206/24 via 94.xx.xx.254 src y.y.y.y
Hi, I tried but
~]# ip route add 220.127.116.11/24 via 94.xx.xx.254 src 178.xx.xx.255
RTNETLINK answers: File exists
Ok, then, try this:
and see if it helps
ip route del 18.104.22.168/24
ip route add 22.214.171.124/24 via 94.xx.xx.254 src 178.xx.xx.255
ip route flush cache
By the way if your IP really ends with .255 this may cause all kind of problems to you.
Hi thanks. that /24 works for port 443?
Originally Posted by
It doesn't care about ports. All connections to 126.96.36.199/24 should be initiated with the specified source address, no matter the ports.
Thanks alot I'll try. But how can i check all/delete entry?
to list the routing table
ip route add ... to add entry
ip route del ... to delete
But be careful - don't delete your defaultroute
Ok I saw it. BTW will this work
ip route add 188.8.131.52/24 via 94.xx.xx.254 src 178.xx.xx.255 ?
I want it to be effective for 195.122.XX.XX, or 195.XX.XX.XX. How can i do it?
Sorry I'm really lousy at all these
195.122.x.x is 184.108.40.206/16 (=netmask 255.255.0.0)
195.x.x.x is 220.127.116.11/8 (=netmask 255.0.0.0)
But that IP ending with .255 is goind to cause you problems.
Restating the problem:
You want a specific host (18.104.22.168) to always connect to your server's eth0:0 IP.
You -cannot- control the IP that the host connects to with the route command on the server. The host is going to connect to whatever IP it wants on your server. The only thing you can do is redirect, using IPTables, all the traffic from that host to the subinterface you want it to go to.
By AsadMoeen in forum VPS Hosting
Last Post: 10-08-2010, 05:54 AM
By truenegative in forum Colocation and Data Centers
Last Post: 08-31-2009, 04:56 PM
By stevewest15 in forum Providers and Network Outages and Updates
Last Post: 12-03-2008, 01:33 PM
By servand in forum Colocation and Data Centers
Last Post: 09-22-2006, 01:51 PM
By gegeor in forum Providers and Network Outages and Updates
Last Post: 05-28-2005, 07:27 AM