Top
Systemwalker Operation Manager  Reference Guide
FUJITSU Software

10.2.5 fctrlcli File Operation Command

Synopsis

fctrlcli HostName {/delete | /rename | /mkdir | /rmdir}
        /f:FilePathName [/fn:FileName] [/un:UserName]
        [/lg:LoginGroup] [/rc:nn /ri:nnnn]

Description

The fctrlcli command operates files or directories on a client. For file operations, the command deletes or renames files. For directory operations, the command creates or deletes directories. File operations with this command are performed using the Windows shared directories (Windows network share method) or through FTP services (FTP method).

If you wish only to operate remote files, you can do it even on the remote server without having Systemwalker Operation Manager installed.

Parameters

HostName

Specifies a host name of the client on which the file is to be operated. The host name in HostName must be specified using up to 15 characters. If HostName contains a space character, enclose it in double quotation marks.

/delete

Deletes a file.

/rename

Renames a file.

/mkdir

Creates a directory.

/rmdir

Deletes a directory.

/f:FilePathName

Specify a path name of the file or directory to be operated. You can use a wildcard for the file name if specified with the /delete or /rename parameter.

Since wildcard characters such as an asterisk (*) have special meaning to shell, you need to enclose FilePathName with either single or double quotation marks as necessary.

Use one of the following methods to specify the path name of the file to FilePathName in the URL format. The path name must be no longer than 255 characters, and enclose it in double quotation marks if a space character is contained.

A local drive path:

Specify a path including the drive name.

Specify the path name of desired file directly after "file://" character string.

Example:

file://c:\database\database.db

UNC method (Windows network share method):

Specify a path in the format of "\\computer name\share name". For "computer name", specify a Windows-based computer name within 15 alphanumeric characters. Specify a share name within 80 bytes.

Specify the path name of desired file directly after "file://" string.

Example:

file://\\foo\share\database\database.db

By specifying a path on the FTP server (FTP method):

Specify the path name to the FTP server.

The path name can be specified with a full path name or relative path name from the current directory in logging in with FTP.

Specify the path name in the format of "server name/path name of desired file" directly after "ftp://" string.

Example) To specify using the full path name:

ftp://foo.bar.com//usr/database/database.db

Example) To specify using the relative path name:

ftp://foo.bar.com/database/database.db

/fn:FileName

Specifies the new file name you change to. You can use a wildcard for this parameter.

Since wildcard characters such as an asterisk (*) have special meaning to shell, you need to enclose FileName with either single or double quotation marks as necessary.

Specify a file name in FileName within 255 characters, and enclose it in double quotation marks if a space character is contained.

This parameter is valid if the /rename parameter is specified.

/un:UserName

Specifies a user name to be used to access the file or directory specified in FilePathName.

The user name to be specified must be set in the password management book in advance. UseName must be no longer than 20 alphanumeric characters. If UserName contains a space character, enclose it in double quotation marks.

If FilePathName is specified using a local drive path or the UNC method, this parameter's specification is ignored. In this case, you need to access the target file with the user privileges logged in to the client running the Client Task Link service. If FilePathName is specified using a path on the FPT server, be sure to specify this parameter.

/lg:LoginGroup

Specifies a login definition name used to manage the password management book. The login definition name in LoginGroup must be no longer than 256 characters, and enclose it in double quotation marks if a space character is contained.

If the /un parameter is specified, be sure to specify this parameter.

/rc:nn

Specifies the retry count in case an error occurs in file operation.

Specify an integer value between 0 and 99 for nn. Setting any other value results in an error. If omitted, no retry is performed.

/ri:nnnn

Specifies the retry interval in case an error occurs. This specification is valid if 1 or a greater value is specified in the /rc:nn parameter.

Specify an integer value between 0 and 9999 (in seconds) for nnnn. Setting any other value results in an error. The default value is 0.

Return Values

Return value

Meaning

0

Completed

Value other than 0

Abended

Command Location

Solaris

/opt/FJSVsnjss/bin

HP-UX

/opt/FHPsnjss/bin

AIX

/opt/FAIXsnjss/bin

Linux

/opt/FJSVsnjss/bin

Example

In this example, the command is executed to delete the local file "c:\database\master\database.db" on the client "foo". If deletion failed, retry is performed up to three times at an interval of 60 seconds.

fctrlcli foo /delete /f:file://c:\\database\\master\\database.db
/rc:3 /ri:60

Execution Results/Output Format

After the command has been through processing, the information at command completion is output to the standard output.

The contents to be output are shown below:

[Process start time] MM-DD-YYYY HH:MM:SS
[Client host name] HostName
[Server host/User name] Server host name/user name (***)
[Retry count] Number of retries performed (***)
[Error] Error message (***)
[File operation type] File operations/Directory name New file name (*)(**)
[Retry count] Number of retries performed (*)
[Error] Error message (*)
[Process end time] MM-DD-YYYY HH:MM:SS
*:

If a wildcard is used, the information of each file is output by file basis.

**:

The new file name you changed to is only output if the /rename parameter is specified.

***:

This information is output if the /un parameter is specified.

In [Error], "None" is output if the command completed successfully. A message is output if the command is canceled or failed. For details on the messages, see the Systemwalker Operation Manager Message Guide.

In [File operation type], any of "Delete file," "Rename file," "Create directory" or "Delete directory" is output.

If an error occurs before performing file operations, a message is output in the following format:

[Process start date and time] MM/DD/YYYY HH:MM:SS
[Command error] Error message
[Process end date and time] MM/DD/YYYY HH:MM:SS

For details on the messages, see the Systemwalker Operation Manager Message Guide.

Cautions