Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 2 > Installation/Configuration

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 30th June 2007, 19:43
dayjahone dayjahone is offline
Senior Member
 
Join Date: Jan 2007
Posts: 417
Thanks: 31
Thanked 0 Times in 0 Posts
Default Second Hard Drive

I installed ISPConfig, everything was working well. I added a second hard drive that is much larger than the other. So far, so good. I copied all of the files in /var to the new larger hard drive, mounted the new hard drive as /var and get the following error when I try to log in to ISPConfig:

Code:
Warning: mysql_connect() [function.mysql-connect]: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (111) in /home/admispconfig/ispconfig/lib/classes/ispconfig_db_mysql.lib.php on line 77

Warning: mysql_connect() [function.mysql-connect]: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (111) in /home/admispconfig/ispconfig/lib/classes/ispconfig_db_mysql.lib.php on line 77

Warning: Cannot modify header information - headers already sent by (output started at /home/admispconfig/ispconfig/lib/classes/ispconfig_db_mysql.lib.php:77) in /home/admispconfig/ispconfig/web/login/login.php on line 60
I ran umount /var for now. Can anyone tell me where I went wrong? Thanks.
Reply With Quote
Sponsored Links
  #2  
Old 30th June 2007, 22:03
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 35,457
Thanks: 813
Thanked 5,230 Times in 4,099 Posts
Default

Please restart mysql, do you get any errors? Have you preserved all permissions as you copied the files?
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #3  
Old 1st July 2007, 07:28
dayjahone dayjahone is offline
Senior Member
 
Join Date: Jan 2007
Posts: 417
Thanks: 31
Thanked 0 Times in 0 Posts
Default

I restarted with /var unmounted and now I can't access the ISPConfig login. I deleted the second hard drive from fstab and restarted. It didn't give any errors, but I still couldn't access ISPConfig. I added the hard drive to fstab again, restarted mysql and got the following:

Code:
root@mail:~# mount
/dev/sda1 on / type ext3 (rw,errors=remount-ro,usrquota,grpquota)
proc on /proc type proc (rw,noexec,nosuid,nodev)
/sys on /sys type sysfs (rw,noexec,nosuid,nodev)
varrun on /var/run type tmpfs (rw,noexec,nosuid,nodev,mode=0755)
varlock on /var/lock type tmpfs (rw,noexec,nosuid,nodev,mode=1777)
procbususb on /proc/bus/usb type usbfs (rw)
udev on /dev type tmpfs (rw,mode=0755)
devshm on /dev/shm type tmpfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
lrm on /lib/modules/2.6.20-15-generic/volatile type tmpfs (rw)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
/dev/sdb1 on /var type ext3 (rw,errors=remount-ro)
Code:
root@mail:~#  /etc/init.d/mysql restart
 * Stopping MySQL database server mysqld
   ...done.
 * Starting MySQL database server mysqld
   ...fail!
root@mail:~#
One thing I did differently from the instructions on this thread http://www.howtoforge.com/forums/sho...ght=hard+drive . . . I did not stop ISPConfig before copying. I copied it using the following command: cp -Rp /var/* /tempVar

Code:
root@mail:/# /etc/init.d/ispconfig_server restart
Shutting down ISPConfig system...
/root/ispconfig/httpd/bin/apachectl stop: httpd (no pid file) not running
ISPConfig system stopped!
Starting ISPConfig system...
/root/ispconfig/httpd/bin/apachectl startssl: httpd could not be started
Could not connect to MySQL server!ISPConfig system is now up and running!
root@mail:/#

Last edited by dayjahone; 1st July 2007 at 07:43.
Reply With Quote
  #4  
Old 1st July 2007, 11:11
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 35,457
Thanks: 813
Thanked 5,230 Times in 4,099 Posts
Default

This has all nothing to do with ISPConfig. Your problem is that mysql is not working and as long as mysql is not working, you can not start ISPConfig.

Have a look at your mysql and syslog and fix the mysql problem to be able to use ISPConfig again.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #5  
Old 1st July 2007, 18:12
dayjahone dayjahone is offline
Senior Member
 
Join Date: Jan 2007
Posts: 417
Thanks: 31
Thanked 0 Times in 0 Posts
Default

How can I diagnose the problem with mysql?

Here is what I found in /var/log/syslog:

