Skip to content

Commit

Permalink
man: converted to unix format, fixed comment macroses
Browse files Browse the repository at this point in the history
  • Loading branch information
bioothod committed Jan 13, 2017
1 parent 2d8bc8c commit 48a34a0
Show file tree
Hide file tree
Showing 4 changed files with 226 additions and 226 deletions.
158 changes: 79 additions & 79 deletions man/dnet_find.1
@@ -1,79 +1,79 @@
./" 2008+ Copyright (c) Evgeniy Polyakov <zbr@ioremap.net>
./" All rights reserved.

.TH MAN 1 2013-07-10 "Linux" "Elliptics admin's guide"
.SH NAME
dnet_find \- find a key in a storage.
.SH SYNOPSIS
.B dnet_find \-r
.I host:port:family
\-I
.I id
.B [-mlh]
.SH DESCRIPTION
.P
Run this command to find a key in a storage.
.P
Storage structure can be changed: storage can grow or shrink, or just it can be moved to another physical platform with the different parameters then it was. In this case some files in the storage can wait for recovery in unappropriate place creating reading/writing problems by this way.
.P
.I dnet_find
helps to detect keys that located at illegal (from the standpoint of the routing table) place. When such a problem detected, the
.I dnet_recovery
should be called. Read the
.B dnet_recovery (1)
document for more information.
.P
.I dnet_find
connects to the specified node and gets the whole routing table there. Then it connects to each node from the table with the search request in special DIRECT mode (read the DNET_FLAGS_DIRECT description in the /usr/include/elliptics/packet.h). When node receives this request it searches through all it's keys even if the key should not be served by this node by the routing table.
.SH OPTIONS
.TP
.B \-r host:port:family
Address of a storage node, where
.I family
is either 2 (AF_INET) or 10 (AF_INET6). Example,
.I example.host:1025:2.
.TP
.B \-I id
Hashed key. You can get the hash from the key string by the command
.B echo -n \*(lqkey-string\*(rq | sha512sum | awk '{print $1}'.
.TP
.B \-m level
Log level. You should pass numbers from 0 to 4. 4 is the highest level.
.TP
.B \-l log
Log file,
.I stdout
by default.
.TP
.B \-h
Show help message and exit.
.SH EXAMPLES
.P
Let's find a key "file_name":
.P
dnet_find -r localhost:1025:2 -I `echo -n "file_name" | sha512sum | awk '{print $1}'`
.P
result:
.P
2013-09-24 13:14:47.728838 3084/3084 : 2:034c3671e643: FIND-OK object: 127.0.0.1:1025: should live at: 127.0.0.1:1025, offset: 3413, size: 752, mtime: 2013-06-14 14:30:43 MSK, path: /var/tmp/blob/data-0.13
.P
This answer shows us that specified key was found at
.B FIND-OK object: 127.0.0.1:1025,
and it
.B should live at: 127.0.0.1:1025.
Comparison of this messages tell us that the location of this file is correct.
.P
Also we have additional information about the record:
.B offset: 3413, size: 752, mtime: 2013-06-14 14:30:43 MSK, path: /var/tmp/blob/data-0.13.
.SH AUTHOR
Evgeniy Polyakov (zbr@ioremap.net)
.SH SEE ALSO
.P
.BR dnet_ioclient (1),
.BR dnet_ioserv (1),
.BR dnet_recovery (1),
.BR eblob_index_info (1),
.BR eblob_merge (1),
.BR eblob_regex_iter (1).
.P
Complete documentation on project you can find at http://doc.reverbrain.com.
.\" 2008+ Copyright (c) Evgeniy Polyakov <zbr@ioremap.net>
.\" All rights reserved.

.TH MAN 1 2013-07-10 "Linux" "Elliptics admin's guide"
.SH NAME
dnet_find \- find a key in a storage.
.SH SYNOPSIS
.B dnet_find \-r
.I host:port:family
\-I
.I id
.B [-mlh]
.SH DESCRIPTION
.P
Run this command to find a key in a storage.
.P
Storage structure can be changed: storage can grow or shrink, or just it can be moved to another physical platform with the different parameters then it was. In this case some files in the storage can wait for recovery in unappropriate place creating reading/writing problems by this way.
.P
.I dnet_find
helps to detect keys that located at illegal (from the standpoint of the routing table) place. When such a problem detected, the
.I dnet_recovery
should be called. Read the
.B dnet_recovery (1)
document for more information.
.P
.I dnet_find
connects to the specified node and gets the whole routing table there. Then it connects to each node from the table with the search request in special DIRECT mode (read the DNET_FLAGS_DIRECT description in the /usr/include/elliptics/packet.h). When node receives this request it searches through all it's keys even if the key should not be served by this node by the routing table.
.SH OPTIONS
.TP
.B \-r host:port:family
Address of a storage node, where
.I family
is either 2 (AF_INET) or 10 (AF_INET6). Example,
.I example.host:1025:2.
.TP
.B \-I id
Hashed key. You can get the hash from the key string by the command
.B echo -n \*(lqkey-string\*(rq | sha512sum | awk '{print $1}'.
.TP
.B \-m level
Log level. You should pass numbers from 0 to 4. 4 is the highest level.
.TP
.B \-l log
Log file,
.I stdout
by default.
.TP
.B \-h
Show help message and exit.
.SH EXAMPLES
.P
Let's find a key "file_name":
.P
dnet_find -r localhost:1025:2 -I `echo -n "file_name" | sha512sum | awk '{print $1}'`
.P
result:
.P
2013-09-24 13:14:47.728838 3084/3084 : 2:034c3671e643: FIND-OK object: 127.0.0.1:1025: should live at: 127.0.0.1:1025, offset: 3413, size: 752, mtime: 2013-06-14 14:30:43 MSK, path: /var/tmp/blob/data-0.13
.P
This answer shows us that specified key was found at
.B FIND-OK object: 127.0.0.1:1025,
and it
.B should live at: 127.0.0.1:1025.
Comparison of this messages tell us that the location of this file is correct.
.P
Also we have additional information about the record:
.B offset: 3413, size: 752, mtime: 2013-06-14 14:30:43 MSK, path: /var/tmp/blob/data-0.13.
.SH AUTHOR
Evgeniy Polyakov (zbr@ioremap.net)
.SH SEE ALSO
.P
.BR dnet_ioclient (1),
.BR dnet_ioserv (1),
.BR dnet_recovery (1),
.BR eblob_index_info (1),
.BR eblob_merge (1),
.BR eblob_regex_iter (1).
.P
Complete documentation on project you can find at http://doc.reverbrain.com.
104 changes: 52 additions & 52 deletions man/dnet_ioclient.1
@@ -1,37 +1,37 @@
./" 2008+ Copyright (c) Evgeniy Polyakov <zbr@ioremap.net>
./" All rights reserved.
.\" 2008+ Copyright (c) Evgeniy Polyakov <zbr@ioremap.net>
.\" All rights reserved.

.TH MAN 1 2013-07-10 "Linux" "Elliptics admin's guide"
.SH NAME
dnet_ioclient \- client to elliptics.
.SH SYNOPSIS
.B dnet_ioclient \-r
.I host:port:family
.B dnet_ioclient \-r
.I host:port:family
.B [-WszaURIgcLlwmMFOSuNDCdiH]
.P
.SH DESCRIPTION
.I dnet_ioclient
.I dnet_ioclient
is a multitool, that can perform a plenty of operations on the storage, it can read and write data into the storage, execute server-side scripts, change configuration parameters of the node on the fly and get some statistics.
.SH OPTIONS
.TP
.B \-r host:port:family
Address of a storage node, where
.I family
is either 2 (AF_INET) or 10 (AF_INET6). Example,
Address of a storage node, where
.I family
is either 2 (AF_INET) or 10 (AF_INET6). Example,
.I host:1025:2.
.TP
.B \-W file
Write given file to the network storage. Example,

dnet_ioclient -r host:1025:2 -g 1:2:3 -W "file"
You can use
.B \-I
option to set a hashed key instead of a

You can use
.B \-I
option to set a hashed key instead of a
.B file.
When
.B \-I
option used
.B \-I
option used
.B file
is applied as an input filename, not as a key string.
.TP
Expand All @@ -45,7 +45,7 @@ Request VFS IO statistics from node.
Request statistics from all connected nodes.
.TP
.B \-U status
Change internal status of node. '1' - exit mode, '2' - read-only state.
Change internal status of node. '1' - exit mode, '2' - read-only state.

If you call

Expand All @@ -54,73 +54,73 @@ If you call
elliptics node will try to stop itself.
.TP
.B \-R file
Read the specified file from the storage. If
.B \-I
is not used, then
.B file
Read the specified file from the storage. If
.B \-I
is not used, then
.B file
will be used as a key string and as a result file name.
If
.B \-I
If
.B \-I
is used then
.B file
applied only for output.

For example,

dnet_ioclient -r host:1025:2 -g 1:2:3 -R file_name
In this case
.B file_name

In this case
.B file_name
will be used both as a key string and as an output filename.

dnet_ioclient -r host:1025:2 -g 1:2:3 -R file_name -I "6b8.."
In this case

In this case
.B file_name
will be used only for output file. Value of
will be used only for output file. Value of
.B \-I
option will be used as a hashed key.

.TP
.B \-I id
Hashed key. This option can be used with all of the options that need a key (like
.B \-R
or
Hashed key. This option can be used with all of the options that need a key (like
.B \-R
or
.B \-W
options) to identificate required data in the storage.

Hash value can be obtained from arbitrary string with the next call:

echo -n "key-string" | sha512sum | awk '{print $1}'
echo -n "key-string" | sha512sum | awk '{print $1}'
.TP
.B \-g groups
Group IDs to connect. If you need to perform operation for some groups (read/write operations, for example), you should provide colon-separated list of groups. For example,
Group IDs to connect. If you need to perform operation for some groups (read/write operations, for example), you should provide colon-separated list of groups. For example,
.B 1:2:3.
.TP
.B \-c cmd-event
Execute command with the specified event on the remote node. For example,

dnet_ioclient -r host:1025:2 -g 2 -c 'app@start-task'

.I dnet_ioclient
.I dnet_ioclient
with this option is performed in blocking mode. This means that, if server-side program does not response, our client will wait it for a long time before exit.
.TP
.B \-L file
Get file location in the storage. Example,

dnet_ioclient -r host:1025:2 -g 2 -L 'file_name'

.TP
.B \-l log
Log file,
.B stdout
.B stdout
by default.
.TP
.B \-w timeout
Timeout (in seconds) is used to wait for operation completion. Read operations from multiply groups are made one by one, and this timeout is used for each operation. For example in case of
.B dnet_ioclient -r host:1025:2 -g 1:2:3 -R file_name
.B dnet_ioclient -r host:1025:2 -g 1:2:3 -R file_name
call real timeout will be
.B timeout
.B timeout
multiplied by 3.

That is not right for the write operations which are performed simultaneously.
Expand All @@ -142,9 +142,9 @@ Read/write transaction size.
.TP
.B \-u file
Tell the node to delete the
.B file
.B file
from the storage.
Can be used whith the
Can be used whith the
.B \-I
option.
.TP
Expand All @@ -154,19 +154,19 @@ Use this namespace for operations. Namespace is a prefix that added to the filen
Assume that you have 2 different projects with the same filenames, and you need to save them in the storage. Just set the prefixes of projects (p1. and p2. for example) to this field for read/write/delete/ operations to have a different keys for the same filenames (p1.cfg.xml, p2.cfg.xml for example).
.TP
.B \-D file_name
Read latest data for the given
.B file_name.
When used with the
.B \-I
Read latest data for the given
.B file_name.
When used with the
.B \-I
option
.B file_name
.B file_name
is ignored.

"Latest" means that if we read data from more then one groups, client will fetch data with the latest modification time.

With this option
With this option
.I dnet_ioclient
puts received data into
puts received data into
.I stdout.

Example,
Expand All @@ -182,19 +182,19 @@ Defragmentation and sorting request: 'start' - start defragmentation, 'status' -
.B \-i flags
IO flags (see DNET_IO_FLAGS_* in include/elliptics/packet.h).
.TP
.B \-H
.B \-H
Do not hash key string, use it as is.

Elliptics key is of 64 bytes long. If your strings which you want to use as a keys less or equal this size you can pass it to elliptics as is with this option. As
.B \-I
option you can use it with the
.B \-W, \-D, \-R, \-u
Elliptics key is of 64 bytes long. If your strings which you want to use as a keys less or equal this size you can pass it to elliptics as is with this option. As
.B \-I
option you can use it with the
.B \-W, \-D, \-R, \-u
options.
.TP
.B \-h
Show help message and exit.
.SH EXAMPLES
.P
.P
Read/write file to the storage
.P
.B dnet_ioclient -r host:1025:2 -g 2 -W file_to_put
Expand Down

0 comments on commit 48a34a0

Please sign in to comment.