{"id":8,"date":"2018-08-06T12:15:48","date_gmt":"2018-08-06T11:15:48","guid":{"rendered":"https:\/\/wissing.me\/daan\/blog\/?p=8"},"modified":"2018-08-06T12:15:48","modified_gmt":"2018-08-06T11:15:48","slug":"getting-wordpress-to-work-on-my-synology-nas","status":"publish","type":"post","link":"https:\/\/daan.wsng.eu\/index.php\/2018\/08\/06\/getting-wordpress-to-work-on-my-synology-nas\/","title":{"rendered":"Getting WordPress to work on my Synology NAS"},"content":{"rendered":"<p>The fact that I&#8217;m typing this means I&#8217;ve (somewhat) successfully installed WordPress on my Synology NAS! There are still some things to do (WP\/plugin updating doesn&#8217;t work yet, haven&#8217;t done anything about styling, writing a decent post&#8230;) but the base is standing.<\/p>\n<p>All of this should have only taken 5 minutes (as was promised on many places), but took way longer, of course because of my own stupidity. Here&#8217;s how it went:<\/p>\n<p><!--more--><\/p>\n<ul>\n<li>I downloaded the latest package from the WordPress site<\/li>\n<li>I unzipped and placed the content in the \/web\/daan\/blog directory on the NAS<\/li>\n<li>I opened good ol&#8217; Firefox and went to the website<\/li>\n<li>In a different tab I opened phpMyAdmin and created a database for WordPress<\/li>\n<li>First question was to give the root user + pass. My reaction: &#8220;Hell no, I&#8217;ll create a separate user for you, with only access to that table&#8221;. (Not that that was needed, WordPress was the only thing running in my database)<\/li>\n<li>WordPress: &#8220;Error establishing a database connection&#8221;.\n<p><figure id=\"attachment_12\" aria-describedby=\"caption-attachment-12\" style=\"width: 300px\" class=\"wp-caption alignright\"><img loading=\"lazy\" class=\"size-medium wp-image-12\" src=\"https:\/\/wissing.me\/daan\/blog\/wp-content\/uploads\/error-db-connection-300x157.jpeg\" alt=\"Database connection error\" width=\"300\" height=\"157\" srcset=\"https:\/\/daan.wsng.eu\/wp-content\/uploads\/error-db-connection-300x157.jpeg 300w, https:\/\/daan.wsng.eu\/wp-content\/uploads\/error-db-connection-768x401.jpeg 768w, https:\/\/daan.wsng.eu\/wp-content\/uploads\/error-db-connection-825x433.jpeg 825w, https:\/\/daan.wsng.eu\/wp-content\/uploads\/error-db-connection.jpeg 829w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><figcaption id=\"caption-attachment-12\" class=\"wp-caption-text\">This cannot be good&#8230;<\/figcaption><\/figure><\/li>\n<li>Me: &#8220;Shit. Maybe I need to change &#8216;localhost&#8217; to something else? Lets try.&#8221;<\/li>\n<li>WordPress: &#8220;Error establishing a database connection&#8221;.<\/li>\n<li>Me: &#8220;Dammit. Wait, what port is MySQL running on? Lets check that. Hmm, port 3307. Ah, yes, I have to use localhost:3307, now everything will work&#8221;.<\/li>\n<li>WordPress: &#8220;Error establishing a database connection&#8221;.<\/li>\n<li>Me: &#8220;Grr. OK, here is the bloody root user, I&#8217;ll change the password later&#8221;<\/li>\n<li>WordPress: &#8220;Error establishing a database connection&#8221;.<\/li>\n<li>Me: &#8220;Aargh!&#8221; [starts frantic googling] &#8220;Ok, let&#8217;s double check if the user rights are set correctly.&#8221;<\/li>\n<li>PHPMyAdmin: &#8220;Here are your users:&#8221;<\/li>\n<li>\n<figure id=\"attachment_10\" aria-describedby=\"caption-attachment-10\" style=\"width: 300px\" class=\"wp-caption alignright\"><img loading=\"lazy\" class=\"wp-image-10 size-medium\" src=\"https:\/\/wissing.me\/daan\/blog\/wp-content\/uploads\/any-user-300x188.png\" alt=\"phpMyAdmin users\" width=\"300\" height=\"188\" srcset=\"https:\/\/daan.wsng.eu\/wp-content\/uploads\/any-user-300x188.png 300w, https:\/\/daan.wsng.eu\/wp-content\/uploads\/any-user.png 704w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><figcaption id=\"caption-attachment-10\" class=\"wp-caption-text\">Users in a new installation of MySQL. Certainly nothing wrong with this&#8230;<\/figcaption><\/figure>\n<p>Me: &#8220;Hmm, what is this warning about having any user from any location?&#8221; [googles some more].<\/li>\n<li>Google: &#8220;Having any user from any location can clash with users that have a stricter definition, but more priviliges&#8221;<\/li>\n<li>Me: &#8220;Aha! Bye-bye, any user&#8221;<\/li>\n<li>WordPress: &#8220;Welcome to WordPress, please fill in these details to begin!&#8221;<\/li>\n<li>Me: &#8220;Woooo!&#8221;<\/li>\n<\/ul>\n<p>Tl;dr: Use the root user when installing WP. And make sure that the users in your DB are set properly, so no &#8220;Any&#8221; users. And don&#8217;t give up.<\/p>\n<p>Next up: set up FTP, so I can update WordPress and install\/update new shiny plugins&#8230;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The fact that I&#8217;m typing this means I&#8217;ve (somewhat) successfully installed WordPress on my Synology NAS! There are still some things to do (WP\/plugin updating doesn&#8217;t work yet, haven&#8217;t done anything about styling, writing a decent post&#8230;) but the base is standing. All of this should have only taken 5 minutes (as was promised on&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"twitterCardType":"","cardImageID":0,"cardImage":"","cardTitle":"","cardDesc":"","cardImageAlt":"","cardPlayer":"","cardPlayerWidth":0,"cardPlayerHeight":0,"cardPlayerStream":"","cardPlayerCodec":""},"categories":[3],"tags":[],"_links":{"self":[{"href":"https:\/\/daan.wsng.eu\/index.php\/wp-json\/wp\/v2\/posts\/8"}],"collection":[{"href":"https:\/\/daan.wsng.eu\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/daan.wsng.eu\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/daan.wsng.eu\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/daan.wsng.eu\/index.php\/wp-json\/wp\/v2\/comments?post=8"}],"version-history":[{"count":6,"href":"https:\/\/daan.wsng.eu\/index.php\/wp-json\/wp\/v2\/posts\/8\/revisions"}],"predecessor-version":[{"id":16,"href":"https:\/\/daan.wsng.eu\/index.php\/wp-json\/wp\/v2\/posts\/8\/revisions\/16"}],"wp:attachment":[{"href":"https:\/\/daan.wsng.eu\/index.php\/wp-json\/wp\/v2\/media?parent=8"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/daan.wsng.eu\/index.php\/wp-json\/wp\/v2\/categories?post=8"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/daan.wsng.eu\/index.php\/wp-json\/wp\/v2\/tags?post=8"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}