Ubuntu: Error Changing MYSQL Data Directory



Question:

I was trying to change the mysql data directory following these instructions. When I try to restart the database with step 8:

sudo /etc/init.d/mysql restart  

Gets the following errror:

Rather than invoking init scripts through /etc/init.d, use the service(8)  utility, e.g. service mysql restart    Since the script you are attempting to invoke has been converted to an  Upstart job, you may also use the stop(8) and then start(8) utilities,  e.g. stop mysql ; start mysql. The restart(8) utility is also available.  start: Job failed to start  

When I try to start the database with:

service mysql start  

I get the following error message:

start: Rejected send message, 1 matched rules; type="method_call", sender=":1.71" (uid=1000 pid=3703 comm="start mysql ") interface="com.ubuntu.Upstart0_6.Job" member="Start" error name="(unset)" requested_reply="0" destination="com.ubuntu.Upstart" (uid=0 pid=1 comm="/sbin/init")  

after trying sudo mysql start I get Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »