Ad Widget

Collapse

Database Error: No such File or Directory

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • snowxcloud
    Junior Member
    • Mar 2021
    • 3

    #1

    Database Error: No such File or Directory

    Hi,

    I've recently started up a new Zabbix server and successfully migrated across data from my old Zabbix server. Due to storage constraints, I've changed the MySQL Data Directory from the default '/var/lib/mysql' path to a new partition on my server called '/app/mysql'. I have confirmed that MySQL is accepting the new location by executing 'mysql > SELECT @@datadir;' which lists '/app/mysql/'. Following this, I restarted mysqld and all Zabbix-related services however when I attempt to login at 'http://HOSTNAME/zabbix' I'm greeted with the Database Error: No such file or directory.

    Is there a configuration file somewhere that I need to reconfigure so that Zabbix will recognise the new location of the MySQL database? Prior to changing the datadir location Zabbix was functioning correctly.

    The new '/app/mysql' path is still located on localhost.

    Any help would be greatly appreciated!
  • Atsushi
    Senior Member
    • Aug 2013
    • 2028

    #2
    I don't know the specific solution because I don't know the environment you are using. If it's just a web frontend issue, you may be able to fix it by setting mysqli.default_socket to a new socket file in your PHP settings.

    Comment

    Working...