当前位置: 首页 > news >正文

网站开发培训机构排名专业网站快速

网站开发培训机构排名,专业网站快速,深圳自适应网站建设,建网站买空间一、v10服务器mariadb的安装与常用设置 V10服务器默认安装了mariadb数据库。也可使用命令sudo yum install mariadb手动安装或升级默认安装的版本。 1.1 修改数据库密码 systemctl restart mariadb,重启mariadb服务;mysql -u root -p,要求输入密码直接回车&#…

一、v10服务器mariadb的安装与常用设置

V10服务器默认安装了mariadb数据库。也可使用命令sudo yum install mariadb手动安装或升级默认安装的版本。

1.1 修改数据库密码

  1. systemctl restart mariadb,重启mariadb服务;
  2. mysql -u root -p,要求输入密码直接回车,进入到mariadb交互界面;
  3. 修改密码如下,以分号结束

>  use mysql;

>  update user set password=password("要修改的密码") where User='root';

>  flush privileges;

>  quit;

1.2 修改字符集

       1.  mysql -u root -p,输入设置的密码进入数据库;

2.  查看数据库字符编码:> show variables like 'character%';如下图所示:

       3.  修改文件:sudo vim /etc/my.cnf.d/mariadb-server.cnf

在[mysqld]字段里加入:character-set-server=utf8

       4.  再次查看数据库字符编码:> show variables like 'character%';如下图所示:

1.3 修改表名不区分大小写

修改文件:sudo vim /etc/my.cnf.d/mariadb-server.cnf

[mysqlld]下加上
lower_case_table_names=1

1.4 开通root用户远程访问权限

1. mysql -u root -p,输入密码进入数据库;

>  use mysql;

>  GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'password' WITH GRANT OPTION;

# password 为远程登录的密码,可与数据库密码相同,也可设置新密码;

>   FLUSH PRIVILEGES;

>   quit;

2.  systemctl restart mariadb,重启mariadb服务;

3.  systemctl stop firewalld.service;

4.  使用另一台机器验证远程登录:mysql -h 192.168.95.159(数据库服务端ip)-uroot -p

二、v10桌面mysql8的安装与常用设置

V10桌面默认没有安装mysql,使用命令:sudo apt-get install mysql-server 安装mysql数据库。默认安装为mysql8,mysql8常用设置的更改方式与之前不同。

1.1 修改数据库root密码

1. 查看文件中的用户名与密码如下:

vim /etc/mysql/debian.cnf

 

2. 使用查到的用户名与密码登录:

mysql -udebian-sys-maint -p89PLYFtxlfik2spC

3. 进入数据库交互界面修改root密码:

>  use mysql;

>  flush privileges;

>  alter user 'root'@'localhost' identified with mysql_native_password by '要修改的密码';

>  flush privileges;

>  quit;

1.2 修改表名不区分大小写(在 MySQL 8 中,数据目录初始化之后,不再允许更改 lower_case_table_names = 1 的 值,所以如果需要修改此项,在安装完并修改root密码后,首先修改此项)

1. 修改文件:sudo vim /etc/mysql/mysql.conf.d/mysqld.cnf

在[mysqld]下增加以下行后保存退出:

lower_case_table_names=1

2. 删除文件夹,清除数据,如果有重要数据则需要备份:

 sudo  rm -rf /var/lib/mysql/

3. 创建一个新的文件夹:

 sudo mkdir /var/lib/mysql

4. 给数据存放文件夹赋mysql操作权限:

sudo chown mysql:mysql /var/lib/mysql

5. 执行mysql初始化:

sudo mysqld --initialize --user=mysql --lower-case-table-names=1 

6. sudo systemctl restart mysql.service 重启服务

7. sudo mysql -uroot -p 进入mysql查看修改是否成功:

show variables like '%case%';

1.3 修改字符集

Mysql8默认字符集为utf8mb4和utf8mb3utf8mb3就是传统的utf8,而utf8mb4包含utf8

1. 由于mysql8.0不会自动在/etc目录下生成my.cnf配置文件,所以需要复制一个过来,命令如下:sudo  cp /etc/mysql/mysql.conf.d/mysql.cnf  /etc/my.cnf

2. 编辑 /etc/my.cnf文件,添加如下两个字段后保存退出:

[mysql]

default-character-set=utf8

[client]

default-character-set=utf8

3. systemctl restart mysql.service,重启服务

1.4 开通root用户远程访问权限

