Summary:
Finds the first occurrence of a data block in files.
Request specification:
Name |
Min/Max |
Type |
Description |
|
|
|
|
|
|
|
|
|
|
|
Starting search offset. Positive offset means offset from the beginning of a file, and negative from the end of a file. |
|
|
|
Data block to find in a file. |
|
|
|
Search backwards. |
|
|
|
|
Returns:
Name |
Min/Max |
Type |
Description |
|
|
|
|
|
|
|
|
|
|
The name of the file containing the specified block of data. |
|
|
|
|
Offset at which the block is located in the file. |
|
|
|
|
Example:
Search for a string "aaa" in the /tmp.txt
file on the specified Virtuozzo Container.
Input
<packet version="4.0.0">
<dst>
<host>24b9acf5-8ca5-49c9-b7b1-4c93fe048389</host>
</dst>
<target>filer</target>
<data>
<filer>
<search>
<cwd>Lw==</cwd>
<path>L3RtcC50eHQ=</path>
<offset>0</offset>
<block>YWFhYQ==</block>
</search>
</filer>
</data>
</packet>
Output
<packet version="4.0.0">
<origin>filer</origin>
<target>vzclient123</target>
<data>
<filer>
<file>
<name>dG1wLnR4dA==</name>
<offset>15</offset>
</file>
</filer>
</data>
</packet>