pfsctl (BPX1PCT)

Purpose

The pfsctl (BPX1PCT) application programming interface is used to send requests to a physical file system. For more information, see the BPX1PCT service in z/OS UNIX System Services Programming: Assembler Callable Services Reference. zFS is a physical file system and supports several zFS-specific pfsctl functions, which are documented in this section.

Format

BPX1PCT (File_system_type,
         Command,
         Argument_Length,
         Argument,
         Return_value,
         Return_code,
         Reason_code); 

Parameters

File_system_type
An eight-character field. In the case of zFS, it contains the characters ZFS, followed by five blanks.
Command
An integer. There are five major ZFS commands:
  • ZFSCALL_AGGR (0x40000005)
  • ZFSCALL_CONFIG (0x40000006)
  • ZFSCALL_FILESYS (0x40000004)
  • ZFSCALL_FSINFO (0x40000013)
  • ZFSCALL_STATS (0x40000007)

Each command has a set of subcommands.

Argument_Length
An integer that contains the length of the argument.
Argument
A structure that has the pfsctl parameters followed by the subcommand parameters. The definitions of any structures that have padding bytes added by the compiler, have the padding bytes explicitly declared in the examples.
The fields of the structures are described in the Format sections of each API. These descriptions contain structure names, field names inside the structures, the length of the field, and a brief description of what the field is used for. The lengths of the field names contain C types and are as follows:
  • int or unsigned int are four bytes.
  • long long, unsigned long long, long long int, and unsigned long long int are 8 bytes.
The following list shows the general format of the Argument for all subcommands, where n depends on the particular subcommand:
Subcommand operation code     int
Parameter0                    int
Parameter1                    int
Parameter2                    int
Parameter3                    int
Parameter4                    int
Parameter5                    int
Parameter6                    int
Buffer[n]                     char[n]                        
Return_value
An integer that contains 0 if the request is successful or -1 if it is not successful.
Return_code
An integer in which the return code is stored. For these codes, see Return codes (errnos) in z/OS UNIX System Services Messages and Codes.
Reason_code
An integer that stores the reason code. If this code is of the form 0xEFnnxxxx, see EFxxrrrr reason codes in z/OS File System Messages and Codes. Otherwise, see Reason codes in z/OS UNIX System Services Messages and Codes.

Usage notes for pfsctl

  1. The major commands are summarized in Table 1 and described in detail in the following sections. The zFS pfsctl APIs will work across sysplex members. That is, zFS pfsctl APIs can query and set information on zFS aggregates that are owned by the current system. They can also access and set file system information from other systems in the sysplex.
  2. The z/OS® UNIX pfsctl (command X'C000000B') can also retrieve zFS reason code text. For more information, see the description of the PC#ErrorText pfsctl command in the usage notes for the BPX1PCT service in z/OS UNIX System Services Programming: Assembler Callable Services Reference.
  3. Most of the zFS pfsctl APIs have structures as input that allow a caller to specify both the version of input structures and the version of the desired output structures. Refer to the Usage Notes and Example sections of each individual zFS pfsctl API description to determine what versions need to be specified to produce the output structures that you want.
Table 1. Summary of APIs for pfsctl
For Command Subcommands (opcodes)
Aggregate ZFSCALL_AGGR (0x40000005)
  • Attach Aggregate (105)
  • Change Aggregate Attributes (160)
  • Compress Aggregate (264)
  • Define Aggregate (139)
  • Delete File System (136)
  • Detach Aggregate (104)
  • Encrypt Aggregate (262)
  • Decompress Aggregate (265)
  • Decrypt Aggregate (263)
  • Format Aggregate (134)
  • Grow Aggregate (129)
  • List Aggregate Status (137)
  • List Aggregate Status (Version 2) (146)
  • List Attached Aggregate Names (135)
  • List Attached Aggregate Names (Version 2) (140)
  • List File System Names (138)
  • List File System Names (Version 2) (144)
  • Quiesce Aggregate (132)
  • Salvage Aggregate (155)
  • Shrink Aggregate (266)
  • Set Auditfid (149)
  • Unquiesce Aggregate (133)
