Tips‎ > ‎

Mysql

Installing mySQL on Slackware:
root@sbserver:~# mysql_install_db
root@sbserver:/etc/rc.d# chmod +x rc.mysqld
root@sbserver:/var/lib# chown mysql.mysql -R mysql
root@sbserver:~# mysql_secure_installation
Watch out of SKIP="--skip-networking" in rc.mysqld !!!!

Creating database:
mysql -u root -p.............
create database mantis;
grant all on mantis.* to mantis@localhost identified by '------------';
show databases;

Backup database:
Restore database:
mysql -u ttwww -p.................. ttwww  < /home/bart/transfer/ttwww.sql

Check the database table type: MyISAM, InnoDB, etc:
SHOW TABLE STATUS WHERE Name = 'xxx'
show
create table <tablename>;



:)
Comments