In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/01 Report--
This article is about how to use Nacos. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.
The functions that Nacos can achieve: service registration and discovery, configuration management, service management, these functions in the native Spring Cloud components are Eureka, Spring Cloud Config Server, Spring actuator. Let's take a look at how Nacos implements these functions through practice. The practice part of this paper is divided into several steps:
Deploy Nacos
Build micro-service applications and access Nacos
Deploy Nacos (for Linux environment below)
Download the latest release version from the official source repository Github
Wget https://github.com/alibaba/nacos/releases/download/0.9.0/nacos-server-0.9.0.tar.gz
Extract the corresponding tar packet
Tar-zxvf nacos-server-0.9.0.tar.gz
Start Nacos
Cd. / nacos/bin;sh startup.sh-m standalone
You can see the corresponding terminal log consle log
/ usr/lib/jvm/java-1.8.0-openjdk-1.8.0.201.b09-2.el7_6.x86_64/bin/java-Xms512m-Xmx512m-Xmn256m-Dnacos.standalone=true-Djava.ext.dirs=/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.201.b09-2.el7_6.x86_64/jre/lib/ext:/usr/lib/jvm/java-1.8.0-openjdk-1.8 .0.201.b09-2.el7_6.x86_64/lib/ext:/tmp/nacos/plugins/cmdb-Xloggc:/tmp/nacos/logs/nacos_gc.log-verbose:gc-XX:+PrintGCDetails-XX:+PrintGCDateStamps-XX:+PrintGCTimeStamps-XX:+UseGCLogFileRotation-XX:NumberOfGCLogFiles=10-XX:GCLogFileSize=100M-Dnacos.home=/tmp/nacos-jar / tmp/nacos/target/nacos-server.jar-- spring.config.location=classpath:/ Classpath:/config/,file:./,file:./config/,file:/tmp/nacos/conf/-- logging.config=/tmp/nacos/conf/nacos-logback.xmlnacos is starting. ,--.'|,--,:: | Nacos 0.9.0, `- .` |':,--. Running in stand alone mode, All function modules |:: | |','\. Port: 8848:\ |:,. -.--. / / | / 'Pid: 31401 |:'; | /\ /. ;,. : |: / `. / Console: http://172.16.0.16:8848/nacos/index.html';. | / /'| |:: |; _ | |\ |\ _\ /:. .. '/' |.;:\'. Https://nacos.io': |;.', ". -;; |';: _ _ |: | `-. \ | |'`- -'/ /,. |'|'.'|\ / `- -'/': |;:.'::` -'. /; |. |. /\ / `-'-'- -'. 2019-03-10 17 with context path 2814 02006 INFO Tomcat started on port (s): 8848 (http) with context path'/ nacos'
2019-03-10 17 2815 02058 INFO Nacos Log files: / tmp/nacos/logs/
2019-03-10 17 2815 02058 INFO Nacos Conf files: / tmp/nacos/conf/
2019-03-10 17 2815 02058 INFO Nacos Data files: / tmp/nacos/data/
2019-03-10 17 INFO Nacos started successfully in stand alone mode 2815 02058.
2019-03-10 17 2803267 INFO Initializing Servlet' dispatcherServlet'
2019-03-10 17 2815 03321 INFO Completed initialization in 53 ms
The above log can see that Nacos has been started, then log in to the Nacos console
The default http://ip:8488/nacos/index.html account is nacos/nacos.
The following figure shows a default console interface without any service instance registration. On the left side of the figure, Nacos can implement basic configuration center functions (configuration monitoring, historical version, monitoring query) and service registration management.
Thank you for reading! This is the end of the article on "how to use Nacos". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, you can share it for more people to see!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.