MySQL don't start after installation

evernewbie

New member
Joined
Jan 25, 2011
Messages
21
After a new installation of DA I cannot start MySQL - clicking on "Start" results with nothing.

I've checked the reason -

/home/mysql/<HOSTNAME>.err is just empty.

Can someone help me please?
 
serwer:~# /etc/init.d/mysqld start
Starting mysqld: [ OK ]
serwer:~# nohup: redirecting stderr to stdout
 
No idea what to do, no reply from DA support, no live chat to ask... Great, really great...
 
I dont see how there is nothing in the error log.

/sbin/service mysqld restart

Did you check

/var/lib/mysql/hostname.err
 
serwer:~# /sbin/service mysqld restart
-bash: /sbin/service: No such file or directory
serwer:~# /var/lib/mysql/hostname.err
-bash: /var/lib/mysql/hostname.err: No such file or directory
serwer:~# /var/lib/mysql/vps.wroclaw.pl.err
-bash: /var/lib/mysql/my.domain.com.err: No such file or directory

Sorry, I'm not a Linux expert, maybe I type those commands wrong (I mean the hostname part)...?
 
Post here results

Code:
uname -a

and if you use any kind of Linux

Code:
hostname -f

than run

Code:
tail -20 /var/lib/mysql/`hostname -f`.err
 
First of all, thanks for your patience...

serwer:~# tail -20 /var/lib/mysql/server.mydomain.com.err
tail: cannot open `/var/lib/mysql/serwer.mydomain.com.err' for reading: No such file or directory

- I'm afraid, there is no such file on the server. Of course, I've entered my hostname carefully.
 
Is there any file in /var/lib/mysql/? Please, post all results here. It's important.

Code:
ls -l /var/lib/mysql/

and

Code:
ls -ld /var/lib/mysql/

What about

Code:
uname -a

I need to know your OS type to help more.

Code:
/etc/init.d/mysqld restart
 
Here they are:

serwer:~# ls -l /var/lib/mysql/
ls: cannot access /var/lib/mysql/: No such file or directory

serwer:~# ls -ld /var/lib/mysql/
ls: cannot access /var/lib/mysql/: No such file or directory

serwer:~# uname -a
Linux serwer.vps.wroclaw.pl 2.6.26-2-amd64 #1 SMP Thu Nov 25 04:30:55 UTC 2010 x86_64 GNU/Linux

serwer:~# /etc/init.d/mysqld restart
Stopping mysqld: [ FAILED ]
Starting mysqld: [ OK ]
serwer:~# nohup: redirecting stderr to stdout
 
Since you've got Debian you can use:

Code:
invoke-rc.d mysqld restart

Ok, just after mysql was restarted, is /var/lib/mysql/ still missing?

If yes, run

Code:
mkdir /var/lib/mysql
chown mysql:mysql /var/lib/mysql/
chmod 750 /var/lib/mysql/

Re-start mysql and do tail again for error log.
 
Still no such file or directory:

serwer:~#
serwer:~# invoke-rc.d mysqld restart
Stopping mysqld: [ FAILED ]
Starting mysqld: [ OK ]
serwer:~# nohup: redirecting stderr to stdout
ls -l /var/lib/mysql/
ls: cannot access /var/lib/mysql/: No such file or directory
serwer:~# ls -ld /var/lib/mysql/
ls: cannot access /var/lib/mysql/: No such file or directory
 
serwer:~# invoke-rc.d mysqld restart
Stopping mysqld: [ FAILED ]
Starting mysqld: [ OK ]
serwer:~# nohup: redirecting stderr to stdout

ls -l /var/lib/mysql/
ls: cannot access /var/lib/mysql/: No such file or directory
serwer:~# ls -ld /var/lib/mysql/
ls: cannot access /var/lib/mysql/: No such file or directory

serwer:~#
serwer:~# mkdir /var/lib/mysql
serwer:~# chown mysql:mysql /var/lib/mysql/
serwer:~# chmod 750 /var/lib/mysql/
serwer:~# /etc/init.d/mysqld start
Starting mysqld: [ OK ]
serwer:~# nohup: redirecting stderr to stdout

serwer:~# tail -20 /var/lib/mysql/serwer.vps.wroclaw.pl.err
tail: cannot open `/var/lib/mysql/serwer.vps.wroclaw.pl.err' for reading: No such file or directory
 
And what about

Code:
grep log /etc/my.cnf

?

Is there error log specified? Where is it located?

Try to check /var/log/message and/or /var/log/messagemessages.err

Is your mysql-server installed with directadmin or apt-get/aptitude?

Try

Code:
aptitude purge mysql-server
aptitude purge mysql-server-5.0
aptitude purge mysql-server-5.1

And than re-start.
 
All done, but there is still no error log...

All was installed with directadmin.

Here are the results:

serwer:~# grep log /etc/my.cnf

serwer:~# /var/log/message
-bash: /var/log/message: No such file or directory

serwer:~# /var/log/messagemessages.err
-bash: /var/log/messagemessages.err: No such file or directory

