The error in Plesk: ERR [panel] SQLSTATE[HY000] [2002] No such file or directory, Can't connect to local MySQL server through socket




  • Avatar
    Dilan Rostam


    /opt/psa/admin/conf/php.ini (PSA is shortcutted in /usr/local/psa...)

    My server has the same issue and can not upgrade and the info you refer is not stated in the file at all, What does this mean? can add them here?


    # The MariaDB configuration file
    # The MariaDB/MySQL tools read configuration files in the following order:
    # 1. "/etc/mysql/mariadb.cnf" (this file) to set global defaults,
    # 2. "/etc/mysql/conf.d/*.cnf" to set global options.
    # 3. "/etc/mysql/mariadb.conf.d/*.cnf" to set MariaDB-only options.
    # 4. "~/.my.cnf" to set user-specific options.
    # If the same option is defined multiple times, the last one will apply.
    # One can use all long options that the program supports.
    # Run program with --help to get a list of available options and with
    # --print-defaults to see which it would actually understand and use.

    # This group is read both both by the client and the server
    # use it for options that affect everything

    # Import all .cnf files from configuration directory
    !includedir /etc/mysql/conf.d/
    !includedir /etc/mysql/mariadb.conf.d/
    bind-address = ::ffff:

    Comment actions Permalink
  • Avatar
    Alexey Lapshin

    Hello @Dilan Rostam,

    I suggest you check definition in MySQL server configuration files as follows:

    # grep -ir "mysql.sock" /etc/mysql/*

    In case any further issues occur - please submit ticket to us:  

    Comment actions Permalink

Please sign in to leave a comment.

Have more questions? Submit a request