Menu

apache segmentation fault

Help
lemon
2005-03-11
2013-04-17
  • lemon

    lemon - 2005-03-11

    hallo
    i run libnss-mysql to authorize ftp users (and i need to to support a lot of user accounts, now is more then 2000 users)

    And i get weird error - apache crashes with segmentaion fault.

    apache is compiled --with-apxs --enable_module=rewrte --enable-module=vhost_alias --enable-so

    i use latest PHP4.

    libnss version is 1.4. 
    FTP is working fine, no problems at all with it.

    I get such this is /var/log/messages

    Mar 10 23:29:45 r2-h50 httpd: libnss-mysql: Connection to server 'localhost' failed: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
    Mar 10 23:30:02 r2-h50 last message repeated 203 times
    Mar 10 23:33:23 r2-h50 su: libnss-mysql: Connection to server 'localhost' failed: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)

    i start mysql with
    /usr/local/mysql/bin/safe_mysqld -O max_connections=30000 --user=mysql

    my.cfn is  default accept i added time-out option.

    My questions are, why apache tryes to use libnss to connect to mysql.  And can it be a reason that couses seg fault?
    and why i get Cant connect if FTP is working fine.

    Thank you in advance,
    Vlad

     
    • Ben Goodwin

      Ben Goodwin - 2005-03-12

      My first question is why is libnss-mysql unable to connect to your MySQL server at 23:29:45?  Notice also that the 'su' command also ran into a similar situation.  Are there any log messages in your MySQL log?

      Apache needs to look up usernames and groups which is why it's showing up.  My guess is that it's crashing because at one point a user or group existed but at another point (when it was unable to contact the MySQL server) it didn't.  It's also possible that libnss-mysql is doing the "wrong thing" when the MySQL server is unreachable, so it's entirely possible we have two problems to track down here.

       

Log in to post a comment.