Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

mysql Daemon problems

Status
Not open for further replies.

Halfcan

Technical User
Dec 8, 2002
214
US
Hello,

I've had mysql running for quite some time now, on a machine I rarely use. For some reason, mysql seems broken:

[andy@tunes mysql]$ mysql
ERROR 2002: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)

mysql Daemon is not running:
[andy@tunes mysql]$ ps -ef | grep mysqld
andy 2227 1775 0 13:48 pts/1 00:00:00 grep mysqld
[andy@tunes mysql]$


When I try to start mysqld I get these errors:

[andy@tunes mysql]$ mysqld start
041230 13:41:57 Warning: Can't create test file /var/lib/mysql/tunes.lower-test
041230 13:41:57 Warning: Asked for 196608 thread stack, but got 126976
041230 13:41:57 Can't start server : Bind on unix socket: Permission denied
041230 13:41:57 Do you already have another mysqld server running on socket: /var/lib/mysql/mysql.sock ?
041230 13:41:57 Aborting

041230 13:41:57 mysqld: Shutdown Complete

I'm running Redhat 7.3, and MYSQL 4.0.21-0

Any ideas?

Thanks,

HC
 
One thing to note, I can start mysqld_safe:

[root@tunes htdocs]# mysqld_safe
Starting mysqld daemon with databases from /var/lib/mysql

Thanks,
HC
 
Are you starting the server as user 'andy' or 'root'?
'andy' probably does not have write access to /vat/lib...



"If you always do what you've always done, you will always be where you've always been."
 

Hey rzs, thanks for the response. Actually both ways,
Check it out:

[root@tunes andy]# mysqld start
041231 10:43:26 Warning: Asked for 196608 thread stack, but got 126976
041231 10:43:26 Can't start server: Bind on TCP/IP port: Address already in use
041231 10:43:26 Do you already have another mysqld server running on port: 3306 ?
041231 10:43:26 Aborting

041231 10:43:26 mysqld: Shutdown Complete

[root@tunes andy]# exit
exit
[andy@tunes andy]$ mysqld start
041231 10:43:36 Warning: Can't create test file /var/lib/mysql/tunes.lower-test
041231 10:43:36 Warning: Asked for 196608 thread stack, but got 126976
041231 10:43:36 Can't start server: Bind on TCP/IP port: Address already in use
041231 10:43:36 Do you already have another mysqld server running on port: 3306 ?
041231 10:43:36 Aborting

041231 10:43:36 mysqld: Shutdown Complete

HC

[andy@tunes andy]$
 
OK, I think I've figured out half of my problem. If I attempt to start the server as user "mysql" then it starts.

but I still get the thread stack warning.

Does anyone know what this could mean?

Thanks.
hc


[root@tunes andy]# mysqld start --user=mysql
041231 11:16:41 Warning: Asked for 196608 thread stack, but got 126976
041231 11:16:44 InnoDB: Started
mysqld: ready for connections.
Version: '4.0.21-standard' socket: '/var/lib/mysql/mysql.sock' port: 3306 Official MySQL RPM
 
Try reducing the thread_stack parameter in my.cnf
 
I've checked on my Slackware and Suse machines,
They always start the daemon using mysqld_safe
Check: for some info.
Basically they say that mysqld_safe is the recommended way of starting MySQL on a Unix machine


"If you always do what you've always done, you will always be where you've always been."
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top