Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 09-24-2012, 04:14 PM   #1
Registered: Mar 2012
Location: Evansville,IN
Distribution: Chakra
Posts: 56

Rep: Reputation: Disabled
iptables help/SOCKS Proxy with Multiple IPs

I have a ubuntu server with a physical interface and virtual interface. I want to direct outgoing http traffic to broadcast from the virtual interfaces IP so that when I use it as a socks proxy, my IP displays as that of the virtual interface rather then physical interface. After weeks of searching I found an iptables rule that *should* work.
sudo iptables -t nat -A POSTROUTING -o eth0 -p tcp --dport 80 -j SNAT --to
I can not get the rules to save and take effect though.

First I run the iptables command above, then
sudo sh -c "iptables-save > /etc/iptables.rules"
I have edited /etc/network/interfaces and included:
post-up iptables-restore < /etc/iptables.rules
Then reboot. After rebooting I run iptables -L but no rules are present but I can check /etc/iptables.rules and see the rule present.

So this brings me to 2 questions:
1. Will the iptables rule listed do what I need?
2. Why are my iptables rules not applying?

Last edited by Xplorer4x4; 09-26-2012 at 03:03 PM. Reason: topic name changed
Old 09-26-2012, 03:03 PM   #2
Registered: Mar 2012
Location: Evansville,IN
Distribution: Chakra
Posts: 56

Original Poster
Rep: Reputation: Disabled
No one can help me with Iptables?


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Bind Failover IPs to users over SSH (using SOCKS) Tunnel SonicFire Linux - Networking 3 12-13-2011 07:54 AM
proxy server that accepts PARENT PROXY as a SOCKS PROXY shadyabhi Linux - Server 1 08-10-2010 03:09 PM
how to make socks proxies with ips of server Ruler123 Linux - Software 3 08-12-2009 01:11 PM
Getting things straight: Apache, SSL, Multiple External IPs / Internal IPs Linux - Server 21 10-13-2007 11:39 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:20 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration