Device Full - Move MySQL folder

Dear all,

I want to use the MySQL server presents inside my EX2 Ultra in order to store a lot of data (around 140GB). These data came from a MySQL database settled in a PC (basically I want to replicate that database using a Python routine).
The problem is that I can store only around 600MB of data, because if I try to add more data I receive an error of “full device”. I’ve checked and I find the MySQL database is stored in the “/mnt/HD_a4” partition, which actually results 100% occupied.
How I can move the folder(s) where the MySQL database is saved? Can I use the main partition of the NAS (the one that is accesible with the file manager, just to be clear) as the location of the MySQL database?

Thank you all!

Hi all,

I’ve solved my problem. I put the solution here maybe it can help other people.
I’ve followed this guide only in these steps:

  • I’ve copied my data to the new folder
cp -R /mnt/HD_a4/.@database@/DATABASEFOLDER /mnt/HD/HD_a2/NEWFOLDER
  • I’ve removed my old dir from MySQL data files (be careful to backup for security)
rm -R /mnt/HD_a4/.@database@/DATABASEFOLDER
  • I’ve made a symlink back to MySQL data dir
ln -s /mnt/HD/HD_a2/NEWFOLDER /mnt/HD_a4/.@database@/DATABASEFOLDER

And all work perfectly. It is not needed to stop or reboot MySQL server, it works with the server still running. I’ve used PuTTY to connect to the NAS command line with SSH on.