Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

document zk binaries #1599

Merged
merged 2 commits into from
Sep 27, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 50 additions & 0 deletions content/en/docs/18.0/reference/programs/zk/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
---
title: zk
series: zk
commit: 5d802ee3aed9099ee325ff27425099d05090b0e0
---
## zk

zk is a tool for wrangling the zookeeper.

### Synopsis

zk is a tool for wrangling the zookeeper.

It tries to mimic unix file system commands wherever possible, but
there are some slight differences in flag handling.

The zk tool looks for the address of the cluster in /etc/zookeeper/zk_client.conf,
or the file specified in the ZK_CLIENT_CONFIG environment variable.

The local cell may be overridden with the ZK_CLIENT_LOCAL_CELL environment
variable.

### Options

```
-h, --help help for zk
--keep_logs duration keep logs for this long (using ctime) (zero to keep forever)
--keep_logs_by_mtime duration keep logs for this long (using mtime) (zero to keep forever)
--log_rotate_max_size uint size in bytes at which logs are rotated (glog.MaxSize) (default 1887436800)
--purge_logs_interval duration how often try to remove old logs (default 1h0m0s)
--security_policy string the name of a registered security policy to use for controlling access to URLs - empty means allow all for anyone (built-in policies: deny-all, read-only)
--server string server(s) to connect to
```

### SEE ALSO

* [zk addAuth](./zk_addauth/) -
* [zk cat](./zk_cat/) -
* [zk chmod](./zk_chmod/) -
* [zk cp](./zk_cp/) -
* [zk edit](./zk_edit/) - Create a local copy, edit, and write changes back to cell.
* [zk ls](./zk_ls/) -
* [zk rm](./zk_rm/) -
* [zk stat](./zk_stat/) -
* [zk touch](./zk_touch/) - Change node access time.
* [zk unzip](./zk_unzip/) -
* [zk wait](./zk_wait/) - Sets a watch on the node and then waits for an event to fire.
* [zk watch](./zk_watch/) - Watches for changes to nodes and prints events as they occur.
* [zk zip](./zk_zip/) - Store a zk tree in a zip archive.

23 changes: 23 additions & 0 deletions content/en/docs/18.0/reference/programs/zk/zk_addAuth.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
title: addAuth
series: zk
commit: 5d802ee3aed9099ee325ff27425099d05090b0e0
---
## zk addAuth



```
zk addAuth <digest> <user:pass> [flags]
```

### Options

```
-h, --help help for addAuth
```

### SEE ALSO

* [zk](../) - zk is a tool for wrangling the zookeeper.

35 changes: 35 additions & 0 deletions content/en/docs/18.0/reference/programs/zk/zk_cat.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
---
title: cat
series: zk
commit: 5d802ee3aed9099ee325ff27425099d05090b0e0
---
## zk cat



```
zk cat <path1> [<path2> ...] [flags]
```

### Examples

```
zk cat /zk/path

# List filename before file data
zk cat -l /zk/path1 /zk/path2
```

### Options

```
-p, --decodeProto decode proto files and display them as text
-f, --force no warning on nonexistent node
-h, --help help for cat
-l, --longListing long listing
```

### SEE ALSO

* [zk](../) - zk is a tool for wrangling the zookeeper.

30 changes: 30 additions & 0 deletions content/en/docs/18.0/reference/programs/zk/zk_chmod.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
---
title: chmod
series: zk
commit: 5d802ee3aed9099ee325ff27425099d05090b0e0
---
## zk chmod



```
zk chmod <mode> <path> [flags]
```

### Examples

```
zk chmod n-mode /zk/path
zk chmod n+mode /zk/path
```

### Options

```
-h, --help help for chmod
```

### SEE ALSO

* [zk](../) - zk is a tool for wrangling the zookeeper.

33 changes: 33 additions & 0 deletions content/en/docs/18.0/reference/programs/zk/zk_cp.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
---
title: cp
series: zk
commit: 5d802ee3aed9099ee325ff27425099d05090b0e0
---
## zk cp



```
zk cp <src> <dst> [flags]
```