serwer:~# aptitude purge mysql-server
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done
Reading task descriptions... Done
No packages will be installed, upgraded, or removed.
0 packages upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 0B of archives. After unpacking 0B will be used.
Writing extended state information... Done
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done
Reading task descriptions... Done

serwer:~# aptitude purge mysql-server-5.0
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done
Reading task descriptions... Done
No packages will be installed, upgraded, or removed.
0 packages upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 0B of archives. After unpacking 0B will be used.
Writing extended state information... Done
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done
Reading task descriptions... Done

serwer:~# aptitude purge mysql-server-5.1
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done
Reading task descriptions... Done
Couldn't find any package whose name or description matched "mysql-server-5.1"
Couldn't find any package whose name or description matched "mysql-server-5.1"
No packages will be installed, upgraded, or removed.
0 packages upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 0B of archives. After unpacking 0B will be used.
Reading package lists... Done
Building dependency tree
Reading state information... Done
Reading extended state information
Initializing package states... Done
Reading task descriptions... Done

serwer:~# /etc/init.d/mysqld start
Starting mysqld: [ OK ]
serwer:~# nohup: redirecting stderr to stdout

serwer:~# tail -20 /var/lib/mysql/serwer.vps.wroclaw.pl.err
tail: cannot open `/var/lib/mysql/serwer.vps.wroclaw.pl.err' for reading: No such file or directory
serwer:~#
 
Have you ever had mysql working on your server?

I would try:

cd /usr/local/directadmin/custombuild
./build update
./build clean
./build mysql d
 
@scsi: yes. The story is: my server was working properly incl. MySQL. Unfortunately, the ISP did not installed the 'quota' command and had to reinstall DA. After that I cannot use it.

OK, I did what you suggested - here is the result:

serwer:~# cd /usr/local/directadmin/custombuild
serwer:/usr/local/directadmin/custombuild# ./build update
--2011-01-25 20:02:07-- http://files.directadmin.com/services/custombuild/1.1/custombuild.tar.gz
Resolving files.directadmin.com... 72.35.85.222
Connecting to files.directadmin.com|72.35.85.222|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 103676 (101K) [application/x-gzip]
Saving to: `./custombuild.tar.gz'

100%[======================================>] 103,676 116K/s in 0.9s

2011-01-25 20:02:08 (116 KB/s) - `./custombuild.tar.gz' saved [103676/103676]

extracting custombuild.tar.gz for 1.1 ...
custombuild/
custombuild/build
custombuild/configure/
custombuild/configure/pureftpd/
custombuild/configure/pureftpd/configure.pureftpd
custombuild/configure/ap1/
custombuild/configure/ap1/configure.php5
custombuild/configure/ap1/configure.apache_ssl
custombuild/configure/ap1/conf/
custombuild/configure/ap1/conf/mime.types
custombuild/configure/ap1/conf/httpd.conf
custombuild/configure/ap1/conf/extra/
custombuild/configure/ap1/conf/extra/httpd-vhosts.conf
custombuild/configure/ap1/conf/extra/httpd-deflate.conf
custombuild/configure/ap1/conf/extra/httpd-multilang-errordoc.conf
custombuild/configure/ap1/conf/extra/httpd-info.conf
custombuild/configure/ap1/conf/extra/httpd-alias.conf
custombuild/configure/ap1/conf/extra/httpd-userdir.conf
custombuild/configure/ap1/conf/extra/httpd-languages.conf
custombuild/configure/ap1/conf/extra/httpd-default.conf
custombuild/configure/ap1/conf/extra/httpd-autoindex.conf
custombuild/configure/ap1/conf/extra/directadmin-vhosts.conf
custombuild/configure/ap1/conf/extra/httpd-ssl.conf
custombuild/configure/ap1/conf/magic
custombuild/configure/ap1/configure.php4
custombuild/configure/ap2/
custombuild/configure/ap2/configure.php5
custombuild/configure/ap2/conf/
custombuild/configure/ap2/conf/httpd.conf_2.0
custombuild/configure/ap2/conf/mime.types
custombuild/configure/ap2/conf/httpd.conf
custombuild/configure/ap2/conf/extra/
custombuild/configure/ap2/conf/extra/httpd-vhosts.conf
custombuild/configure/ap2/conf/extra/httpd-deflate.conf
custombuild/configure/ap2/conf/extra/httpd-mpm.conf
custombuild/configure/ap2/conf/extra/httpd-multilang-errordoc.conf
custombuild/configure/ap2/conf/extra/httpd-mpm.conf_2.0
custombuild/configure/ap2/conf/extra/httpd-info.conf
custombuild/configure/ap2/conf/extra/httpd-alias.conf
custombuild/configure/ap2/conf/extra/httpd-userdir.conf
custombuild/configure/ap2/conf/extra/httpd-languages.conf
custombuild/configure/ap2/conf/extra/httpd-dav.conf
custombuild/configure/ap2/conf/extra/httpd-default.conf
custombuild/configure/ap2/conf/extra/httpd-autoindex.conf
custombuild/configure/ap2/conf/extra/directadmin-vhosts.conf
custombuild/configure/ap2/conf/extra/httpd-ssl.conf
custombuild/configure/ap2/conf/extra/httpd-manual.conf
custombuild/configure/ap2/conf/magic
custombuild/configure/ap2/cert_config
custombuild/configure/ap2/configure.apache
custombuild/configure/ap2/configure.php4
custombuild/configure/dovecot/
custombuild/configure/dovecot/dovecot.conf
custombuild/configure/proftpd/
custombuild/configure/proftpd/configure.proftpd
custombuild/configure/suphp/
custombuild/configure/suphp/configure.php5
custombuild/configure/suphp/configure.suphp
custombuild/configure/suphp/configure.php4
--2011-01-25 20:02:08-- http://files.directadmin.com/services/custombuild/versions.txt
Resolving files.directadmin.com... 72.35.85.222
Connecting to files.directadmin.com|72.35.85.222|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 4466 (4.4K) [text/plain]
Saving to: `./versions.txt'

