Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 06-12-2006, 02:13 PM   #1
LQ Newbie
Registered: Jun 2006
Posts: 23

Rep: Reputation: 15
Help me intall Mysql in Linux

Hi all,

First of all, I am a super newbie at Linux and I am falling in love with it.

I have been trying to install Mysql for 2 days but I can't get it to work. I installed Mysql 3.23.38 something like that. It comes with the distribution. I am able to install it but when I try to create a root password like this: mysqladmin -u root password 'mypsw'
I get this message:
mysqladmin: connect to server at 'localhost' failed
error: 'Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' ( 2)'
Check that mysqld is running and that the socket: '/var/lib/mysql/mysql.sock' exists!
I try to locate mysql.sock and it does not exists..

So after searching hours for a solution I just cant find one. I had to uninstall Mysql. I tried two other Mysql versions 5.0.x and 4.1.x they both does not work. I am able to install them but when I type this in the terminal mysqladmin
it say bash error or file does not exists. So I use locate try to find it. Nope, I can't find it. Wow I can't do anything now. I am tired. Can someone please give me some advices. Please treat like a newbie and provide me examples of shell commands.

thank you very much
Old 06-12-2006, 02:45 PM   #2
Senior Member
Registered: Apr 2002
Location: Smithville, TN
Distribution: Slackware
Posts: 1,745

Rep: Reputation: 71
In Slackware you do this as root.
# mysql_install_db
# /etc/rc.d/rc.mysqld start
# mysqladmin -u root password 'password'

Then you can log in as the user root with the password you specified.

Some links are below.

If you are using redhat or a varient, here is some good easy to read tutorials.
Old 06-12-2006, 02:48 PM   #3
Senior Member
Registered: May 2003
Location: Sydney, Nova Scotia, Canada
Distribution: slackware
Posts: 4,185

Rep: Reputation: 59
Two questions based on what you wrote :
A) when you go the error regarded '/var/lib/mysql/mysql.sock' did you do as it said in the error and make sure that mysqld was running ?

B) If you open a terminal and just type "mysql" and press the TAB key twice do you see a bunch of output (approx. 30 commands), or does it just do nothing ?
Old 06-12-2006, 09:17 PM   #4
LQ Newbie
Registered: Jun 2006
Posts: 23

Original Poster
Rep: Reputation: 15
Yes Yes Yes, I got it to work. I typed in the terminal
mysql_install_db and it gave me instruction to setup root password and it works.
Wow your guys are good

thanks alot
Old 06-12-2006, 09:47 PM   #5
Senior Member
Registered: Apr 2002
Location: Smithville, TN
Distribution: Slackware
Posts: 1,745

Rep: Reputation: 71
Originally Posted by tzpow2k2
Wow your guys are good

thanks alot
Nah, I just beat my head against the wall for a while.
Old 06-13-2006, 03:13 AM   #6
Wim Sturkenboom
Senior Member
Registered: Jan 2005
Location: Roodepoort, South Africa
Distribution: Slackware 10.1/10.2/12, Ubuntu 12.04, Crunchbang Statler
Posts: 3,786

Rep: Reputation: 282Reputation: 282Reputation: 282
Us Slackers are just lucky. We read the script that will start mysql at boot and find the following info:
# Before you can run MySQL, you must have a database.  To install an initial
# database, do this as root:
#   su - mysql
#   mysql_install_db
Or we just read the user manual which can be found at
Old 06-13-2006, 06:42 AM   #7
Registered: May 2005
Location: solar-system->earth->northern hemisphere
Distribution: ubunutu+knoppix+suse
Posts: 197

Rep: Reputation: 31
i am not sure ... you could just use gaim insteed ,



Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to intall / to NFS ??? liutom Slackware 4 09-27-2004 10:22 AM
Can't Intall WineX tini1212 Linux - Newbie 3 08-31-2004 01:11 AM
How to intall a new kernel ( 2.6 ) on my linux machine wesleywest Linux - Newbie 5 08-29-2004 04:08 PM
can't login after first intall n00b_casp Slackware - Installation 4 08-01-2004 09:34 PM
intall problem citrus Slackware 5 02-04-2004 02:06 AM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:52 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration