mysql user administration
1. 为数据库databasename创建web用户
1.1 创建数据库
mysql> create database databasename;
1.2 为数据库创建用户
mysql> grant select,insert,update,delete,index,alter,create,drop on databasename.* to user identified by 'password';
1.3 插入数据
mysql -D databasename -u user -ppassword </home/shushen/Documents/TCMID/mysql/mysql.sql
1.4 mysql config 配置
,mysql启动和停止等操作
# /etc/init.d/mysqld start;# service mysqld start;#service mysqld stop ;#/etc/init.d/mysqld stop ;# service mysqld restart;/etc/init.d/mysqld restart;#service mysqld status
修改列属性
alter table microrna_target_database CHANGE database_id database_id INT(24) NOT NULL AUTO_INCREMENT;
/etc/my.cnf是默认的MySQL配置文件。应该对这个文件配置修改。 Port 127.0.0.1 改为 0.0.0.0