### Examples

```
zk cp /zk/path .
zk cp ./config /zk/path/config

# Trailing slash indicates directory
zk cp ./config /zk/path/
```

### Options

```
-h, --help help for cp
```

### SEE ALSO

* [zk](../) - zk is a tool for wrangling the zookeeper.

24 changes: 24 additions & 0 deletions content/en/docs/18.0/reference/programs/zk/zk_edit.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
title: edit
series: zk
commit: 5d802ee3aed9099ee325ff27425099d05090b0e0
---
## zk edit

Create a local copy, edit, and write changes back to cell.

```
zk edit <path> [flags]
```

### Options

```
-f, --force no warning on nonexistent node
-h, --help help for edit
```

### SEE ALSO

* [zk](../) - zk is a tool for wrangling the zookeeper.

40 changes: 40 additions & 0 deletions content/en/docs/18.0/reference/programs/zk/zk_ls.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
---
title: ls
series: zk
commit: 5d802ee3aed9099ee325ff27425099d05090b0e0
---
## zk ls



```
zk ls <path> [flags]
```

### Examples

```
zk ls /zk
zk ls -l /zk

# List directory node itself)
zk ls -ld /zk

# Recursive (expensive)
zk ls -R /zk
```

### Options

```
-d, --directorylisting list directory instead of contents
-f, --force no warning on nonexistent node
-h, --help help for ls
-l, --longlisting long listing
-R, --recursivelisting recursive listing
```

### SEE ALSO

* [zk](../) - zk is a tool for wrangling the zookeeper.

37 changes: 37 additions & 0 deletions content/en/docs/18.0/reference/programs/zk/zk_rm.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
---
title: rm
series: zk
commit: 5d802ee3aed9099ee325ff27425099d05090b0e0
---
## zk rm



```
zk rm <path> [flags]
```

### Examples

```
zk rm /zk/path

# Recursive.
zk rm -R /zk/path

# No error on nonexistent node.
zk rm -f /zk/path
```

### Options

```
-f, --force no warning on nonexistent node
-h, --help help for rm
-r, --recursivedelete recursive delete
```

### SEE ALSO

* [zk](../) - zk is a tool for wrangling the zookeeper.

24 changes: 24 additions & 0 deletions content/en/docs/18.0/reference/programs/zk/zk_stat.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
title: stat
series: zk
commit: 5d802ee3aed9099ee325ff27425099d05090b0e0
---
## zk stat



```
zk stat <path> [flags]
```

### Options

```
-f, --force no warning on nonexistent node
-h, --help help for stat
```

### SEE ALSO

* [zk](../) - zk is a tool for wrangling the zookeeper.

44 changes: 44 additions & 0 deletions content/en/docs/18.0/reference/programs/zk/zk_touch.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
---
title: touch
series: zk
commit: 5d802ee3aed9099ee325ff27425099d05090b0e0
---
## zk touch

Change node access time.

### Synopsis

Change node access time.

NOTE: There is no mkdir - just touch a node.
The disntinction between file and directory is not relevant in zookeeper.

```
zk touch <path> [flags]
```

### Examples

```
zk touch /zk/path

# Don't create, just touch timestamp.
zk touch -c /zk/path

# Create all parts necessary (think mkdir -p).
zk touch -p /zk/path
```

### Options

```
-p, --createparent create parents
-h, --help help for touch
-c, --touchonly touch only - don't create
```

### SEE ALSO

* [zk](../) - zk is a tool for wrangling the zookeeper.

30 changes: 30 additions & 0 deletions content/en/docs/18.0/reference/programs/zk/zk_unzip.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
---
title: unzip
series: zk
commit: 5d802ee3aed9099ee325ff27425099d05090b0e0
---
## zk unzip



```
zk unzip <archive> <path> [flags]
```

### Examples

```
zk unzip zktree.zip /
zk unzip zktree.zip /zk/prefix
```

### Options

```
-h, --help help for unzip
```

### SEE ALSO

* [zk](../) - zk is a tool for wrangling the zookeeper.

Loading