mysqld error : 'mysql ended'
I am getting this error at the time of booting of my machine and even if I want to run my mysql server by command prompt,
Error : Starting mysqld daemon with databases from /var/lib/mysql STOPPING server from pid file /var/run/mysql/mysql.pid mysql ended Why this error? Regards Anindyanuri |
Did you created the databases as stated in /etc/rc.d/rc.mysqld ?
|
first of all ii'm guesing you installed slackware and enabled mysql server.
what needs to be done after that is to run $>mysql_install_db from the prompt this will create the required user databases and put them in the right places. after that you need to edit the /etc/rc.d/rc.mysqld file and look for the command that runs mysqld and add --user=root to it. it won't allow the mysql server to start unless a valid user is starting it. root always works and if you create other administrators they can also start up the server. hope this helps |
cyberhawk, it's not good to run mysql daemon with root privileges. That's why there's a user called mysql and the daemon defaults to run with it.
If you read the instructions on /etc/rc.d/rc.mysqld it will instruct you on how to create the databases with the correct privlege (owned by mysql user). |
Quote:
I am not able to enter into the environment. /etc/rc.d/rc.mysqld also gives the same error, so I am not able to enter into mysql to make any database. Just reinstalled Slackware but strange...........a complete reinstall also giving the same problem. Seeking your help. Regards Anindyanuri |
Quote:
/etc/rc.d/rc.mysqld is producing an error which is same as my thread and quitting. How to proceed? Regards Anindyanuri |
You misunderstand.
Go back and read the MySQL manual (for your convience, it is located here: http://dev.mysql.com/doc/mysql/en/index.html ) or, as gbonvehi suggested, read the contents of /etc/rc.d/rc.mysqld (~$ less /etc/rc.d/rc.mysqld). To paraphrase: You must run a script *BEFORE* starting MySQL for the first time to instantiate some fixed databases (the mysql database itself, for example). Once that script has been run (and run correctly), then AND ONLY THEN, will you be able to type: ~$ /etc/rc.d/rc.mysqld start Please read the documentation provided with MySQL, all the information is in there. - Piete. |
Thank you for this wonderful clear picture. I am right now following your thread.
Tell you the result later. Thank you once again my friend. Regards Anindyanuri |
Big Thanks to the replys in here gave me direction on where to start looking to get mysql working
made the mistake of running mysql_install_db as root and needed to 'chown -R mysql.mysql /var/lib/mysql' that seemed to be the only thing stopping me good thing it told me that in the comments of /etc/rc.d/rc.mysql Tweter |
All times are GMT -5. The time now is 10:30 PM. |