MySQL Issue on Start
Hi,
I installed some days ago slackware 13.1. However the mysqld daemon doesn't start on boot nor I can't start it on my own. I know that the mysqld is not configured in Slackware so I typed in my command line: Code:
mysql_install_db Code:
Installing MySQL system tables... Code:
100911 09:51:46 mysqld_safe Logging to '/var/lib/mysql/slackware_hostname.err'. Code:
Installing MySQL system tables... Thanks in advance |
Hi,
Have you also tried the steps as indicated in the output? Code:
Installation of system tables failed! Examine the logs in Eric |
Thanks EricTra for your response.
Yes I have tried them without any success. in "/var/lib/mysql" there are some probably log file which however I can't read them... e.g. ib_logfile0 Code:
offset 0 1 2 3 4 5 6 7 8 9 a b c d e f 0123456789abcdef I typed also "mysqld --help" and "mysqld --log" bu it doesn't find the command. Finally I tried also this: Code:
bash> /etc/rc.d/rc.mysqld start |
Hello,
Is there anything in the log files pointing to why MySQL is failing to start? Check Code:
/var/log/messages Kind regards, Eric |
Thanks again for your reply.
I haven't seen anything about mysql errors in /var/log/messages nor in syslog. What I did was: Code:
bash1>tail -f /var/log/messages Code:
Sep 9 14:45:11 slackware_hostname sshd[4244]: Failed password for mysql from 212.51.223.139 port 46327 ssh2 |
Perhaps starting again is in order..
I'll assume you have no valuable data in your database that is not backed up. Code:
rm -rf /var/lib/mysql/* http://connie.slackware.com/~mrgobli...ware-lamp3.php |
Thanks mRgOBLIN for your reply,
I have done all you 've told me but without any success. I get the same messages. However I have noticed the following: 1. There wasn't before a my.cnf file in /etc. 2. The folder /var/run/mysql is empty: a.When I start the server through "/etc/rc.d/rc.mysqld start" I can't see anywhere the "/var/run/mysql/mysql.pid 100912 11:00:59 mysqld_safe Logging to '/var/lib/mysql/slackware_hostname.err'. 100912 11:00:59 mysqld_safe Starting mysqld daemon with databases from /var/lib/ mysql 100912 11:00:59 mysqld_safe mysqld from pid file /var/run/mysql/mysql.pid ended b. And as I see in the file my.cnf the following file/var/run/mysql/mysql.sock is used, which it doesn't exist in my /var/run/mysql folder Because I have done a backup of slack 13.0 I see that in /var/run/mysql these 2 files, i.e. mysql.pid and mysql.sock, do exist. I don't know what is happening but I didn't have such problems with slackware 13.0. Everything was preinstalled in my system and ready to work. I don't know If I did something wrong during the installation of slackware. Also I wonder if it possible to uninstall completely mysql from my computer, not only the database files in /var/lib/mysql, and reinstall it. |
Yes that's probably advisable at this stage.
Make sure you have the correct package for the Slackware version you are using. Code:
removepkg mysql Why do you have a mysql user on your system with a usable shell account? And.. was it you that logged in as mysql via ssh? |
Two additional thoughts on this. One, does /var/log/mysqld.log exist, and if so is there anything interesting inside? And two, what exactly is the situation with the mysql account and the permissions on /var/lib/mysql? Does a mysql account exist or not? Does that account own everything in /var/lib/mysql? Can it write to /var/run? Are you using that account to start the database?
|
Quote:
|
Actually it was me...I have created a mysql user. I was trying to find out what is going on and I have given him permissions.
As far as it concerns the /var/run/mysql and /var/lib/mysql the mysql user is the owner. How do I remove access to the bash for mysql user? Finally, I make it work. What I did was: Code:
removepkg mysql I'm not so sure, but I think the problem was finally in the permissions of /var/run/mysql which was Code:
drwx------ 2 mysql mysql 4096 Sep 15 23:49 mysql Code:
drwxr-xr-x 2 mysql mysql 4096 Sep 15 23:49 mysql |
Quote:
Code:
usermod -s /bin/false mysql |
Thanks
|
I came across this thread because I want to setup LAMP on my slackware 13.1 x86 32 bit system. This thread helped me look for a solution different from what the original poster did.
The following worked for me when I executed the commands below as root user: !!NOTE!!: When I installed slackware 13.1, I did a complete/full install of all packages on the slackware dvd 1. # chmod 755 /etc/rc.d/rc.mysqld 2. # mysql_install_db --user=mysql 3. # cd /usr ; /usr/bin/mysqld_safe 4. # /usr/bin/mysqladmin -u root password 'new-password' 5. # /usr/bin/mysql_secure_installation |
Instructions I followed in setting up my LAMP
http://www.linuxquestions.org/questi...8/#post3390789 even though it says slackware 12.2, i used it for slackware 13.0 and 13.1 without a problem. I didn't encounter any problem in MySQL configuration when i followed the steps in here. |
All times are GMT -5. The time now is 02:09 PM. |