Databases such as Oracle and SQL Server are only equipped with one storage engine, and all data storage management mechanisms are the same. The MySql database provides a variety of storage engines. Users can choose storage engines suitable for different needs to store data for data tables, and they can also write exclusive storage engines according to their own needs.
It is possible to find the default database type from phpMyAdmin, provided you have gained access to phpMyAdmin. Select a database from phpMyAdmin to view its table list. Under the "Type" column, you will see the data table type for each table.
If you can log in to the MySQL server directly, another way to identify the storage engine is to log in to the MySQL server and run the following MySQL command:
mysql> SELECT ENGINE FROM information_schema.TABLES WHERE TABLE_SCHEMA = 'my_database' AND TABLE_NAME = 'my_table';
The above command will display the engine type of the ’mytable’ table in the ’mydatabase’ database.
Use mysqlshow, a command line tool and a method of checking the engine, to display database information. mysqlshow is included in the MySQL client installation package. To use the mysqlshow command, you must provide the login credentials for the MySQL server.
The following command will display specific database information. Under the "Engine" column, you can see the engine used by each table.
$ mysqlshow -u -p -i
The above is the detailed content of How to check MySql storage engine under Linux. For more information, please follow other related articles on the PHP Chinese website!