100%[======================================>] 4,466 --.-K/s in 0.01s

2011-01-25 20:02:09 (385 KB/s) - `./versions.txt' saved [4466/4466]

File already exists: servers.txt
MD5 Checksum on servers.txt passed.
File already exists: httpd-2.2.17.tar.gz
MD5 Checksum on httpd-2.2.17.tar.gz passed.
File already exists: httpd_2
File already exists: httpd_2_freebsd
File already exists: httpd_2_debian
File already exists: mime.types
File already exists: mod_perl-2.0.4.tar.gz
MD5 Checksum on mod_perl-2.0.4.tar.gz passed.
File already exists: curl-7.21.3.tar.gz
MD5 Checksum on curl-7.21.3.tar.gz passed.
File already exists: pcre-8.10.tar.gz
MD5 Checksum on pcre-8.10.tar.gz passed.
File already exists: libmcrypt-2.5.8.tar.gz
MD5 Checksum on libmcrypt-2.5.8.tar.gz passed.
File already exists: mhash-0.9.9.9.tar.gz
MD5 Checksum on mhash-0.9.9.9.tar.gz passed.
File already exists: freetype-2.4.4.tar.gz
MD5 Checksum on freetype-2.4.4.tar.gz passed.
File already exists: libiconv-1.13.1.tar.gz
MD5 Checksum on libiconv-1.13.1.tar.gz passed.
File already exists: libxml2-2.7.6.tar.gz
MD5 Checksum on libxml2-2.7.6.tar.gz passed.
File already exists: libxslt-1.1.26.tar.gz
MD5 Checksum on libxslt-1.1.26.tar.gz passed.
File already exists: icu4c-4_4_1-src.tgz
MD5 Checksum on icu4c-4_4_1-src.tgz passed.
File already exists: php-5.2.17.tar.gz
MD5 Checksum on php-5.2.17.tar.gz passed.
File already exists: php-5.2.17-mail-header.patch
MD5 Checksum on php-5.2.17-mail-header.patch passed.
File already exists: webalizer-2.23-03-src.tgz
File already exists: suphp-0.7.1.tar.gz
MD5 Checksum on suphp-0.7.1.tar.gz passed.
File already exists: dovecot-2.0.9.tar.gz
MD5 Checksum on dovecot-2.0.9.tar.gz passed.
File already exists: dovecot.boot
File already exists: dovecot.boot.freebsd
File already exists: dovecot.boot.debian
File already exists: dovecot.conf
File already exists: exim.conf.dovecot.patch
MD5 Checksum on exim.conf.dovecot.patch passed.
File already exists: autoconf-2.67.tar.gz
MD5 Checksum on autoconf-2.67.tar.gz passed.
File already exists: m4-1.4.15.tar.gz
MD5 Checksum on m4-1.4.15.tar.gz passed.
File already exists: automake-1.11.1.tar.gz
MD5 Checksum on automake-1.11.1.tar.gz passed.
File already exists: libtool-2.4.tar.gz
MD5 Checksum on libtool-2.4.tar.gz passed.
serwer:/usr/local/directadmin/custombuild# ./build clean
serwer:/usr/local/directadmin/custombuild# ./build mysql d
ls: cannot access */: No such file or directory
Stopping mysqld ...
Stopping mysqld: [ FAILED ]
Starting mysqld: [ OK ]
Giving mysqld a few seconds to start up...
nohup: redirecting stderr to stdout
Looking for 'mysql' as: /usr/local/mysql/bin/mysql
Looking for 'mysqlcheck' as: /usr/local/mysql/bin/mysqlcheck
Running 'mysqlcheck'...
/usr/local/mysql/bin/mysqlcheck: Got error: 2002: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) when trying to connect
FATAL ERROR: Upgrade failed
Restarting MySQL.
Stopping mysqld: [ FAILED ]
Starting mysqld: [ OK ]
It is recommended to do "./build php n" after MySQL update.
nohup: redirecting stderr to stdout
serwer:/usr/local/directadmin/custombuild#
 
Back
Top