Update MySQL

I have installed phpmyadmin and saw that the MySQL server is currently at version 5.1.56.
This version is very old and end of support was December 2013.
I would like to update MySQL but I am unable to figure out how.
Anybody has a clue?

I think another question to this is does the WD NAS have any valid attack vectors to it’s installed version of MySQL? Is this version being used possibly being extremely stable and NASs are designed to be on 24x7. It has been a long time since I’ve had to crash or cold reboot the WD NAS I’ve got. Quite possibly because I’ve not installed a newer version of something that has something Broken.

As an unrelated example. Plex. I updated the server and the result of that is the player on the SMART TV could not play some types of media, but Chromecast could. Reverted back a version and both devices play media perfectly.

Another example. The Voyager 2 probes using what is now VERY old technology. They are both still working.

New technology? A Microsoft quality update recently caused many people to lose valuable personal information within a matter of minutes.

Maybe WD are trying to operate under a policy of: “If it ain’t broken, don’t fix it”?

Still, it’s acknowledged that WD ate way to slow to release security updates and patches. :frowning:

I have the same question. How can a person upgrade MySQL as well as phpmyadmin?

Thanks

Daryl

The OS3 firmware stores the configuration (users, shares, settings, …) in the MySQL database. It’s really at the core of OS3 and I doubt they will update it.

I’ve made a phpMyAdmin upgrade here: https://bintray.com/tfl/wdpksrc/phpMyAdmin
It’s the latest version that still supports this old mysql version.

For your own databases, I’d recommend to use docker (compose) and the latest mysql version.
Here’s how to run mysql - phpmyadmin - wordpress

Get a recent Docker from wdcommunity.com
Get Docker compose

dc=/shares/Volume_1/Nas_Prog/docker/docker/docker-compose
curl -L --fail https://github.com/docker/compose/releases/download/1.23.2/run.sh -o $dc
chmod +x $dc

Then create a docker-compose.yml with this content (you may want to update the passwords)

version: '3.3'              
                                         
services:                       
   db:                      
     image: mysql:5.7                    
     volumes:                   
       - db_data:/var/lib/mysql  
     restart: always                     
     environment:                      
       MYSQL_ROOT_PASSWORD: somewordpress
       MYSQL_DATABASE: wordpress       
       MYSQL_USER: wordpress       
       MYSQL_PASSWORD: wordpress   
                                       
   wordpress:                           
     depends_on:                   
       - db                             
     image: wordpress:latest       
     ports:                        
       - "8000:80"                      
     restart: always               
     environment:                      
       WORDPRESS_DB_HOST: db:3306       
       WORDPRESS_DB_USER: wordpress    
       WORDPRESS_DB_PASSWORD: wordpress
       WORDPRESS_DB_NAME: wordpress     

   phpmyadmin:                     
     depends_on:                       
       - db                            
     image: phpmyadmin/phpmyadmin:latest
     ports:                            
       - "8080:80"                      
     restart: always               
     environment:                       
       WORDPRESS_DB_HOST: db:3306       
       WORDPRESS_DB_USER: wordpress
       WORDPRESS_DB_PASSWORD: wordpress 
       WORDPRESS_DB_NAME: wordpress     
                                       
volumes:                                
    db_data: {}                         

Then start the whole stack in daemon mode

docker-compose up -d

Et voila, you’ll have the latest wordpress / phpmyadmin at ports 8000 and 8080…

Thanks, was hoping to update the current WD one :slight_smile: I got the docker running

Hi,
Thanks for share.
This messages is old now there is a new version docker: 1.26
new link => https://github.com/docker/compose/blob/master/script/run/run.sh

I have this erors:./docker-compose up
standard_init_linux.go:211: exec user process caused “exec format error”
failed to resize tty, using default size

php -v

PHP 5.4.45 (cli) (built: Apr 9 2019 18:40:07)
Copyright © 1997-2014 The PHP Group
Zend Engine v2.4.0, Copyright © 1998-2014 Zend Technologies

I try to update PHP, was not possible…
I try to download last images:

docker image ls

REPOSITORY TAG IMAGE ID CREATED SIZE
wordpress latest 9f33a7011b85 6 days ago 407MB
phpmyadmin/phpmyadmin latest 6f9550cff175 3 weeks ago 468MB
resin/rpi-raspbian latest 28f1ee4d4d5a 17 months ago 128MB
docker/compose 1.23.2 65f21bf3ffc9 19 months ago 63.5MB
mysql 8.0.1 7896f0417528 3 years ago 262MB
armv7/armhf-php latest e7b67ea7db84 4 years ago 364MB

When try to create mysql:8.0.1 give and error…
Impossible to download other mysql versions (lastes)…

docker ps -a

CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
b4b2500dc729 phpmyadmin/phpmyadmin “/docker-entrypoint.…” 2 minutes ago Created 0.0.0.0:8081->80/tcp my-own-phpmyadmin
34c37915d209 mysql:8.0.1 “docker-entrypoint.s…” 3 minutes ago Exited (1) 3 seconds ago my-own-mysql

PHPMYADMIN do not give error… only php.
Thanks for the help.

root@WDMyCloudMirror docker # docker version
Client: Docker Engine - Community
Version: 19.03.5
API version: 1.19
Go version: go1.12.12
Git commit:
Built: Sat Nov 16 02:40:36 2019
OS/Arch: linux/arm
Experimental: false

Server: Docker Engine - Community
Engine:
Version: 19.03.5
API version: 1.40 (minimum version 1.12)
Go version: go1.12.12
Git commit: 633a0ea838
Built: Sat Nov 16 10:50:03 2019
OS/Arch: linux/arm
Experimental: false
containerd:
Version: v1.2.10
GitCommit: b34a5c8af56e510852c35414db4c1f4fa6172339
runc:
Version: 1.0.0-rc8+dev
GitCommit: 3e425f80a8c931f88e6d94a8c831b9d5aa481657-dirty
docker-init:
Version: 0.18.0
GitCommit: fec3683