Recreating the mysql.sock file

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Alan Williamson

    Recreating the mysql.sock file

    looking through all the forums and newsgroups it would appear that
    mysql.sock is definitely one for the Top10 of all time problems.
    However, i have yet to see an answer that properly addresses it.

    I have a production system, that is running away with no problems.
    However every so often the command line 'mysql' seems to be unable to
    connect to the main server running. It complains it can't find the
    file.

    Now here is the rub; the file is there; it has the correct
    permissions. Now before any smart-a**e says to restart MySQL server,
    i can't. Its a production site and therefore i don't wish to restart
    it.

    So the question is, how does one recreate this file on a live system?
    And second question is why does it lose the file in the first place?

    Any help anyone can point would be appreciated.

    thank you,

    a
  • Aggro

    #2
    Re: Recreating the mysql.sock file

    Alan Williamson wrote:
    [color=blue]
    > And second question is why does it lose the file in the first place?[/color]

    It _shouldn't_ be destroyed by itself. So could it be that some other
    program is deleting/rewriting it? Is it possible to setup the socket
    file for safer place if it isn't there yet. If I remember correctly,
    there have been problems, when socket file is located in /tmp/ folder,
    which is cheduled to be cleared automaticly.

    So atleast make sure that the folder where your socket file is, is not
    cleared automaticly.

    Comment

    • Aggro

      #3
      Re: Recreating the mysql.sock file

      Alan Williamson wrote:
      [color=blue]
      > And second question is why does it lose the file in the first place?[/color]

      It _shouldn't_ be destroyed by itself. So could it be that some other
      program is deleting/rewriting it? Is it possible to setup the socket
      file for safer place if it isn't there yet. If I remember correctly,
      there have been problems, when socket file is located in /tmp/ folder,
      which is cheduled to be cleared automaticly.

      So atleast make sure that the folder where your socket file is, is not
      cleared automaticly.

      Comment

      Working...