Code:
Jul  1 07:46:36 mail postfix/pickup[13549]: warning: connect #1 to subsystem public/cleanup: Connection refused
Jul  1 07:46:46 mail postfix/pickup[13549]: warning: connect #2 to subsystem public/cleanup: Connection refused
Jul  1 07:46:56 mail postfix/pickup[13549]: warning: connect #3 to subsystem public/cleanup: Connection refused
Jul  1 07:47:06 mail postfix/pickup[13549]: warning: connect #4 to subsystem public/cleanup: Connection refused
Jul  1 07:47:16 mail postfix/pickup[13549]: warning: connect #5 to subsystem public/cleanup: Connection refused
Jul  1 07:47:26 mail postfix/pickup[13549]: warning: connect #6 to subsystem public/cleanup: Connection refused
Jul  1 07:47:36 mail postfix/pickup[13549]: warning: connect #7 to subsystem public/cleanup: Connection refused
Jul  1 07:47:46 mail postfix/pickup[13549]: warning: connect #8 to subsystem public/cleanup: Connection refused
Jul  1 07:47:56 mail postfix/pickup[13549]: warning: connect #9 to subsystem public/cleanup: Connection refused
Jul  1 07:48:06 mail postfix/pickup[13549]: warning: connect #10 to subsystem public/cleanup: Connection refused
Jul  1 07:48:16 mail postfix/pickup[13549]: fatal: connect #11 to subsystem public/cleanup: Connection refused
Code:
root@mail:~# netstat -tap
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name   
tcp        0      0 localhost:2208          *:*                     LISTEN     4667/hpiod          
tcp        0      0 *:mysql                 *:*                     LISTEN     5810/mysqld         
tcp        0      0 *:www                   *:*                     LISTEN     5445/apache2        
tcp        0      0 *:ftp                   *:*                     LISTEN     5630/proftpd: (acce 
tcp        0      0 mail.mydomain.co:domain *:*                     LISTEN     5595/named          
tcp        0      0 localhost:domain        *:*                     LISTEN     5595/named          
tcp        0      0 localhost:ipp           *:*                     LISTEN     4637/cupsd          
tcp        0      0 localhost:953           *:*                     LISTEN     5595/named          
tcp        0      0 *:smtp                  *:*                     LISTEN     5547/master         
tcp        0      0 *:https                 *:*                     LISTEN     5445/apache2        
tcp        0      0 localhost:2207          *:*                     LISTEN     4672/python         
tcp       17      0 localhost:smtp          localhost:3113          CLOSE_WAIT -                   
tcp6       0      0 *:imaps                 *:*                     LISTEN     4909/couriertcpd    
tcp6       0      0 *:pop3s                 *:*                     LISTEN     4951/couriertcpd    
tcp6       0      0 *:pop3                  *:*                     LISTEN     4926/couriertcpd    
tcp6       0      0 *:imap2                 *:*                     LISTEN     4882/couriertcpd    
tcp6       0      0 *:domain                *:*                     LISTEN     5595/named          
tcp6       0      0 *:ssh                   *:*                     LISTEN     5105/sshd           
tcp6       0      0 ip6-localhost:953       *:*                     LISTEN     5595/named          
tcp6       0      0 *:smtp                  *:*                     LISTEN     5547/master         
tcp6       0   2112 server1.mydomain.com:ssh   c-67-186-198-183.:65199 ESTABLISHED16494/0
Code:
root@mail:~# ls -l /home/admispconfig/ispconfig/lib/
total 68
-rwxr-xr-x 1 admispconfig admispconfig  5967 2007-06-30 10:30 app.inc.php
-rwxr-xr-x 1 admispconfig admispconfig  1768 2007-06-30 10:30 banner.inc.php
drwxr-xr-x 2 admispconfig admispconfig  4096 2007-06-30 10:34 classes
-rw------- 1 admispconfig admispconfig  7029 2007-06-30 10:30 config.inc.php
-rwxr-xr-x 1 admispconfig admispconfig   354 2007-06-30 10:30 copyright.inc.php
-rwxr-xr-x 1 admispconfig admispconfig  7480 2007-06-30 10:30 go_info.inc.php
drwxr-xr-x 2 admispconfig admispconfig  4096 2007-06-30 09:14 help
-rwxr-xr-x 1 admispconfig admispconfig   324 2007-06-30 10:30 index.php
drwxr-xr-x 2 admispconfig admispconfig  4096 2007-06-30 09:14 lang
drwxr-xr-x 2 admispconfig admispconfig  4096 2007-06-30 09:14 plugins
-rwxr-xr-x 1 admispconfig admispconfig     5 2007-06-30 10:30 preload.inc.php
-rwxr-xr-x 1 admispconfig admispconfig 10992 2007-06-30 10:30 session.inc.php
root@mail:~#

Last edited by dayjahone; 14th July 2007 at 00:00.
Reply With Quote
  #6  
Old 2nd July 2007, 09:39
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 35,457
Thanks: 813
Thanked 5,230 Times in 4,099 Posts
Default

Your mysqld is running but it seems not be able to accept connections.

Please stop mysql with its init script. If there is still a mysql process running when you check with netstat, then kill the mysql process with the "kill" command and start mysql again.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #7  
Old 2nd July 2007, 15:34
dayjahone dayjahone is offline
Senior Member
 
Join Date: Jan 2007
Posts: 417
Thanks: 31
Thanked 0 Times in 0 Posts
Default

I tried stopping and it was still running. I used the command "killall mysql" which stopped it. I then started mysql and restarted ISPConfig. I got the same error when restarting ISPConfig, and I still can't access the control panel on port 81. This happened when I rebooted the machine. Or did I mess up the tables when I copied everything from one drive to the other? I didn't stop mysql or ISPConfig before copying everything; however, it worked fine until I rebooted.


Code:
root@mail:~# killall mysqld
root@mail:~# netstat -tap
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name   
tcp        0      0 localhost:2208          *:*                     LISTEN     4667/hpiod          
tcp        0      0 *:www                   *:*                     LISTEN     683/apache2         
tcp        0      0 *:ftp                   *:*                     LISTEN     5630/proftpd: (acce 
tcp        0      0 mail.mydomain.co:domain *:*                     LISTEN     5595/named          
tcp        0      0 localhost:domain        *:*                     LISTEN     5595/named          
tcp        0      0 localhost:ipp           *:*                     LISTEN     4637/cupsd          
tcp        0      0 localhost:953           *:*                     LISTEN     5595/named          
tcp        0      0 *:smtp                  *:*                     LISTEN     821/smtpd           
tcp        0      0 *:https                 *:*                     LISTEN     683/apache2         
tcp        0      0 localhost:2207          *:*                     LISTEN     4672/python         
tcp       17      0 localhost:smtp          localhost:3113          CLOSE_WAIT -                   
tcp6       0      0 *:imaps                 *:*                     LISTEN     4909/couriertcpd    
tcp6       0      0 *:pop3s                 *:*                     LISTEN     4951/couriertcpd    
tcp6       0      0 *:pop3                  *:*                     LISTEN     4926/couriertcpd    
tcp6       0      0 *:imap2                 *:*                     LISTEN     4882/couriertcpd    
tcp6       0      0 *:domain                *:*                     LISTEN     5595/named          
tcp6       0      0 *:ssh                   *:*                     LISTEN     5105/sshd           
tcp6       0      0 ip6-localhost:953       *:*                     LISTEN     5595/named          
tcp6       0      0 *:smtp                  *:*                     LISTEN     821/smtpd           
tcp6       0   2592 mail.mydomain.com:ssh   rockland-router3.:50028 ESTABLISHED728/0
Code:
root@mail:~# /etc/init.d/mysql start
 * Starting MySQL database server mysqld
   ...done.
 * Checking for corrupt, not cleanly closed and upgrade needing tables.
Code:
root@mail:~# /etc/init.d/ispconfig_server restart
Shutting down ISPConfig system...
/root/ispconfig/httpd/bin/apachectl stop: httpd (no pid file) not running
ISPConfig system stopped!
Starting ISPConfig system...
/root/ispconfig/httpd/bin/apachectl startssl: httpd could not be started
ISPConfig system is now up and running!
Code:
root@mail:~# netstat -tap
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name   
tcp        0      0 localhost:2208          *:*                     LISTEN     4667/hpiod          
tcp        0      0 *:mysql                 *:*                     LISTEN     899/mysqld          
tcp        0      0 *:www                   *:*                     LISTEN     683/apache2         
tcp        0      0 mail.mydomain.co:domain *:*                     LISTEN     1158/named          
tcp        0      0 localhost:domain        *:*                     LISTEN     1158/named          
tcp        0      0 *:ftp                   *:*                     LISTEN     5630/proftpd: (acce 
tcp        0      0 localhost:ipp           *:*                     LISTEN     4637/cupsd          
tcp        0      0 localhost:953           *:*                     LISTEN     1158/named          
tcp        0      0 *:smtp                  *:*                     LISTEN     1204/smtpd          
tcp        0      0 *:https                 *:*                     LISTEN     683/apache2         
tcp        0      0 localhost:2207          *:*                     LISTEN     4672/python         
tcp        0      0 localhost:ftp           localhost:1716          TIME_WAIT  -                   
tcp        0      0 localhost:1570          localhost:www           TIME_WAIT  -                   
tcp       17      0 localhost:smtp          localhost:3113          CLOSE_WAIT -                   
tcp6       0      0 *:imaps                 *:*                     LISTEN     4909/couriertcpd    
tcp6       0      0 *:pop3s                 *:*                     LISTEN     4951/couriertcpd    
tcp6       0      0 *:pop3                  *:*                     LISTEN     4926/couriertcpd    
tcp6       0      0 *:imap2                 *:*                     LISTEN     4882/couriertcpd    
tcp6       0      0 *:domain                *:*                     LISTEN     1158/named          
tcp6       0      0 *:ssh                   *:*                     LISTEN     5105/sshd           
tcp6       0      0 ip6-localhost:953       *:*                     LISTEN     1158/named          
tcp6       0      0 *:smtp                  *:*                     LISTEN     1204/smtpd          
tcp6       0   3024 mail.mydomain.com:ssh   rockland-router3.:50028 ESTABLISHED728/0

Last edited by dayjahone; 14th July 2007 at 00:02.
Reply With Quote
  #8  
Old 2nd July 2007, 18:27
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,723 Times in 2,563 Posts
Default

Are there any errors in the ISPConfig Apache error log in /root/ispconfig/httpd/logs?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #9  
Old 2nd July 2007, 18:30
dayjahone dayjahone is offline
Senior Member
 
Join Date: Jan 2007
Posts: 417
Thanks: 31
Thanked 0 Times in 0 Posts
Default

root@mail:~# vim /root/ispconfig/httpd/logs/error_log:

Code:
[Sat Jun 30 10:30:25 2007] [error] mod_ssl: Init: Unable to read server certificate from file /root/ispconfig/httpd/conf/ssl.crt/server.crt (OpenSSL library error follows)
[Sat Jun 30 10:30:25 2007] [error] OpenSSL: error:0D06B08E:asn1 encoding routines:ASN1_D2I_READ_BIO:not enough data
[Sat Jun 30 23:09:26 2007] [error] mod_ssl: Init: Unable to read server certificate from file /root/ispconfig/httpd/conf/ssl.crt/server.crt (OpenSSL library error follows)
[Sat Jun 30 23:09:26 2007] [error] OpenSSL: error:0D06B08E:asn1 encoding routines:ASN1_D2I_READ_BIO:not enough data
[Sat Jun 30 23:14:17 2007] [error] mod_ssl: Init: Unable to read server certificate from file /root/ispconfig/httpd/conf/ssl.crt/server.crt (OpenSSL library error follows)
[Sat Jun 30 23:14:17 2007] [error] OpenSSL: error:0D06B08E:asn1 encoding routines:ASN1_D2I_READ_BIO:not enough data
[Sat Jun 30 23:19:36 2007] [error] mod_ssl: Init: Unable to read server certificate from file /root/ispconfig/httpd/conf/ssl.crt/server.crt (OpenSSL library error follows)
[Sat Jun 30 23:19:36 2007] [error] OpenSSL: error:0D06B08E:asn1 encoding routines:ASN1_D2I_READ_BIO:not enough data
[Sat Jun 30 23:34:32 2007] [error] mod_ssl: Init: Unable to read server certificate from file /root/ispconfig/httpd/conf/ssl.crt/server.crt (OpenSSL library error follows)
[Sat Jun 30 23:34:32 2007] [error] OpenSSL: error:0D06B08E:asn1 encoding routines:ASN1_D2I_READ_BIO:not enough data
[Sat Jun 30 23:42:56 2007] [error] mod_ssl: Init: Unable to read server certificate from file /root/ispconfig/httpd/conf/ssl.crt/server.crt (OpenSSL library error follows)
[Sat Jun 30 23:42:56 2007] [error] OpenSSL: error:0D06B08E:asn1 encoding routines:ASN1_D2I_READ_BIO:not enough data
[Mon Jul  2 07:28:28 2007] [error] mod_ssl: Init: Unable to read server certificate from file /root/ispconfig/httpd/conf/ssl.crt/server.crt (OpenSSL library error follows)
[Mon Jul  2 07:28:28 2007] [error] OpenSSL: error:0D06B08E:asn1 encoding routines:ASN1_D2I_READ_BIO:not enough data
Reply With Quote
  #10  
Old 2nd July 2007, 19:04
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,723 Times in 2,563 Posts
 
Default

Your SSL certificate is corrupt. Please create a new one: http://www.howtoforge.com/forums/showthread.php?t=121
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
The Following User Says Thank You to falko For This Useful Post:
dayjahone (2nd July 2007)
Reply

Bookmarks

Thread Tools
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Syncing two servers bagpiperdude90 Technical 4 18th March 2007 19:35
Additional Hard Drive Installation Problem msimpson7 Installation/Configuration 2 3rd September 2006 19:27
Hard Drive Failed Need Help mphayesuk Technical 1 28th April 2006 23:20
FC4 - How to remove LVM after hard drive crash? pudn Technical 4 10th April 2006 09:32
Suse 10 new Hard Drive install mphayesuk Installation/Configuration 5 1st November 2005 17:41


All times are GMT +2. The time now is 23:09.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.