You are hereForums / Support / Apache on another port? [Resolved]

Videocache 2.1 is here :-) Check changelog for changes and new features in this version. Contact Us for your free upgrade!!

Apache on another port? [Resolved]


3 posts / 0 new
Last post
Offline
Joined: Jan 13 2009
Apache on another port? [Resolved]

I have an iptables entry to redirect 80 to 3128,

If I have apache on port 81 (so it doesn't loop continually)

Where would I set this for videocache?

Offline
Joined: Jan 13 2009

I solved this myself by adding an iptables entry with a -i eth0 redirect to port 3128.

sudo iptables -t nat -A PREROUTING -p tcp --dport 80 -i eth0 -j REDIRECT --to-port 3128

Basically, all incoming traffic for port 80 across that interface and internal traffic to the proxy itself goes to the correct port. This way apache can still run on port 80 as it needs to.

Also, the cache_host in the videocache.cfg had to be changed to the real outside world IP from 127.0.0.1

Noticed this during testing on Firefox when I saw the url_store_rewrite push the 127.0.0.1 address to the test pc. Obviously, it can't pull from itself since it's not a proxy.

Hope this helps anyone trying to get it working correctly.

Rafael Guedes's picture
Offline
Joined: Jan 9 2009

As its rule of iptables, is correct. The apache can continue listening on port 81 .. I have the same situation, you need only add a line in the apache configuration file:
Listen 81
Listen 80
... and give a reload in the service.

In videocache.cfg cache_host must be the IP of your internal network. Test and post their results. Greetings

My Book on Squid

Purchase/Renew

Go to Pricing page to purchase a new license or renew your existing license.

Recent comments

Who's online

There are currently 2 users and 149 guests online.