How to recreate ibdata1 on my server?

Tommyhara

Verified User
Joined
Jul 25, 2014
Messages
185
Hello Directadmin support staff,

Unluckily, I cleared all content of ibdata1 file in /var/lib/mysql

and now I can not connect to Mysql server, I can not restart mysql server. I tried but it showed this error

[root@srv mysql]# sudo service mysqld start
Starting MariaDB.190915 06:09:20 mysqld_safe Logging to '/var/lib/mysql/srv.mydomain.com.err'.
190915 06:09:20 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
/etc/init.d/mysqld: line 264: kill: (25439) - No such process
ERROR!

How to recover ibdata1 and make my websites work ?


Please support urgently.

Thank you very much!
 
Hello,

You need to reinstall SQL-server and re-import your databases from a dump. Or use another method to restore your server from a snapshot or whatever else backups you have.

If you go with a SQL server reinstall then check help and forums for ready guides, one of a possible guide can be found here: How to reinstall MariaDB on DirectAdmin server
 
Back
Top