Does anyone have a fix to the problem mentioned in the subject. I recently switched from MySQL to MariaDB and all was fine till suddenly I could no longer connect to the database. There was absolutely no changes made in any settings but MariaDB just stopped working and here is what I could gather from the log
Aug 25 11:26:50 gpsdata-01 mysqld_safe: Starting mysqld daemon with databases from /var/lib/mysql Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [Note] /usr/sbin/mysqld (mysqld 10.1.13-MariaDB-1~trusty) starting as process 3816 ... Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [Note] InnoDB: Using mutexes to ref count buffer pool pages Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [Note] InnoDB: The InnoDB memory heap is disabled Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [Note] InnoDB: Memory barrier is not used Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [Note] InnoDB: Compressed tables use zlib 1.2.8 Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [Note] InnoDB: Using Linux native AIO Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [Note] InnoDB: Using SSE crc32 instructions Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [Note] InnoDB: Initializing buffer pool, size = 256.0M Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [Note] InnoDB: Completed initialization of buffer pool Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [Note] InnoDB: Highest supported file format is Barracuda. Aug 25 11:26:50 gpsdata-01 mysqld: InnoDB: Transaction 3748540 was in the XA prepared state. Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [ERROR] InnoDB: Failed to find tablespace for table '"gps"."events"' in the cache. Attempting to load the tablespace with space id 72. Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [ERROR] InnoDB: Failed to find tablespace for table '"gps"."positions"' in the cache. Attempting to load the tablespace with space id 56. Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [ERROR] InnoDB: Failed to find tablespace for table '"gps"."user_device"' in the cache. Attempting to load the tablespace with space id 54. Aug 25 11:26:50 gpsdata-01 mysqld: 2016-08-25 11:26:50 140205837375424 [ERROR] InnoDB: Failed to find tablespace for table '"gps"."device_geofence"' in the cache. Attempting to load the tablespace with space id 83. Aug 25 11:26:50 gpsdata-01 mysqld: InnoDB: 1 transaction(s) which must be rolled back or cleaned up
I have never previously seen any error such as this when using MySQL. I am a little puzzled because it's just a development database with not that many read/writes - how could it go corrupt? Any pointers on how to fix this?