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.
Hello all, I've got a problem with mysql 4 in my Slack machine..
I've installed mysql in my compie, and the process is fine... But when I type mysql in shell, i found that the mysqld hasn't been run... ???? When I execute the mysqld, it prompts a while and ENDED !!!! I can't use mysql ... Please Help Me...
Actually, the command for MySQL 4 would be "mysqld_safe --user=root &". However, running as root is a bad idea and should only be done for testing purposes!
I'm willing to admit I'm wrong about this, but I don't think it is a bad thing to run mysqld as root. In fact I think most daemons(ssh,ftp,sendmail....) are run as root.
Now running the mysql client as root is a bad idea as you probably have unrestricted access to everything.
There have been some vulnerabilities in MySQL in the past that would allow mysql users to get root access to the machine if the daemon was run as root. These have been resolved but I still prefer not to run the daemon as root. It's a personal thing, I guess.
I run it as mysql, which is a user that only has rights to the MySQL data files.
When installing MySQL it's sometimes a bit tricky to get all the permissions right if you don't want to run it as root, but it will allow for a more secure system.
For MaMatO: If you start MySQL and all it gives you is "MySQL ended", a file called <machinename>.err is created in your MySQL data directory. This file contains the exact error messages which will allow you do diagnose the problem more accurately.
Where your data directory is located depends on the way you installed MySQL (Slackware pkg, source, MySQL binary).
Edit: One more thing: In most cases after installation you have to run an initialization script which will create the MySQL system tables and some other important things. It's called "mysql_install_db" if memory serves me. If these tables etc. are not created, you won't be able to run MySQL.
Originally posted by Hangdog42 I'm willing to admit I'm wrong about this, but I don't think it is a bad thing to run mysqld as root. In fact I think most daemons(ssh,ftp,sendmail....) are run as root.
Now running the mysql client as root is a bad idea as you probably have unrestricted access to everything.
Running the daemon as root allows any mysql user with FILE privs to write a file anywhere on the machine.
I am having similar problems. I tried some of the above and it seemed to work, but now when I issue the "show tables" command in the mysql database, I get an error that says:
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.