Mysql installation

php5 should allready be installed on your My Cloud by default. You could check via the following command in SSH

php -i

When installing mysql-server, did it complain about missing dependancies?

Also, what instructions are you following for the my book live?

these

http://mybookworld.wikidot.com/forum/t-371685

but did not install php5 mysql because of cake error

I’m confused, didn’t the cake error only appear when updating php itself, thus not when installing the php-mysql package?

It sure looks like that package is necessary for mysql to work

So i should not enconter any problem by installing php-mysql package?

joskevermeulen wrote:

php5 should allready be installed on your My Cloud by default. You could check via the following command in SSH

php -i

 

When installing mysql-server, did it complain about missing dependancies?

 

Yes some librarys wher missing

 

Also, what instructions are you following for the my book live?

yes

so i tried to install php5-mysql but it says i am missing php5-common

when i try to install php5-common it  say i already have newest version

is there a simple way to install all dependencies easily?

I’m not sure about xbmc but does it requires php to work with mysql? Not just direct tcp:3306? You’ll face lots of dependency issues trying to install php-mysql.

If I get you correctly you mentioned earlier you already have mysql installed and created the password. Was the mysql-server installation successful? If you happen to install mysql-client try “mysql -u root -p” and login to access your tables. Else try install some other webui such as phpmyadmin to access your mysqld. It should be running “ps -ef | grep mysql” by default on port 3306.

I’m on firmware v4 now with mysql 5.5.38 but I think I had a hard time installing mysql on firmware v3 due to dependencies…

Note that php-mysql below needs apache2 and php5 to be upgraded or you’ll break WD’s DashBoard:

i did install mysql-client  and i am able to login mysql show database and stuff

here’s what  i get from this command  ‘ps -ef | grep mysq’

Capture.JPG

also php version is  5.4.11-1

how more easy with 4.0 firmware?

I see that lots off people have done this successfully. Anyone CAN walk me throught

finally 

for anyone interested here’s how i did 

-first i did a system restore and went back to a unmodifed firmware.  so i could start over

i used those two command in putty

apt-get update (not upgrade, NEVER)

and then 

apt-get -f install mysql-server 

(-f stands for fixing)

created a password when prompt appeared

then i rebooted the wdmc (mycloud)

after that i re-opened putty and wrote:

mysql -uroot -p  (-u is for user and -p is for password)

entered password when asked

then i followed these instructions   http://wiki.xbmc.org/index.php?title=MySQL/Setting_up_XBMC

launched xbmc and voila!

2 Likes

I’m glad you figured it out!

Out of curiosity, why would you need mysql for xbmc? (I just recenly started using xbmc on a raspberry pi)

Unified library :wink:

Joskevermeulen Check this article

http://www.howtogeek.com/75535/how-to-sync-your-media-across-your-entire-house-with-xbmc/

Ok thanks! Having multiple xbmc clients never occured to me. The ammount of configurability of xbmc is amazing…

I tried doing this today and ran into some issues.

After apt-get -f install mysql-server I get some errors as shown in the attached log:

http://pastebin.com/download.php?i=BBYkuJLy

Then when I try to run mysqld I get the following:

/usr/sbin/mysqld: error while loading shared libraries: libaio.so.1: ELF load command alignment not page-aligned

I tried installing libsaoi1 but it seems like it’s already installed.  This is on a MyCloud running v04.00.00-607.

I am tempted to try restore - but will that not erase all my shared backups?

MyCloud:~# apt-cache policy libaio1
libaio1:
Installed: 0.3.109-4
Candidate: 0.3.109-4
Version table:
*** 0.3.109-4 0
500 http://ftp.us.debian.org/debian/ jessie/main armhf Packages
100 /var/lib/dpkg/status
0.3.109-3 0
500 http://ftp.us.debian.org/debian/ wheezy/main armhf Packages

“dpkg: warning: files list file for package ‘libpam-winbind:armhf’ missing; assuming package has no files currently installed”

The errors that you’re seeing above is normal when you try to “apt-get install” on this device because the packages has been modified by WD. It’s safe to ignore as long you didn’t remove/upgrade anything during the installations.

BUT the main “problem” is now you’re on firmware V4. You will not be able to use “apt-get install” successfully due to V4’s 64K memory page size. You’ll need to rebuild the debs patched with this new V4 requirement. See this thread for more info: [GUIDE] Building packages for the new firmware… someone tried it?

Doing a restore from WD’s Dashboard settings will not fix this, you’ll need to reflash the firmware. Download the V4 firmware manually and upgrade it from the Dashboard settings. It will not wipe your shared backups. If after the upgrade you see WD Dashboard acting weirdly, go to the settings again and do a “system” only restore. This will also preserve your shared backups.

I have MySQL installed on V4 but only after going through all the rebuild hassle. I would advise if you really want to have MySQL installed, downgrade to V3 to be able to use “apt-get install”. There’s two method, modify the upgrade script or the version file. Search this forum for details.

Thank you for the very detailed explanation of what is going on - very much appreciate the time you put into that response.

Building from source on another machine is likely over my head - it seems like the easiest thing to do would be to downgrade to version 3 of the firmware then install mysql.  

However - If I am understanding properly - upgrading to firmware 4 would then break my installation of mysql because it hasn’t been compiled with the proper options.

Building from source is not something I would want to undertake.  Too many steps for me to go wrong.

Seems like a pretty weird decision to handicap the hardware like this in version 4.  Is this something that is likely to change in the future?

No problem. If you read the thread link I posted from the very 1st post, try to understand and follow the steps given, you should have at least be able to build those simple deb like htop.

I’m afraid nothing will change in the future. WD seems to keep it this way. I haven’t installed the latest V4 released few days back but I did download and pull out the img file. It has the same 64k page size memory builds :frowning:

Thermo wrote:

Seems like a pretty weird decision to handicap the hardware like this in version 4.  Is this something that is likely to change in the future?

This might be an interesting read: http://yarchive.net/comp/linux/page_sizes.html

Also found this pretty decent explanation here:

Using large pages instead of the default 64K page size can improve application performance. The performance improvement of using large pages is a result of a more efficient use of the hardware translation caches which are used when translating application page addresses to physical page addresses. Applications that are frequently accessing a fast amount of memory benefit most from using pages sizes that are larger than 64K.

I presume this means they won’t go back on their decision, as the hardware is designed for a very specific purpose and not designed to run third party applications on. From their point of view breaking compatibility with 3rd party apps is likely a non-issue.

Hello,

I’m using the ‘Western Digital MyCloud 4tb’ as NAS server for my movie collection. I use XBMC/Kodi to control them. Now i would like to have XBMC/Kodi to synchronize with other computers. For that i have to install MySQL and phpMyAdmin on my WD MyCloud. Here starts a lot of trobble for me, I’m a computer amature and i can get it started. Is there someone who is so kind to explane to me step by step what i must do to get MySQL and phpMyAdmin installed on my WD MyCloud? The firmware is v04.01.02-417 so if i understand it correctly i have to downgrade it. Please help me out here. Thanks in advanced!

@barrychello

If you’re not comfortable with linux comand lines and have basic knowledge to do recovery from bricks, then we strongly don’t recommend you meddling with the nas WD’s core.

But if you insist, look for the thread by Fox_exe. Hes got the repository for v4 firmwares which means you don’t have to downgrade to install MySQL. phpMyAdmin is quite easy to install but requires extra module php5-mysql.