linux下mysql安装、目录结构、配置
发布时间:2020-12-15 07:19:12 所属栏目:安全 来源:网络整理
导读:[root@localhost?/]#rpm?-ivh?MySQL-server-community-5.1.44-1.rhel4.i386.rpm;[root@localhost?/]#rpm?-ivh?MySQL-client-community-5.1.44-1.rhel4.i386.rpm; [root@localhost?/]#netstat?-ntpl; [root@localhost?/]#/usr/bin/mysqladmin?-u?root?passwor
[root@localhost?/]#rpm?-ivh?MySQL-server-community-5.1.44-1.rhel4.i386.rpm;[root@localhost?/]#rpm?-ivh?MySQL-client-community-5.1.44-1.rhel4.i386.rpm;
[root@localhost?/]#netstat?-ntpl;
[root@localhost?/]#/usr/bin/mysqladmin?-u?root?password?'xxxxxx';[root@localhost?/]#mysql?-u?root?-pEnter?password:xxxxxx
表示登陆成功!
mysql>use?mysql;mysql>update?user?set?host?='%'?where?user?='root';mysql>select?host,user?from?user;mysql>FLUSH?PRIVILEGES
mysql>GRANT?ALL?RRIVILEGES?ON?*.*?TO?username@'%'?IDENTIFIED?BY?'password'?WITH?GRANT?OPTION;mysql>FLUSH?PRIVILEGES;
[root@localhost?/]#service?mysql?stop;[root@localhost?/]#service?mysql?start;
[root@localhost?/]#show?variables?like?'character_set_%';[root@localhost?/]#show?variables?like?'collation_%';
[root@localhost?/]#rpm?-qa|grep?-i?mysql
MySQL-server-community-5.1.44-1.rhel4.i386.rpmMySQL-client-community-5.1.44-1.rhel4.i386.rpm[root@localhost?/]#rpm?-e??MySQL-server-community-5.1.44-1.rhel4.i386.rpm[root@localhost?/]#rpm?-e?MySQL-client-community-5.1.44-1.rhel4.i386.rpm
[root@localhost?/]#rm?-f?/etc/my.cnf[root@localhost?/]#rm?-f?/var/lib/mysql
shell>mysqldump?source_db?-uroot?-pxxxxxx?--opt?|?mysql?target_db?-uroot?-pxxxxxx?-h?
(编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
相关内容
- 学习笔记3-Bootstrap CSS 【转载整理->原创】
- 基于AngularJS的UI组件,quantumui与angular-strap vs. angu
- AngularJS中的Provider们:Service和Factory等的区别
- 建议在多个值上优化简单的Scala foldLeft?
- WebService调用Session
- bash – 什么`返回-1 ||退出-1`是什么意思?
- scala – Spark:我已失去参考的unpersist RDD
- typescript – Angular 2动态地将组件实例添加到容器中
- BASH:如何清除清单中命名的文件之外的所有文件?
- WebService之Axis2快速入门(3): 用services.xml发布WebServ