Question

Can't change virtualhost listen port without crashing my site

  • Posted on July 21, 2014
  • dsanAsked by dsan

Hi, I am trying to configure Varnish in an Ubuntu 14.04 server running three virtual hosts and I am getting stuck in the previous step of changing listen port in apache ports.conf and sites-available/site.conf.

It doesn’t matter what port I try (recommended 8080, 8585, 4000, etc), after restarting the server I get a connection error when trying to visit my website.

Can you help me?

Show comments

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

This was solved after configuring varnish. Thanks.

Update:

site1.com:8080 returns the site. site2.com:8080 returns a 301 redirection to site2.com, which returns fetching error since tries to connect on port 80.

Thanks, I didn’t knew that. After changing ports to 8080 (8585 was not allowed) in in apache ports.conf and sites-available/site.conf I´m experiencing a strange behaviour:

site1.com:8080 returns a server error site2.com:8080 returns site1.com

Why is that?