Upgrade to OS 5 broke MySQL connection

I do not know what is WD’s product manager thinking ? DB without remote access…

Seeing how WD broke the database connection and it doesn’t appear that they’re willing to open the port up again, I decided to take the NAS(s) out of the picture completely.

I had an extra Raspberry Pi 4 not being used and I setup a MySQL database on it along with phpMyAdmin and configured it to sync my media databases.

I guess I was a lot like other here, I used the NAS MySQL because it was already there and I didn’t have to create something from scratch. But, now I realized that I should have done this along time ago because we’re at the mercy of WD and you never know when they might change something, like they just did.

Now I just need the to fix the remote backup issue that I have. That one I’ve opened up a support ticket on. USB backups work just fine, but not remote backups.



I experience the same issue here. I had a Kodi and Home assistant bound to my NAS’s sql and am now completely blind…
And I really don’t like to have a house full of constantly operating electronic devices, each performing it’s thing if one is more than capable of running most of them.
I even tried to configure the address in /etc/my.cnf file but it is constantly rewritten after the system reset.
I suppose that the “upgrade click” was one of the greatest mistakes in my life since it brought me nothing but pain:)
Can we do anything to push on WD to bind the port to all interfaces instead of just locallhost?

1 Like

I can’t believe they don’t enable remote access to the DB. This broke my build. It makes no sense, why would I mount phpmyadmin only for apps running locally? does anybody know a way to rollback OS 5?

Same problem messed up my local database. Worst firmwareupgrade ever. I’m afraid there is no way back to OS3. phpmyadmin config is broken aswell since everytime i login (root) using the link via ex2 config i get kicked back to the phpmyadmin login screen when trying to click any option (e.g. status, settings, databases,…) :face_with_symbols_over_mouth:
If there wont be a fix until black friday i try to get another nas (qnap, synology,…)

all I’ve managed to do is:

  1. edit /etc/my.cnf to change to
  2. restart the mysql server by doing: python3 /usr/bin/mysql_reset.py --reboot

But this only lasts until my nas loses power. If you reboot your nas it won’t work anymore and you need to do it again. I’m not sure on how to fix this since the filesystem mounted is on ram (if you look at the output of: mount)

1 Like

That is so helpful, GREAT THANKS

Isn’t there any way to automate this process?

I couldn’t find any. I’m a developer but not super knowledgeable on linux commands. I think that the root is mounted on ram from something in the internal nas memory but I don’t know exactly how to access that or where to find it and I don’t have the time to dig deeper into it.

The problem is that any solution to get around these issues revolves around scripting in fixes that get reverted on a reboot or power loss.

I’ve had issues with this in the past when it came to keeping my NAS connected through a VPN, and there’s no real way to automate it as the filesystem is completely flashed back to default every time on boot and loaded back in fresh without the scripts running.

There’s no real way to automate restarting of the scripts on boot that I’ve found so far.

@htb The issue is not that phpMyAdmin cannot support remote access. The issue is that the database server itself cannot be accessed by clients. Which makes the NAS unusable for media server applications, especially with Kodi clients using the NAS as the mysql server.

1 Like

WD made the right call to close down external access to internal management DB

For those in need of an MySQL server, you can always run a second instance on another port.
Either by simply using the builtin daemon binary with your own config, or you can get a more recent version via Docker or Entware (both available in https://community.wd.com/c/OS5/developer-apps/276).
All you need to do is adjust the listen address and port.
The docker / entware routes are persistent over reboots.

Based on https://hub.docker.com/_/mysql and https://hub.docker.com/r/phpmyadmin/phpmyadmin/
Create docker-compose.yml somewhere on a persistent location.

# Use root/example as user/password credentials
version: '3.1'


    image: mysql
    command: --default-authentication-plugin=mysql_native_password
    restart: always
      MYSQL_ROOT_PASSWORD: example
      - 3307:3306

    image: phpmyadmin
    restart: always
      - 8080:80

Then run

docker-compose up -d

Bamn. 2 steps, without turning your NAS into a honeypot.
Welcome to 2020.

No its absolutely impossible to revert back to OS3 :face_with_symbols_over_mouth:https://support-en.wd.com/app/answers/detail/a_id/29382/

Yes I feel you I’m effing done with WD. Poor rollout of OS5, bad engineering lousy customer service. They’ve become a terrible company. I’ll be switching to Synology. OS5 rollout so poor and destructive, I'm switching brands to Synology after much research

1 Like

@Tfl Except that Docker isn’t installed in the new OS/5…

If anyone is still in warranty then keep putting pressure on WD to send you a new device as OS5 is not letting you have the same functions as os3 so it’s useless to some people or even limited.

It looks like that WD start to hate customers. I’m very upset about OS5 I loose mysql, the device is always turning around while doing indexing and creating nasyty previews I never used before.

So as shame on teh WD Product Owner. My next device is home build, sorry guys I nearly 30 years in that *nix business so I can do that, or I by a better product from an other company.

I personally am looking at turning my PR4100 into either OpenMediaVault or FreeNAS. There is a nice tutorial in the forums about using FreeNAS on the 4100.


Thanks for your help. You can easily add a crontab to exeute this commands:
Type in command line:

  • crontab -e
    add following lines:
    @reboot echo “[mysqld] bind-address=” > /etc/my.cnf
    @reboot python3 /usr/bin/mysql_reset.py --reboot

This means, after the reboot this two commands will be executed. I hope this will help you.

Unfortunately, these changes won’t persist after reboot. The crontab is copied over from a persistent store.