Web server forwards to port 5000

Questions about hosting a Website, using MySQL, PhP or MariaDB may be posted here.
Forum rules
1) This is a user forum for Synology users to share experience/help out each other: if you need direct assistance from the Synology technical support team, please use the following form:
https://myds.synology.com/support/suppo ... p?lang=enu
2) To avoid putting users' DiskStation at risk, please don't paste links to any patches provided by our Support team as we will systematically remove them. Our Support team will provide the correct patch for your DiskStation model.
tau_ceti
Trainee
Trainee
Posts: 19
Joined: Sat Jul 20, 2013 6:37 am

Web server forwards to port 5000

Postby tau_ceti » Fri Feb 17, 2017 4:00 pm

Hi there,

For years I've had no trouble with my running a Web site off my Synology. Unfortunately I updated the DSM and Webstation in the latest of the (all too) many updates that come out and now the problems have begun.

Let's pretend my Web site is nonsenseandblather.org … 

If I go to nonsenseandblather.org, I get redirected to nonsenseandblather.org:5000
If I go to nonsenseandblather.org:80, I get redirected to nonsenseandblather.org:5000
If I go to nonsenseandblather.org:32400, I *correctly* go to nonsenseandblather.org:32400 and can watch my Plex videos.

(note … specifying the IP address from my LAN results in the same thing)

Webstation is currently set to Nginx (it was Apache).
Personal Website is disabled.
Virtual Host status is normal.
The Virtual Host is enabled. Port 80/443 is on, subfolder is web, which is where the index file lives.

Also shared file links no longer work, giving me "Sorry, the page you are looking for is not found." Even though these are of the form http://nonsenseandblather.org:5000/sharing/qCPpy9tAn ?
This has been a disastrous upgrade.

Any ideas?
wutikorn
I'm New!
I'm New!
Posts: 4
Joined: Thu Mar 23, 2017 3:25 pm

Re: Web server forwards to port 5000

Postby wutikorn » Thu Mar 23, 2017 4:03 pm

tau_ceti wrote:Hi there,

For years I've had no trouble with my running a Web site off my Synology. Unfortunately I updated the DSM and Webstation in the latest of the (all too) many updates that come out and now the problems have begun.

Let's pretend my Web site is nonsenseandblather.org … 

If I go to nonsenseandblather.org, I get redirected to nonsenseandblather.org:5000
If I go to nonsenseandblather.org:80, I get redirected to nonsenseandblather.org:5000
If I go to nonsenseandblather.org:32400, I *correctly* go to nonsenseandblather.org:32400 and can watch my Plex videos.

(note … specifying the IP address from my LAN results in the same thing)

Webstation is currently set to Nginx (it was Apache).
Personal Website is disabled.
Virtual Host status is normal.
The Virtual Host is enabled. Port 80/443 is on, subfolder is web, which is where the index file lives.

Also shared file links no longer work, giving me "Sorry, the page you are looking for is not found." Even though these are of the form http://nonsenseandblather.org:5000/sharing/qCPpy9tAn ?
This has been a disastrous upgrade.

Any ideas?

Did you set domain to NAS? This is what I did, not sure if I did too much or not

1. External Access-> Advanced -> enter your hostname there, add www. in front if needed. (Mine is www.mydomain.net) Not sure if "www." is needed, but I think it is.
2. Network -> DSM Settings-> Domain -> tick Enable customized domain, and HSTS(if you want), then put your domain (I put "mydomain.net" there).
3. Quick Connect -> Advanced -> Uncheck File Sharing //NAS will create link that use your domain name instead of quickconnect one.

I also advise you to use HTTPS on all connection. I use page rules in CloudFlare to redirect all traffic to HTTPS from HTTP.

If you use CloudFlare, use page rule to redirect subdomain to port 5001 of your NAS. For example, nas.nonsenseandblather.org redirects to https://www.nonsenseandblather.org:5001

I still don't understand why port 80 redirects you to port 5000, are you using revert proxy?
Epcylon
I'm New!
I'm New!
Posts: 2
Joined: Sat Apr 29, 2017 8:58 pm

Re: Web server forwards to port 5000

Postby Epcylon » Sat Apr 29, 2017 9:31 pm

tau_ceti wrote:Hi there,

For years I've had no trouble with my running a Web site off my Synology. Unfortunately I updated the DSM and Webstation in the latest of the (all too) many updates that come out and now the problems have begun.

Let's pretend my Web site is nonsenseandblather.org … 

If I go to nonsenseandblather.org, I get redirected to nonsenseandblather.org:5000
If I go to nonsenseandblather.org:80, I get redirected to nonsenseandblather.org:5000
If I go to nonsenseandblather.org:32400, I *correctly* go to nonsenseandblather.org:32400 and can watch my Plex videos.

(note … specifying the IP address from my LAN results in the same thing)

Webstation is currently set to Nginx (it was Apache).
Personal Website is disabled.
Virtual Host status is normal.
The Virtual Host is enabled. Port 80/443 is on, subfolder is web, which is where the index file lives.

Also shared file links no longer work, giving me "Sorry, the page you are looking for is not found." Even though these are of the form http://nonsenseandblather.org:5000/sharing/qCPpy9tAn ?
This has been a disastrous upgrade.

Any ideas?


I have experienced the exact same problem, although for me it only started happening the last week. It might be something with when updates to DSM are applied or something like that.

I have had two virtual hosts working fine on my DS213+ for over a year now, recently I added letsencrypt certificates as well. Two weeks ago an upgrade broke HTTPS, because Synology decided to change all vhosts back to using the default certificate on update, but that was easy enough to fix once I became aware of the problem. Then last week, another update, this time vhosts just doesn't work anymore. I'm using nginx as webserver.

I've tried looking at the nginx config, and it looks correct to me, but for some reason the included vhost configs aren't being used. When no vhost matches, the default server has a rule to redirect to port 5000.

I'm going to test switching to apache, in case the apache config isn't as broken, I'll report back if that helps..
Epcylon
I'm New!
I'm New!
Posts: 2
Joined: Sat Apr 29, 2017 8:58 pm

Re: Web server forwards to port 5000

Postby Epcylon » Sat Apr 29, 2017 10:00 pm

Epcylon wrote:I'm going to test switching to apache, in case the apache config isn't as broken, I'll report back if that helps..


Switching to apache didn't help, but then I uninstalled apache and web station and installed web station again, and now it works. I still don't understand what happened.
I can't see anything missing after reinstalling, even the configured vhosts are there, so it's a simple operation.

Return to “Web Server + PHP / MySQL + MariaDB”

Who is online

Users browsing this forum: No registered users and 3 guests