1. Mysql 数据库本地连接:
mysql -uroot -p;
2. 显示 数据库 有哪些:
show databases;
3. 使用 某一个数据库:
use 数据库名称;
4. 显示数据库有 哪些表:
show tables;
5. 将某条sql 导入数据库:
source xxxxx.sql;
6. 数据库退出:
exit;
7. 将某个文件复制到 当前目录:
cp /path/to/source/file . 【其中 . 代表当前目录】
8. 复制一份文件 到 另一个地方:
cp /path/to/source/file1 /path/to/source/file2
9. 移动一份文件并改名字:
mv old_name.txt new_name.txt
10. 移动一份文件并改名字:
cp old_name.txt new_name.txt