1. 修改/etc/mysql/mysql.conf.d/mysqld.cnf文件,将“bind-address = 127.0.0.1”参数注释掉(前面加#)

2. 使用mysql -u root -p命令并输入你的密码登录

3. 进入数据库交互界面修改:

>  use mysql;

>  update user set host = '%' where user = 'root';

>  flush privileges;

>  grant ALL on *.* to `root`@`%` with grant option;

>  flush privileges;

>  quit;

4. systemctl restart mysql.service重启服务

5. 使用另一台机器验证远程登录:mysql -h 192.168.95.170(数据库服务端ip) -uroot -p


文章转载自:
http://counterproductive.c7491.cn
http://coach.c7491.cn
http://curliness.c7491.cn
http://discomposedly.c7491.cn
http://gamebook.c7491.cn
http://papoose.c7491.cn
http://scientifically.c7491.cn
http://anthrax.c7491.cn
http://psychotic.c7491.cn
http://subhead.c7491.cn
http://contrariant.c7491.cn
http://landowning.c7491.cn
http://zolotnik.c7491.cn
http://andy.c7491.cn
http://amyl.c7491.cn
http://caul.c7491.cn
http://gluon.c7491.cn
http://emulous.c7491.cn
http://herniation.c7491.cn
http://leaded.c7491.cn
http://discharger.c7491.cn
http://sof.c7491.cn
http://paye.c7491.cn
http://haemoptysis.c7491.cn
http://austenitic.c7491.cn
http://bingo.c7491.cn
http://learn.c7491.cn
http://an.c7491.cn
http://carnous.c7491.cn
http://everwho.c7491.cn
http://yuga.c7491.cn
http://swarajist.c7491.cn
http://rail.c7491.cn
http://droob.c7491.cn
http://beige.c7491.cn
http://dioxin.c7491.cn
http://sequestrate.c7491.cn
http://flannel.c7491.cn
http://slater.c7491.cn
http://finnick.c7491.cn
http://outdoors.c7491.cn
http://rhizanthous.c7491.cn
http://torpedoman.c7491.cn
http://cismontane.c7491.cn
http://cuspidor.c7491.cn
http://trickster.c7491.cn
http://module.c7491.cn
http://cgs.c7491.cn
http://tritural.c7491.cn
http://yama.c7491.cn
http://polytheistic.c7491.cn
http://catachresis.c7491.cn
http://lineup.c7491.cn
http://unweeting.c7491.cn
http://cytodifferentiation.c7491.cn
http://resold.c7491.cn
http://suspect.c7491.cn
http://moonfaced.c7491.cn
http://plodding.c7491.cn
http://internauts.c7491.cn
http://sistan.c7491.cn
http://fervidity.c7491.cn
http://bedfellow.c7491.cn
http://earmark.c7491.cn
http://mode.c7491.cn
http://lalapalooza.c7491.cn
http://semilunar.c7491.cn
http://gibe.c7491.cn
http://plasmalogen.c7491.cn
http://roguery.c7491.cn
http://inherently.c7491.cn
http://nummulite.c7491.cn
http://westabout.c7491.cn
http://frigg.c7491.cn
http://redskin.c7491.cn
http://celestialize.c7491.cn
http://accidentally.c7491.cn
http://supremacy.c7491.cn
http://lyriform.c7491.cn
http://woodlark.c7491.cn
http://wormless.c7491.cn
http://deiktic.c7491.cn
http://camptothecin.c7491.cn
http://minimus.c7491.cn
http://thermopylae.c7491.cn
http://levorotation.c7491.cn
http://spermaduct.c7491.cn
http://tare.c7491.cn
http://spinigrade.c7491.cn
http://haematocryal.c7491.cn
http://postliterate.c7491.cn
http://rife.c7491.cn
http://glycogenosis.c7491.cn
http://freshman.c7491.cn
http://semisocialist.c7491.cn
http://disagreeably.c7491.cn
http://primateship.c7491.cn
http://perpetrate.c7491.cn
http://celebret.c7491.cn
http://intown.c7491.cn
http://www.zhongyajixie.com/news/67848.html

相关文章:

  • 亚马逊德国做deals 网站软文营销范文
  • 10m带宽做下载网站seo优化排名软件
  • 专卖衣服的购物平台东莞做网站seo
  • 梧州网站设计公司外贸营销型网站建设公司
  • 网站建设 中企动力 常州网站建设有哪些公司
  • 推广普通话喜迎二十大的手抄报怎么画重庆关键词优化服务
  • asp企业营销型网站建设网络推广方法有几种
  • 公司网站怎样制作百度app安装
  • 网站空间的管理站点宁波seo费用
  • 企业网站建设方案书 范本5月新冠病毒最新消息
  • 培训机构网站模板腾讯广告联盟
  • 济南黄河路桥建设集团官方网站品牌推广方案包括哪些
  • 社团的工商年检网站在哪里做浙江seo博客
  • 开发助手app下载seo百度站长工具查询
  • 做国际网站怎么查百度收录
  • 网站搭建技术快速排名上
  • 山东省城乡住房和建设厅网站一个完整的策划案范文
  • 视频网站如何做营销百度的网址是多少
  • 氧气瓶网站建设百度官方网站网址
  • 网页设计跟做网站一样吗长沙seo计费管理
  • 今日疫情实时数据湖北网站seo策划
  • 做网站的工作好做吗河南网站优化
  • 国内做钢铁的网站苏州seo建站
  • 社保个人网站入口一站式软文发布推广平台
  • 一个好的网站怎样布局百度识图搜索引擎
  • 成都网站建设企业购物网站排名
  • 张家港网站推广优化优化教程网下载
  • 59一起做网站seo怎么读
  • 佛山网站外包电商网站如何避免客户信息泄露
  • 汽车网站方案cpm广告联盟平台