SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
That's just a warning message, it doesn't mean it's running or not.
First check if it's running with:
Code:
ps -A | grep mysql
If it's not...
Did you run mysql_install_db as mysql user? You can easily check that by checking database directory owner:
Code:
ls -l /var/lib/mysql
If it's not owned by mysql user, execute
Code:
chown -R mysql.mysql /var/lib/mysql
By the way, that procedure is explained in /etc/rc.d/rc.mysqld, remember to execute mysql using that file instead of manually running mysqld.
Another problem you may be having is that you're trying to connect using a network connection, you need to comment the SKIP line at /etc/rc.d/rc.mysqld in order to allow that.
As gbonvehi says, have a look at rc.mysqld in /etc/rc.d/. All is explained there in.
Quote:
#!/bin/sh
# Start/stop/restart mysqld.
#
# Copyright 2003 Patrick J. Volkerding, Concord, CA
# Copyright 2003 Slackware Linux, Inc., Concord, CA
#
# This program comes with NO WARRANTY, to the extent permitted by law.
# You may redistribute copies of this program under the terms of the
# GNU General Public License.
# To start MySQL automatically at boot, be sure this script is executable:
# chmod 755 /etc/rc.d/rc.mysqld
# Before you can run MySQL, you must have a database. To install an initial
# database, do this as root:
#
# su - mysql
# mysql_install_db
#
# Note that step one is becoming the mysql user. It's important to do this
# before making any changes to the database, or mysqld won't be able to write
# to it later (this can be fixed with 'chown -R mysql.mysql /var/lib/mysql').
# To allow outside connections to the database comment out the next line.
# If you don't need incoming network connections, then leave the line
# uncommented to improve system security.
#SKIP="--skip-networking"
You will notice that the line...
SKIP="--skip-networking"
is commented out above.
at the terminal as root open up pico
# pico /etc/rc.d/rc.mysqld
edit the file by placing a # before the said line.
Ctrl + x to close making sure you say yes to saving the file.
This maybe because you created the databases previously and never recreated them before trying mysql again.
Retrace your steps.
Sounds to me as though mysql is already running.
If you changed permissions on rc.mysqld to start at reboot then it will start everytime you boot your machine.
You will have to stop the running instance of mysql.
As root.
Quote:
/etc/rc.mysqld stop
Remain as root...
make sure Skip-networking is commented out before hand.
Recreate your databases...should destroy current databases and create new ones, will also destroy any previous accounts including passwords. It will also recreate the root acount but blow away the password you previously set.
Quote:
su - mysql
mysql_install_db
Now restart mysql
Quote:
/etc/rc.d/rc.mysqld start
Now try this...no password should be required...
Quote:
$ mysql -u root
If mysql starts okay - you should get the prompt
Quote:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 9
Server version: 5.0.37 Source distribution
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql>
Try to connect to the mysql database...and some query.
Quote:
mysql> use mysql;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
its not an issue, it did that to me on .37 and the .45 mysql package i made, and all runs fine, i have gallery2 and vcddb running fine and rather fast, even phpmyadmin works fine
Coyote, that's just a warning message, mysql will run fine. If you want to avoid seeing it, you can redirect the messages to a log file or just to /dev/null.
If you want that, edit /etc/rc.d/rc.mysqld and change the line:
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.