学习地址:https://www.bilibili.com/video/BV18E411x7eT?p=96&vd_source=e7f24a421cc55783283e95fe226df2af
官网:https://nacos.io/zh-cn/docs/what-is-nacos.html
github:https://github.com/alibaba/nacos/
配置中心+注册中心
单机版部署
下载:https://github.com/alibaba/nacos/releases
将nacos sql导入mysql
[root@localhost bin]# ll ../conf/ total 88 -rw-r--r-- 1 502 games 1224 Jun 18 2021 1.4.0-ipv6_support-update.sql -rw-r--r-- 1 502 games 9508 Dec 15 16:40 application.properties -rw-r--r-- 1 502 games 9506 Jul 27 2021 application.properties.example -rw-r--r-- 1 502 games 670 Mar 18 2021 cluster.conf.example -rw-r--r-- 1 502 games 31156 Jul 15 2021 nacos-logback.xml -rw-r--r-- 1 502 games 10660 Jun 18 2021 nacos-mysql.sql -rw-r--r-- 1 502 games 8795 Jun 18 2021 schema.sql mysql> create database nacos; mysql> use nacos Database changed mysql> source /data/nacos/conf/nacos-mysql.sql; Query OK, 0 rows affected, 3 warnings (0.01 sec) Query OK, 0 rows affected, 3 warnings (0.01 sec) Query OK, 0 rows affected, 3 warnings (0.00 sec) Query OK, 0 rows affected, 3 warnings (0.01 sec) Query OK, 0 rows affected, 4 warnings (0.01 sec) Query OK, 0 rows affected, 9 warnings (0.01 sec) Query OK, 0 rows affected, 4 warnings (0.01 sec) Query OK, 0 rows affected, 9 warnings (0.00 sec) Query OK, 0 rows affected, 5 warnings (0.01 sec) Query OK, 0 rows affected (0.01 sec) Query OK, 0 rows affected (0.00 sec) Query OK, 0 rows affected (0.01 sec) Query OK, 1 row affected (0.00 sec) Query OK, 1 row affected (0.00 sec) mysql> show tables; +----------------------+ | Tables_in_nacos | +----------------------+ | config_info | | config_info_aggr | | config_info_beta | | config_info_tag | | config_tags_relation | | group_capacity | | his_config_info | | permissions | | roles | | tenant_capacity | | tenant_info | | users | +----------------------+ 12 rows in set (0.00 sec)
修改配置文件,user.0与password.0改为以下
### Connect URL of DB: db.url.0=jdbc:mysql://192.168.20.220:3306/nacos?characterEncoding=utf8&connectTimeout=1000&socketTimeout=3000&autoReconnect=true&useUnicode=true&useSSL=false&serverTimezone=UTC db.user=root db.password=mysqlpasswd
单机版启动
bin]# ./startup.sh -m standalone
标签:affected,--,简介,nacos,sec,Query,OK From: https://www.cnblogs.com/rtnb/p/16985468.html