WordPress Site Accessibility After DSM 6.0 Upgrade

Discussion room for Wordpress, a weblog based social networking community.
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://account.synology.com/support/su ... 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.
pbrigido
Novice
Novice
Posts: 44
Joined: Wed Aug 14, 2013 3:21 pm

Re: WordPress Site Accessibility After DSM 6.0 Upgrade

Unread post by pbrigido » Mon Apr 04, 2016 5:57 pm

cravaus wrote:My solution to the 404 error.

I do not know why this works given that Nginx is running. I made a new .htaccess file by going to Settings -> Permalinks and saving the settings and put it into my wordpress root. All my pages work now.

I still cannot update my plugins or Wordpress but I can navigate to my pages.

In Webstation we can select Nginx or Apache for the backend server. I have set them to either one and I get the same results, I cannot update and the .htacess file works.

Interesting, I may have to try the same thing. Just curious to know where you access "Settings -> Permakinks" at. Is that in Web Station or the DSM Control Panel?

Thanks!

-Phil

blim
Beginner
Beginner
Posts: 22
Joined: Mon Mar 28, 2016 8:19 pm

Re: WordPress Site Accessibility After DSM 6.0 Upgrade

Unread post by blim » Mon Apr 04, 2016 8:09 pm

Settings -> Permalinks is within the wordpress admin

cravaus
Novice
Novice
Posts: 58
Joined: Wed Jul 02, 2014 6:12 pm

Re: WordPress Site Accessibility After DSM 6.0 Upgrade

Unread post by cravaus » Mon Apr 04, 2016 10:52 pm

Solved-- FTP and SSL issues
The problem with the update of plugins and file upload issues for FTP turned out to be a port forwarding issue. Somehow a bunch of my ports had been diverted to odd places. I had to delete my past router configuration in the NAS and then go to my router and clean up anything that was left behind. I re ran the EZ-Internet utility. Still, 443 was being re routed to 5609 or something like that which messed up https connection to my website. Also FTP was re routed from 21 to something else (which is likely a good thing but would have been nice to know). I also found that FTP was tuned off in the fire wall of the NAS. I found similar problems with my mail server and other things. I had to manually set this all up with the NAS fire wall and my router because it just insisted on making 443 something else. Now, perhaps I should be making a reverse proxy to handle 443 or something. Perhaps that is what they intend. I am not sure but for now I have 443 working again and 21 is for FTP and Wordpress is now running with SSL and will upload files.

I still cannot get the Wordpress update to run. I may have to manually do that.

cravaus
Novice
Novice
Posts: 58
Joined: Wed Jul 02, 2014 6:12 pm

Re: WordPress Site Accessibility After DSM 6.0 Upgrade

Unread post by cravaus » Tue Apr 05, 2016 6:10 am

Regarding using the .htaccess solution. I made some observations here:
https://forum.synology.com/enu/viewtopi ... 03#p427303

Be sure that the permissions on the .htaccess are set to 0444 or it will disappear when the NAS is reset.

lavenetz
I'm New!
I'm New!
Posts: 7
Joined: Sat Nov 03, 2012 1:05 pm
Contact:

Re: WordPress Site Accessibility After DSM 6.0 Upgrade

Unread post by lavenetz » Tue Apr 05, 2016 3:53 pm

Hi,
when I try to update a WordPress plugin, I always get the message: To perform the requested action, WordPress needs to access your web server. Please enter your FTP credentials to proceed. If you do not remember your credentials, you should contact your web host.
Hostname: 111.222.333.444
FTP-Username: user with administrative rights
FTP-Password: xxxxx
FTPS (SSL)
Proceed
The result I get: Failed to connect to FTP Server 111.222.333.444:21
But the port 21 is forwarded by the router and enable in the DS-Firewall.
PS: This happens after updating DSM 5.2-5644 Update 5 to DSM 6.0-7321
Any suggestions?

cravaus
Novice
Novice
Posts: 58
Joined: Wed Jul 02, 2014 6:12 pm

Re: WordPress Site Accessibility After DSM 6.0 Upgrade

