1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice
  2. Dear Pleskians, please read this carefully! New attachments and other rules Thank you!
    Dismiss Notice
  3. Dear Pleskians, I really hope that you will share your opinion in this Special topic for chatter about Plesk in the Clouds. Thank you!
    Dismiss Notice

Everytime stats are run, /var partition goes under read only mode

Discussion in 'Plesk 9.x for Linux Issues, Fixes, How-To' started by SalvadorS, Dec 17, 2009.

  1. SalvadorS

    SalvadorS Regular Pleskian

    29
    90%
    Joined:
    Nov 12, 2009
    Messages:
    282
    Likes Received:
    2
    Hello,

    I have to disable statistics on plesk because everytime this command was run /var partition goes into read mode only and I have to reboot the server.

    I disable all statistics and try to run script.php manually:

    /usr/local/psa/bin/sw-engine-pleskrun /usr/local/psa/admin/plib/DailyMaintainance/script.php

    And this is the error:

    ns1:/usr/local/psa/admin/sbin# /usr/local/psa/bin/sw-engine-pleskrun /usr/local/psa/admin/plib/DailyMaintainance/script.php
    statistics: Mysql server has gone away. Trying to reconnect
    statistics: Unable to connect to Plesk Database: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (111)
    System error 111: Connection refused
    statistics: Unable to reconnect to the mysql database

    System error 111: Connection refused
    [Thu, 17 Dec 2009 12:48:30 +0100] ! 1 Error: Execution failed: statistics: Mysql server has gone away. Trying to reconnect
    statistics: Unable to connect to Plesk Database: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (111)
    System error 111: Connection refused
    statistics: Unable to reconnect to the mysql database

    System error 111: Connection refused
    [Thu, 17 Dec 2009 12:48:30 +0100] ! 0 Error: Unable to connect to database: MySQL server has gone away
    [Thu, 17 Dec 2009 12:48:30 +0100] ! 0 Error: Unable to connect to database: MySQL server has gone away
    [Thu, 17 Dec 2009 12:48:30 +0100] ! 0 Error: Unable to connect to database: MySQL server has gone away
    [Thu, 17 Dec 2009 12:48:30 +0100] ! 1 Error: Execution failed: Empty error message from utility.
    PHP Fatal error: Exception thrown without a stack frame in Unknown on line 0

    Any ideas?
     
  2. IgorG

    IgorG Forums Analyst Staff Member

    49
    24%
    Joined:
    Oct 27, 2009
    Messages:
    24,546
    Likes Received:
    1,240
    Location:
    Novosibirsk, Russia
    Looks like mysql is not started there. What status of mysql server before starting mentioned command?
     
  3. SalvadorS

    SalvadorS Regular Pleskian

    29
    90%
    Joined:
    Nov 12, 2009
    Messages:
    282
    Likes Received:
    2
    MySQL was up and running without any problem. Everytime we run /usr/local/psa/bin/sw-engine-pleskrun /usr/local/psa/admin/plib/DailyMaintainance/script.php we have the same problem (/var partition goes under read only status and we have to reboot the server) so we disable this script from the crontab.

    Regards
     
  4. IgorG

    IgorG Forums Analyst Staff Member

    49
    24%
    Joined:
    Oct 27, 2009
    Messages:
    24,546
    Likes Received:
    1,240
    Location:
    Novosibirsk, Russia
    If I correctly understood you have separate partition for /var? I can assume that hardware related problems can be a reason of this issue. Do you have any filesystem related errors in /var/log/messages when /var became read-only?
     
  5. SalvadorS

    SalvadorS Regular Pleskian

    29
    90%
    Joined:
    Nov 12, 2009
    Messages:
    282
    Likes Received:
    2
    Hello,

    Yes /var is a separate partition.

    These are the filesystem related errors in /var/log/messages:

    Dec 15 12:54:35 ns1 gconfd (root-14978): comenzando (version 2.16.1), pid 14978 usuario «root»
    Dec 15 12:54:36 ns1 gconfd (root-14978): Se resolvio la direccion «xml:readonly:/etc/gconf/gconf.xml.mandatory» a una fuente de iguracion de solo lectura en la posicion 0
    Dec 15 12:54:36 ns1 gconfd (root-14978): Se resolvio la direccion «xml:readwrite:/root/.gconf» a una fuente de configuracion estable en la posicion 1
    Dec 15 12:54:36 ns1 gconfd (root-14978): Se resolvio la direccion «xml:readonly:/etc/gconf/gconf.xml.defaults» a una fuente de cguracion de solo lectura en la posicion 2
    Dec 15 12:54:37 ns1 gconfd (root-14978): Se resolvio la direccion «xml:readonly:/var/lib/gconf/debian.defaults» a una fuente de iguracion de solo lectura en la posicion 3
    Dec 15 12:54:37 ns1 gconfd (root-14978): Se resolvio la direccion «xml:readonly:/var/lib/gconf/defaults» a una fuente de configuon de solo lectura en la posicion 4
     
  6. IgorG

    IgorG Forums Analyst Staff Member

    49
    24%
    Joined:
    Oct 27, 2009
    Messages:
    24,546
    Likes Received:
    1,240
    Location:
    Novosibirsk, Russia
    I'm not familiar with this language, but seems it is not filesystem related errors but gconf related. Do you really have mountpoint in /etc/fstab for /var with rw permission? Do you really can't write on /var when you see messages about read-only?
     
  7. Expert

    Expert Guest

    0
     
    I have the same problem too

    I have the same problem too

    Mysql is UP
    And I don't use tomcat5.5 (my license do not support it)

    Ubuntu Server 8.04 LTS
     
  8. IgorG

    IgorG Forums Analyst Staff Member

    49
    24%
    Joined:
    Oct 27, 2009
    Messages:
    24,546
    Likes Received:
    1,240
    Location:
    Novosibirsk, Russia
    For preventing error "MySQL server has gone away" try to increase wait_timeout in /etc/my.cnf:

    wait_timeout 20000

    Restart MySQL after that.
     
  9. Expert

    Expert Guest

    0
     
    This param already = 36000 since 2009 year )))
     
  10. Expert

    Expert Guest

    0
     
    if domain have no hosting

    /usr/local/psa/bin/sw-engine-pleskrun /usr/local/psa/admin/plib/DailyMaintainance/script.php
    show errors:

    but hosting for this domain is disabled and folders dose not exists and it's normal, why script.php think that is error...

    this error:
    I resolve this problem.
    In my case it happens because of disappear some IP on my eth0 (thnx my ISP) and become a red state in panel.
    I delete all red state IPs and retry IP list.

    All is ok now.

    But I have a new question.
    How I can change main ip? It is show in dashboard below host name.
    When I have this problem this ip in red state IPs list.
     
  11. IgorG

    IgorG Forums Analyst Staff Member

    49
    24%
    Joined:
    Oct 27, 2009
    Messages:
    24,546
    Likes Received:
    1,240
    Location:
    Novosibirsk, Russia
  12. Expert

    Expert Guest

    0
     
    I change main IP by deleting all old IPs and press Reload Ip's button. Now all is ok. Thanks!
     
Loading...