I would try my best to find a way to login as root or maybe user mysql. 

John Mancuso
Linux Administrator/MySQL DBA
IT Infrastructure
American Home Mortgage
w: 631-622-6382
c: 516-652-2475

-----Original Message-----
From: Ahamarshan jn [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, June 19, 2007 12:48 PM
To: John Mancuso
Subject: RE: ERROR 2002 (HY000): Can't connect to local MySQL server

 mysqld_safe
Starting mysqld daemon with databases from /var/lib/mysql STOPPING
server from pid file /var/run/mysqld/mysqld.pid
070619 17:40:10  mysqld ended

--- John Mancuso <[EMAIL PROTECTED]> wrote:
Hiya,
 These are the outputs i get when using mysqld_safe --console as root
mysqld_safe --console Starting mysqld daemon with databases from
/var/lib/mysql STOPPING server from pid file /var/run/mysqld/mysqld.pid
070619 17:45:48  mysqld ended


as user
[EMAIL PROTECTED] mysql]$ mysqld_safe --console
Starting mysqld daemon with databases from
/var/lib/mysql
/usr/bin/mysqld_safe: line 363:
/var/log/mysqld/mysqld.log: Permission denied
rm: cannot remove `/var/lib/mysql/mysql.sock':
Permission denied
/usr/bin/mysqld_safe: line 371:
/var/log/mysqld/mysqld.log: Permission denied
STOPPING server from pid file
/var/run/mysqld/mysqld.pid
tee: /var/log/mysqld/mysqld.log: Permission denied
070619 17:46:52  mysqld ended
tee: /var/log/mysqld/mysqld.log: Permission denied

I could not locate the logdirectory, any pointers to
this please?
- ash#





> Start mysqld_safe with --console OR
> --error-log=/<logdirectory>/errlog.err
> 
> --console will print your errors to the screen 
> 
> ./mysqld_safe --console
> 
> John Mancuso
> Linux Administrator/MySQL DBA
> IT Infrastructure
> American Home Mortgage
> w: 631-622-6382
> c: 516-652-2475
> 
> -----Original Message-----
> From: Ahamarshan jn [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, June 19, 2007 12:25 PM
> To: John Mancuso
> Subject: RE: ERROR 2002 (HY000): Can't connect to
> local MySQL server
> 
> Hiya,
>  I could not find .err file anywhere.
> and my mysql.sock file is showing 0 bytes in it.
> - ash#
> 
> --- John Mancuso <[EMAIL PROTECTED]>
> wrote:
> 
> > Have you looked in your mysql error log in your
> data directory? Check 
> > /<datadir>/<hostname>.err
> > 
> > FYI- the locate command needs to be updated. It
> can show old info if 
> > you don't run updatedb frequently
> > 
> > 
> > John Mancuso
> > Linux Administrator/MySQL DBA
> > IT Infrastructure
> > American Home Mortgage
> > w: 631-622-6382
> > c: 516-652-2475
> > 
> > -----Original Message-----
> > From: Ahamarshan jn [mailto:[EMAIL PROTECTED]
> > Sent: Tuesday, June 19, 2007 11:54 AM
> > To: mysql@lists.mysql.com
> > Subject: ERROR 2002 (HY000): Can't connect to
> local MySQL server
> > 
> > Hi,
> >  I was appending Grant previledges to some
> databases in mysql; either 
> > i typed something wrong or there is a bug which I
> am uncertain about, 
> > but what happened was I could not login as su
> anymore. I then solved 
> > this problem by changing grp (chgrp) permission in
> /bin/su and it 
> > works fine.
> > 
> > However I could not connect to mysql again
> > 
> > When I start mysql I get the following error $
> mysql ERROR 2002 
> > (HY000):
> > Can't connect to local MySQL server through socket
> 
> > '/var/lib/mysql/mysql.sock'
> > (111)
> > 
> > I could not start nor stop any running mysql I
> tried to reboot my 
> > system hoping that the process will terminate and
> restart fresh but 
> > during shutdown I see the message that mysql
> shutdown failed. Upon 
> > booting again I could not start mysql
> > 
> > Even though it shows the file here
> > [EMAIL PROTECTED] locate mysql.sock
> > /var/lib/mysql/mysql.sock
> > 
> > the cat of my.cnf is
> > 
> > $ cat my.cnf
> > 
> > [mysqld]
> > datadir=/var/lib/mysql
> > socket=/var/lib/mysql/mysql.sock
> > 
> > # Default to using old password format for
> compatibility with old and 
> > # shorter password hash.
> > # Reference:
> >
>
http://dev.mysql.com/doc/mysql/en/Password_hashing.html
> > old_passwords=1
> > 
> > [mysql.server]
> > user=mysql
> > basedir=/var/lib
> > 
> > [mysqld_safe]
> > err-log=/var/log/mysqld/mysqld.log
> > pid-file=/var/run/mysqld/mysqld.pid
> > 
> > Also I tried to kill mysql by using PID ie kill 
> -9 'PID'
> > but each time the PID changes when i do ps
> -ax|grep mysql and it fails
> 
> > to kill mysql.
> > 
> > Can some Mysql messiah help me solve this problem.
> > 
> > Thank you in advance
> > - ash#
> > PS: I guessed it was quite a common error but when
> searched through 
> > the list it retrived me null post, hence I am
> posting this.
> > 
> > --
> > MySQL General Mailing List
> > For list archives: http://lists.mysql.com/mysql To
> unsubscribe:
> >
>
http://lists.mysql.com/[EMAIL PROTECTED]
> > 
> > 
> 
> 
> --
> MySQL General Mailing List
> For list archives: http://lists.mysql.com/mysql
> To unsubscribe:   
>
http://lists.mysql.com/[EMAIL PROTECTED]
> 
> 


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to