LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Trying to move datadir of mysql (https://www.linuxquestions.org/questions/linux-software-2/trying-to-move-datadir-of-mysql-413226/)

edudirectories 02-08-2006 08:30 PM

Trying to move datadir of mysql
 
I am using RHEL V4 with the default install of mysql 4.1.xx I am trying to move the data directory from the default of /var/lib/mysql to /studio folder which is another harddrive that is raid 5.

I have made the change in the my.cnf - copied the files over and can not seem to get mysqld started. I have even at one point made symbolic links from /var/lib/mysql to /studio folder.

If anyone has any feedback on how to move the data directory i would greatly appreciate it. I would like to keep all my data on the raid 5 drive and the OS on the raid 1 drive.

bathory 02-09-2006 01:12 PM

Try to start it using the datadir option:
Code:

mysqld --datadir=/studio -u mysql
and if it works change your startup script accordingly

edudirectories 02-10-2006 06:25 AM

Quote:

Originally Posted by bathory
Try to start it using the datadir option:
Code:

mysqld --datadir=/studio -u mysql
and if it works change your startup script accordingly


I think i found the issue. I am using RHEL 4 and it comes with selinux installed. I need to disable the mysqld option on it. I had the same issue with apache yesterday and i disabled it and it worked. I couldnt move any virtualhost directories


All times are GMT -5. The time now is 05:52 AM.