File System ZFSCALL_FILESYS (0x40000004)
  • List File System Status (142)
Configuration ZFSCALL_CONFIG (0x40000006)
  • List Systems (174)
  • Query Adm_threads Setting (180)
  • Query Aggrfull Setting (181)
  • Query Aggrgrow Setting (182)
  • Query Change_aggrversion_on_mount (246)
  • Query Client_cache_size (231)
  • Query Client_reply_storage (223)
  • Query Cmd_trace (184)
  • Query Convert_auditfid (237)
  • Query Converttov5 (250)
  • Query Debug_settings_dsn Setting (186)
  • Query EDC_buffer_pool (265)
  • Query File_threads (217)
  • Query Format_aggrversion (248)
  • Query Format_compression (262)
  • Query Format_encryption (261)
  • Query Format_perms (267)
  • Query Fsfull Setting (187)
  • Query Group Setting (214)
  • Start of changeQuery HA (269)End of change
  • Query Honor_syslist Setting (253)
  • Query Log_cache_size Setting (193)
  • Query Long_cmd_threads (255)
  • Query Meta_cache_size Setting (198)
  • Query Metaback_cache_size Setting (199)
  • Query Modify_cmd_threads (251)
  • Query Msg_input_dsn Setting (200)
  • Query Msg_output_dsn Setting (201)
  • Query Romount_recovery (233)
  • Query SMF_recording (257)
  • Query Sync_interval Setting (205)
  • Query Syslevel (238)
  • Query Sysplex_filesys_sharemode (244)
  • Query Sysplex_state (215)
  • Query Token_cache_size (216)
  • Query Trace_dsn Setting (206)
  • Query Trace_table_size Setting (207)
  • Query Tran_cache_size Setting (208)
  • Query User_cache_size Setting (210)
  • Query Vnode_cache_size Setting (212)
  • Set Adm_threads (150)
  • Set Aggrfull (158)
  • Set Aggrgrow (171)
Configuration
(continued)
ZFSCALL_CONFIG (0x40000006)
  • Set Change_aggrversion_on_mount (245)
  • Set Client_cache_size (230)
  • Set Client_reply_storage (222)
  • Set Convert_auditfid (236)
  • Set Converttov5 (249)
  • Set File_threads (176)
  • Set Format_aggrversion (247)
  • Set Format_perms (266)
  • Set Fsfull (157)
  • Start of changeSet HA (268)End of change
  • Set Honor_syslist (252)
  • Set Log_cache_size (153)
  • Set Long_cmd_threads (255)
  • Set Meta_cache_size (152)
  • Set Metaback_cache_size (163)
  • Set Modify_cmd_threads (173)
  • Set Msg_output_dsn (161)
  • Set Romount_recovery (232)
  • Set Sync_interval (154)
  • Set Sysplex_filesys_sharemode (243)
  • Set Token_cache_size (177)
  • Set Trace_dsn (159)
  • Set Tran_cache_size (160)
  • Set User_cache_size (151)
  • Set Vnode_cache_size (155)
Statistics ZFSCALL_STATS (0x40000007)
  • Statistics Compression Information (256)
  • Statistics Directory Cache Information (249)
  • Statistics Iobyaggr Information (244)
  • Statistics Iobydasd Information (245)
  • Statistics Iocounts Information (243)
  • Statistics Kernel Information (246)
  • Statistics Locking Information (240)
  • Statistics Log Cache Information (247)
  • Statistics Metadata Cache Information (248)
  • Statistics Storage Information (241)
  • Statistics Transaction Cache Information (250)
  • Statistics User Data Cache Information (242)
  • Statistics Vnode Cache Information (251)
  • Statistics Server Token Management Information (252)
  • Statistics Client Vnode Operations (253)
  • Statistics Server Vnode Operations (254)
File System Information ZFSCALL_FSINFO (0x40000013)
  • List Detailed File System Information (153)
  • Reset File System Statistics (154)
The following table lists a summary of w_pioctl calls for zFS.
Table 2. Summary of w_pioctl calls for zFS
Command Code
file snapshot 0x0000A903
fileinfo 0x0000A901