Zookeeper Web Management installation Node-zk-browser__web

Source: Internet
Author: User
Tags zookeeper install node joyent

Node-zk-browser is the Zookeeper Web management tool, The use of Node.js, based on Express.js and Node-zookeeper development, in the form of a tree to display zookeeper data, login can be added to the node data, edit, delete.

The installation configuration process is as follows:

1. Install Node.js

Download the source pack v0.10.35.tar.gz to https://github.com/joyent/node/tags. Execute the following command to compile the Nodejs. can also go to nodejs official website download binary Nodejs package.
wget https://github.com/joyent/node/archive/v0.10.35.tar.gz

After decompression, install

./configure--prefix=/home/slim/nodejs

Make && make install

Note: Installation needs gcc-c++ support, if prompted the corresponding error, you need to install Yum-y install gcc-c++

Configure environment variables: Vi. bash_profile

Export path= $PATH:/home/slim/nodejs/bin

Export Node_path=/home/slim/nodejs:/home/slim/nodejs/lib/node_modules

This version of Nodejs was brought in by NPM. Run the following script hello.js to verify that the installation was successful:

var http = require ("http");  
Http.createserver (function (request, response) {  
        Response.writehead ({"Content-type": "Text/plain"});  
        Response.Write ("Hello World");  
        Response.End ();  
        }). Listen (9987);  
Node Hello.js

Then in the browser input: http://127.0.0.1:9987 can show "Hello world" to indicate that the installation was successful

2. Install Dependency Pack

Download the program from the Https://github.com/killme2008/node-zk-browser and enter the Node-zk-browser-master directory.
Perform the following command to install the dependency pack, such as Ejs,express,express-namespace and zookeeper

NPM install-d

After the installation is complete, the Ejs,express,express-namespace and zookeeper four directories are generated in the Node-zk-browser-master/node_modules directory.

If the package fails to install, you can perform the installation again, such as: NPM install-d Zookeeper

The packages that are dependent are in Package.json.

3. Configure Node-zk-browser-master

Modify startup script configuration ZK address: start.sh

logfile=$ (dirname $)/logs/node-zk-browser.log  
export zk_host= " 192.168.36.54:2181,192.168.36.99:2181,192.168.36.189:2181 "  
nohup node $ (dirname $)/app.js 2>&1 >> $LOGFILE &  

The username and password are in User.json, and only after logging in can the delete ZK node be created on the Web interface.

To start the service:

./start.sh

Browser input: Http://192.168.36.99:3000/can be accessed, the default port is 3000 can be modified in app.js.
After the installation of the interface as shown below:

In addition to Node-zk-browser, there is a Web management tool node_zookeeper_admin, similar to Node-zk-browser, but the interface looks better.

Https://git.oschina.net/gznofeng/Node_Zookeeper_Admin

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.