首页 > 其他分享 >zookeeper 常用命令

zookeeper 常用命令

时间:2023-03-03 18:13:53浏览次数:27  
标签:zookeeper ZooKeeper sh 常用命令 path ##### 节点

### Zookeeper 服务常用命令

```shell
启动 ZooKeeper 服务:./zkServer.sh start
查看 ZooKeeper 服务状态:./zkServer.sh status
停止 ZooKeeper 服务:./zkServer.sh stop
重启 ZooKeeper 服务:./zkServer.sh restart
```

 

### zookeeper 的客户端常用命令

##### 启动 zookeeper 客户端

![1677833684383](C:\Users\wangh\Desktop\播客园-flink\vm-zookeeper安装\assets\1677833684383.png)

 

##### 连接ZooKeeper服务端

```shell
./zkCli.sh -server ip:port
```

 

##### 断开连接

```shell
quit
```

 

##### 查看命令帮助

```shell
help
```

 

##### 显示指定目录下节点

```shell
ls 目录
```

 

##### 创建节点

```shell
create /节点path value
```

 

##### 获取节点值

```shell
get /节点path
```

 

##### 设置节点值

```shell
set /节点path value
```

 

##### 删除单个节点

```shell
delete /节点path
```

 

##### 删除带有子节点的节点

```shell
deleteall /节点path
```

 

##### 创建临时节点

```shell
create -e /节点path value
```

 

##### 创建顺序节点

```shell
create -s /节点path value
```

 

##### 查询节点详细信息

```shell
ls -s /节点path
```

 

标签:zookeeper,ZooKeeper,sh,常用命令,path,#####,节点
From: https://www.cnblogs.com/qingtianyu2015/p/17176570.html

相关文章

  • scrcpy安装与adb常用命令
    一、资源下载scrcpy安装包:https://download.csdn.net/download/qq_28807911/87527008github:https://github.com/Genymobile/scrcpy二、scrcpy安装1.右击此电脑-属性......
  • mpffinance常用命令参数
    主题相关查看可用预设主题mpf.available_styles()默认的主题包括:'binance','blueskies','brasil','charles','checkers','classic','default','ibd','kenan','mike','n......
  • Linux运用一些常用命令,优秀的PHPer都需掌握
    作为一名优秀的phper,Linux是必备的一项技能,工作3-5年的基本能明白我讲的道理!今天搜集整理了一些Linux服务器运维常用命令,希望对大家有帮助:1.删除0字节文件 find -type......
  • kubectl 常用命令
    1、显示一个或多个资源的详细状态kubectldescribe-nrbd-systemporainbond-operator-6d5bb9c7cb-jz84b2、使用默认编辑器编辑和更新服务器上一个或多个资源的定义。......
  • git常用命令教程
    补充requirements.txt的生成方式第一种方法是,在终端窗口输入pipfreeze>requirements.txtpipinstall-rrequirements.txt#一键安装所有依赖git常用指令指......
  • 【ZooKeeper基础-数据结构、服务端/客户端常用命令】
    一、ZooKeeper简介二、ZooKeeper数据结构&命令**1、数据结构**2、服务端常用命令①单机启动命令:./zkServer.shstart②状态查询命令:./zkServer.shstatus③停止服务......
  • linux常用命令
    1.man[命令或配置文件](功能描述:获得帮助信息)获取一个信息文档,查看具体信息,按q退出2.help命令(功能描述:获得shell内置命令的帮助信息)仅仅能获取bash内置命令的信息,不......
  • Linux中的常用命令
    Linux中的命令严格区分大小写pwd printworkingdirectory:输出当前工作目录,光标所有位置的目录(绝对路径)cd changedirectory:’切换目录 ‘.’表示当前目当‘........
  • Linux中的常用命令
    Linux中的命令严格区分大小写pwd printworkingdirectory:输出当前工作目录,光标所有位置的目录(绝对路径)cd changedirectory:’切换目录 ‘.’表示当前目当‘........
  • Linux中的常用命令
    Linux中的命令严格区分大小写 pwd printworkingdirectory:输出当前工作目录,光标所有位置的目录(绝对路径)cd changedirectory:’切换目录 ‘.’表示当前目当......