# Setting up second router with proxy server installed

## gothbox

im trying to setup a second router , to be used mostly for torrent traffic. 

now i have a router 10.0.0.1 and the second one is 10.0.0.2. Is there a way to setup some kind of proxy , that really does nothing but route all traffic via 10.0.0.2.

----------

## nativemad

Hi,

the only way to use multiple gateways on one box is via iproute2 and weights (to balance the traffic) or to make rules with different routing tables (like that destination or source ip and/or port should use that and that routing table).

If you've got another box (or vm), you could setup the second gateway just there and point different apps to use that proxy... But if you've got a second box anyway, you could also just start the application there to use the other route....

HTH, cheers

----------

## gothbox

ive got two boxes (one is vm, im just testing now).

routing could work, but its not optimal, i need to be able to make only some programs work via the proxy, like torrent and maybe skype. browsing and mostly all other trafic should go through the normal router. 

lets say ive got 4 clients, and 3-4 programs on each client. im to lazy to change routes and iptables rules everytime ive got new shit that should connect through the proxy.

Im using dante now. works like a charm with google chrome and regular browsing . but no torrent traffic is working . i keep getting "connection timed out." and ".... 518: remote closed" in the proxy logs.

is there a program that looks like a proxy, but in reality only routes traffic to a different gateway ?

----------

## nativemad

I would go for squid with socks enabled! -But honestly don't know if torrent works over it also...

----------

## _______0

per app routing can only be done with iptables I think.

----------

