Results 1 to 10 of 17
mmk.. i installed apache, php, and mysql tonight as it is told to on http://www.aboutdebian.com/internet.htm . all is well, except mysql is giving me some problems. im running debian sarge ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 08-18-2005 #1Linux Newbie
- Join Date
- Jul 2005
- Location
- Turn Around
- Posts
- 202
mySQL problems _-=SOLVED=-_
mmk.. i installed apache, php, and mysql tonight as it is told to on http://www.aboutdebian.com/internet.htm. all is well, except mysql is giving me some problems. im running debian sarge and i'm thru a linksys router connected via an ethernet cord. here are some errors im getting...
when i run 'mysql -u root'
when i run '/etc/init.d/mysql start'ERROR 2002: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
when i run 'mysqld'Starting MySQL database server: mysqld...failed.
Please take a look at the syslog.
/usr/bin/mysqladmin: connect to server at 'localhost' failed
error: 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)'
Check that mysqld is running and that the socket: '/var/run/mysqld/mysqld.sock' exists!
I'm stumped, i've checked IRC, and help is greatly appreciated.050817 22:34:22 Can't start server: Bind on TCP/IP port: Cannot assign requested address
050817 22:34:22 Do you already have another mysqld server running on port: 3306 ?
050817 22:34:22 Aborting
050817 22:34:23 mysqld: Shutdown Complete
Thanks!
-Dan
- 08-18-2005 #2
Just a shot in the dark.
Code:# mysqld -P 3305
- 08-18-2005 #3
You dont have a different SQL server running on your system that you dont know about do you?
Linux user #126863 - see http://linuxcounter.net/
- 08-18-2005 #4Just Joined!
- Join Date
- Jul 2005
- Location
- Malang, Indonesia
- Posts
- 53
Re: mySQL problems
Originally Posted by DoctorDan
i've got the same problem
Code:ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
so what must i do?
- 08-18-2005 #5Linux Newbie
- Join Date
- Jul 2005
- Location
- Turn Around
- Posts
- 202
it works all of a sudden, today
makes me happy. thanx to those that submitted some help
- 09-24-2005 #6Just Joined!
- Join Date
- Sep 2005
- Posts
- 1
Same Problem here.
I didn't configure my loopback-device correctly, so it wasn't brought up at boot-time (check with ifconfig if device 'lo' is displayed).
By default, mysqld listens to IP 127.0.0.1 Port 3306. If loopback is not active, binding to 127.0.0.1 fails and the server quits.
- 09-28-2005 #7Just Joined!
- Join Date
- Mar 2005
- Location
- Greece - Larissa
- Posts
- 31
Guys, I had the same problem and I sorted out using YaST (SuSE 9.3) - System - System Services (Runlevel)
- 10-08-2005 #8Just Joined!
- Join Date
- Oct 2005
- Posts
- 2
Sorry for bring back an old topic, but ive googled and googled and googled for weeks not trying to fix this same problem!! I figured ok its about time to ask on some fourms. No answer was put on this for me and i tried asking on the dev.mysql.com fourms but no one replied. This was my exact post can someone PLEASE help me.
once again sorry for bring back an old topic
Hello, im just starting to learn mysql/apache stuff and Im having some problems.
I am currently running debian.
I installed mysql and everything seemed fine, I made my root password.
So i do a
/etc/init.d/mysql start (as root)
and it starts up. I made sure by typing ps which then displays:
PID TTY TIME CMD
3335 pts/2 00:00:00 bash
3397 pts/2 00:00:00 mysqld_safe
3433 pts/2 00:00:00 mysqld_safe
3435 pts/2 00:00:00 logger
3479 pts/2 00:00:00 ps
Ok so now i try to connet to the mysql server via Navicat
I get this error: Can't connet to MySQL server on 'localhost' (10061)
So i figured this is a very common noobie prob so i figured i would google it.
I found alot of things saying "make sure mysql is running". So that didnt help me, as i can see its running.
I keept looking for a few days on how to fix this. I was led down the path to make sure my my.cnf was pointing to the correct mysqld.sock location. Which is its. So my search goes on.
I thought to myself is it safe to run mysql server as root? so i shut it down and tried to run it as my normal user. This is the error i get:
josh@joshua:/$ /etc/init.d/mysql start
Starting MySQL database server: mysqld...failed.
Please take a look at the syslog.
/usr/bin/mysqladmin: connect to server at 'localhost' failed
error: 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)'
Check that mysqld is running and that the socket: '/var/run/mysqld/mysqld.sock' exists!
Now im not sure where the syslog is >< im a noob. I tried googling but i guess im bad at googling cause i came up with nothing that would help me.
Im not sure whats going on...can anyone help me?
- 10-12-2005 #9Just Joined!
- Join Date
- Oct 2005
- Posts
- 4
You need to run the mysql damon as root. So don't worry about trying as another user.
Now, as far as navicat goes, you cannot connect as root (or whatever user you are attempting) because by default the users are made on mysql to only be allowed to connect from localhost. Using Navicate you're coming from another IP, not the localhost.
But first, from the command line, are you able to access mysql?
You should end up with a screen that looks something likeCode:# mysql
If so, your server is up. If not, what's your error message?Code:Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 2 to server version: 4.1.10a Type 'help;' or '\h' for help. Type '\c' to clear the buffer. mysql>
By they way, to exit, type 'quit' (no quotes).
My suggestion would to add another user to your mysql installation and not use root for everything. You'll need to add the user as a localhost user and as a remote user.
To do this, do the following while in the mysql prompt (by typing 'mysql' at the prompt or 'mysql -u root -p' (no quotes of course) if you've added a root password to the main mysql account):
Now the user josh is able to connect remotely and locally.Code:mysql> GRANT ALL PRIVILEGES ON *.* TO 'josh'@'localhost' IDENTIFIED BY 'some_pass' WITH GRANT OPTION; mysql> GRANT ALL PRIVILEGES ON *.* TO 'josh'@'%' IDENTIFIED BY 'some_pass' WITH GRANT OPTION; mysql> FLUSH PRIVILEGES;
let me know if this works for you or you have any more questions.
- 10-16-2005 #10
I have Debain Sarge running on my pc and i have installed mysql4 on my pc but, when i tried to run MySql by typing "mysql" at command console i get an error:
ERROR 2002: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
I thought the server is not up so i typed in "mysqld" then i get this error:
051017 0:06:18 Warning: Can't create test file /usr/local/mysql/data/debian.lower-test
051017 0:06:18 Can't find messagefile '/usr/local/mysql/share/mysql/english/errmsg.sys'
051017 0:06:18 Aborting
Quick help will be greately apprceiated
Registered Linux User#394486