Unread post by cravaus » Wed Apr 06, 2016 2:35 am

I would look at your port assignment in the Diskstation. Control Pannel>External Access>Router Configuration and notice what it is doing with port 21. On mine, 21 was open on my NAS firwall and in the router 21 was reassigned to another port for incoming. So it was like 5060 incomming, and out to the NAS to 21. It did this for me. I did not set it up this way. And no matter what I did with the EZ-Internet it kept reassigning the incoming port. Check it out.

What I had to do was delete the configuration line for 21 in the NAS router configuration. I then manually opened port 21 on the router. The result is that port 21 does not show up in the router configuration on the NAS, but it is open nonetheless.

xakaseanx
I'm New!
I'm New!
Posts: 8
Joined: Mon Mar 28, 2016 5:40 am

Re: WordPress Site Accessibility After DSM 6.0 Upgrade

Unread post by xakaseanx » Sun Apr 10, 2016 6:30 am

Sorry, I have been pretty busy and have not had a lot of time to look into this. I got my test WordPress install set up, and I was able to get it working with the default permalinks. Unfortunately I am unable to log into my original WordPress install still. I am nearly certain now that the problem lies with DSM using Nginx after the update. It seems trying to use Apache does not have any effect on the test install at all. To sum up, here is where I am at:
mysite.com/clone/?cat=3 works fine
mysite.com/clone/category/category-name gives a 404

I ran into this related issue on stackoverflow.com, that is not getting much attention, when I was searching: http://stackoverflow.com/questions/3639 ... -avoid-404

WordPress has documentation for using Nginx which can be found here: https://codex.wordpress.org/Nginx

I am really not familiar with Nginx at this point, and also not familiar with the configuration in DSM as it relates to Nginx, so I do not have any answers at this time. If someone knows where the configuration should likely go, and what that might look like, I would love to hear about it. I will update when I have more information. Thanks!

xakaseanx
I'm New!
I'm New!
Posts: 8
Joined: Mon Mar 28, 2016 5:40 am

Re: WordPress Site Accessibility After DSM 6.0 Upgrade

Unread post by xakaseanx » Sat Apr 16, 2016 4:40 am

Hey, I finally spent some time reading up on Nginx and seeing what DSM does with it. So, DSM 6.0 uses Nginx now. If you choose Apache as your web backend, everything still runs through Nginx. As I mentioned, I am hosting a site that has a blog component, which is a manual install of WordPress. I have everything working now and running on Nginx. If you find yourself in my situation where you have your site and a directory in your site that houses your manual WordPress install, then here's how to get it working with Nginx:

You are going to need to SSH or Telnet in to get this done.

1) Open this file with your preferred editor:

Code: Select all

/etc/nginx/app.d/server.webstation-vhost.conf
2) You will have to update the server blocks that apply to your situation with something similar to this:

Code: Select all

location /blog {
	try_files $uri $uri/ /blog/index.php?$args;
}
Where /blog is your manual WordPress install directory. This should handle the "pretty" permalinks.

3) After you save your changes, run this:

Code: Select all

nginx -s reload
You should be in business after that. There is one caveat to all this: if you change your web backend or virtual host, this will get overwritten. I believe it also gets overwritten if Nginx resets (as opposed to being reloaded). Unfortunately, I do not know how to avoid that yet. At the moment and I am just happy to have everything working again. I hope this helps someone. Thanks for all your input.

EDIT: Actually, after messing with some PhotoStation and AudioStation, it seems like almost any setting you change will overwrite the server.webstation-vhost.conf changes. Does anyone know the place to make the changes such that it will not be overwritten?

camoguy
I'm New!
I'm New!
Posts: 1
Joined: Sat Apr 30, 2016 6:07 pm

Re: WordPress Site Accessibility After DSM 6.0 Upgrade

Unread post by camoguy » Sat Apr 30, 2016 6:23 pm

I used to have a working word press site until the update happened for me (6). I am not a very methodical person and tend to jump between posts and blogs attempting to figure out what I had done wrong. I have been through many of the steps outlined and to no avail, 404 message when attempting to access the site from my phone or from external access. Getting to it internally was working (admin WP) but basic functions stopped, update wordpress automatically, retrieving passwords from locked accounts etc.
Yesterday I finally decided I needed fresh start, so I went with the wiping plan. I uninstalled everything. rebooted the 214+. I brought up instructions on how to create a BLOG on your DSM cloud. I even went into my Router and cleaned all the port forwarding I originally had setup.
My question is to anyone reading this, is there a single site that would help a "green" site builder with hosting my own site so I can simply post from my iphone WP APP? Seems so simple however it is not. Honestly I had it up and running years ago, I was using the PRESS THIS to quickly post videos, pictures, articles right from my phone to my blog. Honestly I am to the point now that I want to go back to "GO DADDY" which who I pay for my domain name and start hosting my blog there. It just thought I could save money by hosting my own small blog. Hope this doesnt sound like wine and cheese party, just aggravated at myself for not having the skill sets in PHP, etc. For the beginner self hosting blogger, I was doing well until the update.
Moral is checking my port forwarding, wiping out everything and going to scratch allowed me to create a template site however I cannot connect to it via my phone through the WP APP nor can I maneuver through admin console like I used to.

Faecon
I'm New!
I'm New!
Posts: 6
Joined: Thu Jul 11, 2013 12:23 pm

Re: WordPress Site Accessibility After DSM 6.0 Upgrade

Unread post by Faecon » Tue May 10, 2016 3:15 pm

Anyone found a solution for the 404 ?

bluyten
I'm New!
I'm New!
Posts: 1
Joined: Sat May 21, 2016 3:40 pm

Re: WordPress Site Accessibility After DSM 6.0 Upgrade

Unread post by bluyten » Sat May 21, 2016 3:43 pm

The solution to the 404 problem posted by cravaus on April 4th works for me. Specifically created an account to thank him/her for the contribution!

GrayeDog
I'm New!
I'm New!
Posts: 5
Joined: Wed Sep 30, 2015 4:33 am

Re: WordPress Site Accessibility After DSM 6.0 Upgrade

Unread post by GrayeDog » Wed Feb 08, 2017 1:48 am

Has anyone come up with a solid solution for this? I just updated permalinks and I too am getting 404s for everything besides my homepage. I currently have my site set up with a Virtual host from my domain name to /web/wordpress, and I have verified that Web Station is set up to use Apache 2.2 (though switching to Apache 2.4 hasn't seemed to matter either). My /web/wordpress/.htaccess file currently looks like this:

Code: Select all

Options +FollowSymlinks
Options +SymlinksIfOwnerMatch

# Synology PHP
AddHandler default-handler .htm .html .shtml
AddHandler php-fastcgi .php
AddType text/html .php
Action php-fastcgi /php56-fpm-handler.fcgi
# Synology PHP

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

# END WordPress
I cannot for the life of my figure out what I need to actually to do make this work. Some people have said mod_rewrite will work if Web Station is set to Apache, others have said regardless of what I've selected, nginx is being used in the back-end. Can I use apache and if so, what am I missing / what do I need to do to fix permalinks? I'm not even sure how I restart apache if I update my .htaccess file.

If I can't use apache, what do I do instead? I've seen plenty of information suggesting some sort of try_files rule with nginx, but I'm just not nearly enough of an expert to know where I'd put this within the nginx file, or what to do about the issues I've read that the nginx config can get reset for a number of reasons.

I'd love to be able to use permalinks but I am rather lost right now. Help, please!

GrayeDog
I'm New!
I'm New!
Posts: 5
Joined: Wed Sep 30, 2015 4:33 am

Re: WordPress Site Accessibility After DSM 6.0 Upgrade

Unread post by GrayeDog » Wed Mar 15, 2017 11:24 pm

Bump -- does anyone have an answer? I know I can't be the only person who's attempted to use Permalinks with a Synology Wordpress installation, and I know one of you out there has to have solved it!

Thanks in advance!

Post Reply

Return to “Wordpress”