易截截图软件、单文件、免安装、纯绿色、仅160KB

Fedora下Mysql的简单使用

转到附录1(mysql 命令大全 - 命令详解

转到附录2(mysql乱码问题解决方法

在我的Fedora中,在系统安装时我就选择安装了Mysql了,所以就不用再去下载源代码,然后去慢慢编译。哈哈,偷了一个懒。
系统安装好了,Mysql时必不可少的,所以一定要检验一下Mysql可以用不。
首先切换到root账户,然后输入命令:service mysqld start
系统显示如下:
初始化 MySQL 数据库: Installing MySQL system tables...
OK
Filling help tables...
OK
To start mysqld at boot time you have to copy
support-files/mysql.server to the right place for your system
PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:
/usr/bin/mysqladmin -u root password 'new-password'
/usr/bin/mysqladmin -u root -h stony password 'new-password'
Alternatively you can run:
/usr/bin/mysql_secure_installation
which will also give you the option of removing the test
databases and anonymous user created by default.  This is
strongly recommended for production servers.
See the manual for more instructions.
You can start the MySQL daemon with:
cd /usr ; /usr/bin/mysqld_safe &
You can test the MySQL daemon with mysql-test-run.pl
cd /usr/mysql-test ; perl mysql-test-run.pl
Please report any problems with the /usr/bin/mysqlbug script!     [确定]
正在启动 mysqld:                                                                                [确定]
看来Mysql的服务可以启动起来,应该问题不大了。
马上添加root密码,mysqladmin -u root  password xxxxxx
登录以下,输入命令:mysql -u root -p
请求输入密码,输入密码,进入了!^_^   
到这里,应该基本上可以说Mysql是没有问题的了。时间不早了,今天的Mysql就弄到这里。明天开始


相关文档:

MySQL常用命令

1. 给root加密码:/usr/bin/mysqladmin -u root password 123456
2. 导出:mysqldump -u root -p dbname > file.sql
3. 导入:mysql -u root -p dbname < backup-file.sql
4. 授权:grant all on *.* to root@"%" identified by "密码";
5. 收回权限:revoke all privileges on *.* from root@"%";
6. 登录:mys ......

Mysql 导入导出的问题

关于MySql的导入导出问题
    在终端中,进入mysql的路径下的bin中,在这个路径下可以执行mysql,mysqldump等命令。
    或者添加环境变量 设置环境变量path "...(mysql的安装路径下的bin目录)",这样就不必每次都进入上面所说的路径下操作。
导出一个库:
    mysqldump ......

mysql问题集总

安装配置mysql
http://edu.codepub.com/2009/1213/18710.php
一、
下载编译安装
#cd /usr/local/src/
#wget http://mysql.byungsoo.net/Downloads/MySQL-5.1/mysql-5.1.38.tar.gz
#tar –xzvf mysql-5.1.38.tar.gz ../software/
#./configure
--prefix=/usr/local/mysql //MySQL安装目录
--datadir=/mydata / ......

MySQL数据库备份和还原的常用命令【转】


MySQL数据库备份和还原的常用命令
原文见http://www.21andy.com/blog/20071102/655.html
时间:2007-11-02 23:29:09   类别:技术   访问:3,731 views   RSS 2.0   评论  
备份MySQL数据库的命令
mysqldump -hhostname -uusername -ppassword database ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号