### Handle Installation Data Input Argument Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RexxPwExit/ichpwx11.txt Sets up the installation data argument. The length of the data is retrieved and stored. ```Assembler LA R5,AXRARGENTRY_LEN(R5) Set basing for next entry MVC AXRARGNAMEADDRLOW,=A(RxArg13Nm) Addr of Arg name LA R3,L'RxArg13Nm STC R3,AXRARGNAMELENGTH Length of Arg name MVC AXRARGLENGTH,=A(0) Set null data length value ICM R3,B'1111',DATALEN Get data length BZ SKIPDATA No data field ST R3,AXRARGLENGTH Set fullword length of Arg value SKIPDATA DS 0H LA R2,DATASTR Get address of data string ST R2,AXRARGADDRLOW Set address of inst data arg MVC AXRARGType,=AL1(AXRARGTypeChar) Set arg type OI AXRARGInputFlgs1,AXRARGInput Input arg ``` -------------------------------- ### Common Local Area Setup Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RexxPwExit/ichpwx01.txt This section describes the setup for installation data and user name arguments, which are typically derived from the ACEE. It highlights the need for a GETDATA subroutine to handle cases where the ACEE is not fully initialized or the command issuer is not the target user. ```Assembler * At this point, we are about to set up the installation data and * * user name arguments. These would typically exist in the ACEE that * * is passed in. However, in the case of RACINIT, the ACEE is not * * fully initialized, and is all but useless. Further, for PASSWORD, * * we cannot assume that the command issuer is the target of the * * operation. We now call the GETDATA subroutine to sort this out and * * set up a common local area with data taken from the appropriate * * location. Sebsequent setup for these two args will grab the data * ``` -------------------------------- ### Install Python Wheel and Run Sample Script Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-EzNoSQL/EzNoSQL Documentation.md Steps to set up a Python virtual environment, install the EzNoSQL wheel, and run a sample script. ```shell mkdir python -m venv source /bin/activate cd /usr/lib pip install pyeznosql-1.1.0-cp313-none-any.whl python /bin/sample_runner.py ``` -------------------------------- ### Building and Running Auto-Conversion Examples Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-Tools-and-Toys/auto-conversion/README.md Build and run both 32-bit and 64-bit auto-conversion examples by navigating to a build directory and executing the `build.sh` script. Use `build.sh clean` to remove build artifacts. ```shell > mkdir ../build > cd ../build > ../repo/build.sh ``` -------------------------------- ### Install Dependencies and Run Script Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-Automation/OMEGAMON-Integration/tems-rest-py/README.md Steps to set up a virtual environment, install required packages, and execute the main script for calling the TEMS REST API. ```bash python3 -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate pip install -r requirements.txt python call_tems.py --userid admin --password secret \ --hostname tems.example.com --port 3661 --path /api/v1/system/nodes ``` -------------------------------- ### Prepare Installation Data Argument Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RexxPwExit/ichpwx01.txt Prepares the 'instData' argument for REXX execution. It retrieves installation data from DATAAREA and sets up the argument structure. ```Assembler *********************************************************************** * Input argument: installation data ("instData") * * - The GETDATA routine has set up the inst data for us in DATAAREA.* *********************************************************************** LA R5,AXRARGENTRY_LEN(R5) Set basing for next entry MVC AXRARGNAMEADDRLOW,=A(RxArg14Nm) Addr of Arg name LA R3,L'RxArg14Nm STC R3,AXRARGNAMELENGTH Length of Arg name MVC AXRARGLENGTH,=A(0) Set null data length value ICM R3,B'1111',DATALEN Get data length BZ SKIPDATA No data field ST R3,AXRARGLENGTH Set fullword length of Arg value SKIPDATA DS 0H LA R2,DATASTR Get address of data string ST R2,AXRARGADDRLOW Set address of inst data arg MVC AXRARGType,=AL1(AXRARGTypeChar) Set arg type OI AXRARGInputFlgs1,AXRARGInput Input arg ``` -------------------------------- ### Output Header and Command Start Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RacfUnixCommands/opermit.txt This REXX code prepares the output file header and records the starting line number for subsequent commands. ```REXX Call buildOutputHeader cmdStart = output.0 + 1 /* Save line number of first command */ ``` -------------------------------- ### Example Token Environment Variable Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-Automation/OMEGAMON-Integration/tems-rest-py/README.md This snippet provides an example of a specific TEMS authorization token environment variable for a given hostname. ```text TEMS_tems-prod_AUTHORIZATION_TOKEN ``` -------------------------------- ### Parse SMF 113 Identification Section Source: https://github.com/ibm/ibm-z-zos/blob/main/SMF-Tools/SMF113Formatter/HIS113.rexx.txt Parses the Identification section of an SMF 113 record, extracting fields such as Job Name (JBN), Record Start (RST), Record Start Description (RSD), and Start Time (STP). ```REXX Parse VAR smf113recs.I . +(SMF113.IOF), SMF113.JBN +(l.SMF113JBN ) , SMF113.RST +(l.SMF113RST ) , SMF113.RSD +(l.SMF113RSD ) , SMF113.STP +(l.SMF113STP ) , ``` -------------------------------- ### Rexx: Display Installation Data Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RexxPwExit/irrpwrex.txt Displays installation data and its length. Use with caution if sensitive information is present. ```Rexx If Length(instData) = 0 Then WtoRc = AXRWTO("Installation data not provided.") Else do WtoRc = AXRWTO("Installation data length:" Length(instData)) WtoRc = AXRWTO("Installation data:" instData) End ``` -------------------------------- ### Installation Data Handling in Rexx Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RexxPwExit/irrphrex.txt Checks if 'instData' is provided. If so, it outputs the length and content of the installation data using AXRWTO. ```Rexx If Length(instData) = 0 Then WtoRc = AXRWTO("Installation data not provided.") Else do WtoRc = AXRWTO("Installation data length:" Length(instData)) WtoRc = AXRWTO("Installation data:" instData) End ``` -------------------------------- ### Create Manifest List Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-Container-Platform/multi-architecture-images/basic-image-building/readme.md Use this command to create a new manifest list for your multi-architecture image. Replace `` with your registry path. ```bash podman manifest create /exampletool:1.0 ``` -------------------------------- ### GETDATA: Retrieve User Name and Installation Data Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RexxPwExit/ichpwx11.txt Retrieves user name and installation data from various RACF sources (USER profile, ACEE) based on the operation type (ADDUSER, ALTUSER, RACINIT, PASSWORD). Handles differences in installation data length. ```Assembler * GETDATA: * * Get the user name and installation data from the appropriate * * source and put it in an area in the module's dynamic area for * * reference by the mainline. * * ADDUSER - There is no USER profile yet for the target, and the * * ACEE is for the command issuer. There is no data. * * ALTUSER - The info is obtained from the target's USER profile * * RACINIT - The info is obtained from the target's USER profile * * PASSWORD - The info is obtained from the input ACEE. Note that * * in this case, only 254 bytes max of installation data * * is chained off the ACEE (as opposed to the full 255 * * which can be obtained from the USER profile). * * * * Note: There *could* be name/data specified on the ADDUSER command * ``` -------------------------------- ### Load Credentials from .env File Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-Automation/OMEGAMON-Integration/tems-rest-py/README.md Shows how to configure credentials using a .env file in the home directory, allowing the script to run without explicit command-line arguments for user and password. ```bash # Create ~/.env file echo "TEMS_USERID=admin" >> ~/.env echo "TEMS_PASSWORD=secret" >> ~/.env chmod 600 ~/.env # Run without credentials python call_tems.py --hostname tems.example.com --path /api/v1/system/nodes ``` -------------------------------- ### Directory Structure for Basic Image Building Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-Container-Platform/multi-architecture-images/basic-image-building/readme.md This is the expected directory structure for the basic image building example. Ensure these files and directories are present before proceeding. ```text basic-image-building/ |- src/ |- src/input/ |- src/input/hello.txt |- src/java/ |- src/java/ExampleTool.java |- src/resources/ |- src/resources/Containerfile.linux |- src/resources/Containerfile.zos ``` -------------------------------- ### Image and Arguments Explanation (Linux) Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-Container-Platform/multi-architecture-images/basic-image-building/readme.md Details on how the image location and tool arguments are combined with the container's ENTRYPOINT when running. ```bash /exampletool:1.0-linux --input /input/hello.txt ``` -------------------------------- ### Run Container with Input File (Linux) Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-Container-Platform/multi-architecture-images/basic-image-building/readme.md Run the container and mount a host directory containing an input file into the container. The volume mount uses the format `-v :`. ```bash basic-multi-arch-image$ podman run -it --rm -v $PWD/src/input:/input /exampletool:1.0-linux --input /input/hello.txt Hello from the ExampleTool. ``` -------------------------------- ### Build Container Image (Linux) Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-Container-Platform/multi-architecture-images/basic-image-building/readme.md Build the container image using Podman. The first build may take longer as it pulls base images. ```bash podman build -f src/resources/Containerfile.linux -t /exampletool:1.0-linux . ``` -------------------------------- ### Extract STARTED Profiles with IRRUTIL Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/IRRXUTIL/XSTARTED.txt This REXX code uses the IRRXUTIL function to extract profiles from the RACF STARTED class. It iterates through profiles until no more are found or an error occurs. Ensure you have the necessary RACF authorizations. ```REXX /*rexx*/ /*********************************************************************/ /* */ /* Copyright 2014, 2022 IBM Corp. */ /* */ /* Licensed under the Apache License, Version 2.0 (the "License"); */ /* you may not use this file except in compliance with the License. */ /* You may obtain a copy of the License at */ /* */ /* http://www.apache.org/licenses/LICENSE-2.0 */ /* */ /* Unless required by applicable law or agreed to in writing, */ /* software distributed under the License is distributed on an */ /* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, */ /* either express or implied. See the License for the specific */ /* language governing permissions and limitations under the License. */ /* */ /********************************************************************* Name: XSTARTED Author: Bruce Wells - brwells@us.ibm.com Purpose: Health-check the STARTED class by identifying profiles that: - do not contain a period - do not have an STDATA segment - do not have a user specified - specify an undefined user - specify an un-PROTECTED user - specify an undefined group - specify a user who is not connected to the specified group - specify =MEMBER for both the user and group Input: None Example: ex 'MYHLQ.RACF.CLISTS(XSTARTED)' Authorization required: - READ access to IRR.RADMIN.RLIST in FACILITY plus authority to list the profile's STDATA segment - READ access to IRR.RADMIN.LISTUSER in FACILITY plus authority to list the user profile of the USER value - READ access to IRR.RADMIN.LISTGRP in FACILITY plus authority to list the group profile of the GROUP value **********************************************************************/ profile = " " /* Start at the beginning */ generic = "FALSE" /* with discrete profiles */ /* Loop until STARTED profiles are exhausted */ Do Until (resrc = '12 12 4 4 4') /* Extract the next STARTED profile */ resrc=IRRXUTIL("EXTRACTN","STARTED",profile,"RES",,generic) Select When word(resrc,1) = 0 Then /* No problems */ Do End When resrc = '12 12 4 4 4' Then /* No more profiles */ Leave Otherwise /* Some sort of error */ ``` -------------------------------- ### Run z/OS Container (Initial) Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-Container-Platform/multi-architecture-images/basic-image-building/readme.md Executes the built z/OS container image. The output indicates that input arguments are required. ```bash basic-multi-arch-image$ podman run -it --rm /exampletool:1.0-zos Invalid arguments. Usage: java ExampleTool --input ``` -------------------------------- ### Example JCL for Dataset Creation Source: https://github.com/ibm/ibm-z-zos/blob/main/zOSMF/ZosmfRESTClient/rest-jobs.html This is an example JCL snippet used for creating a dataset via the z/OSMF REST Jobs API. It includes parameters for job class, message level, region, and dataset disposition. ```jcl //CREATEDS JOB (99999),'IBMUSER', // CLASS=A,MSGLEVEL=(1,1),REGION=0M //******\n//STEP1 EXEC PGM=IEFBR14 //DSN DD DSN=ZTRIAL.ZOSMF.RESTDS, // DISP=(NEW,CATLG,DELETE), // DCB=(DSORG=PS,BLKSIZE=0,RECFM=FB,LRECL=80), // SPACE=(TRK,(10,10)), // UNIT=SYSALLDA, // VOL=SER=PEVTS3 /\* ``` -------------------------------- ### Prepare Installation-Specified Data Argument Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RexxPwExit/ichpwx01.txt Sets up the 'instAddr' argument, which is installation-specified data. This is distinct from 'instData'. ```Assembler *********************************************************************** * Input argument: Installation-specified data ("instAddr") * * - Not to be confused with installation data, this argument is * ``` -------------------------------- ### Compile and Link Sample C Program Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-EzNoSQL/EzNoSQL Documentation.md Commands to compile and link the sample C program igwznsqsamp1.c. ```shell xlc -c -qDLL -qcpluscmt -qLSEARCH="//'SYS1.SCUNHF'" igwznsqsamp1.c xlc -o igwznsqsamp1 igwznsqsamp1.o -W l,DLL /usr/lib/libigwznsqd31.x ``` -------------------------------- ### Retrieve Installation Data and User Name Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RexxPwExit/ichpwx11.txt Calls the GETDATA subroutine to retrieve installation data and user name, either from the ACEE or profile. This is crucial for commands where the ACEE might not be fully initialized or may represent the command issuer instead of the target user. ```Assembler *********************************************************************** * At this point, we are about to set up the installation data and * * user name arguments. These would typically exist in the ACEE that * * is passed in. However, in the case of RACINIT, the ACEE is not * * fully initialized, and is all but useless. Further, when the * * caller is ADDUSER or ALTUSER, the ACEE is that of the command * * issuer; not the user whose phrase is being changed. In short, the * * only time the ACEE is useful in this regard is for the PASSWORD * * command. We now call the GETDATA subroutine to sort this out and * * set up a common local area with data taken from the appropriate * * location. Sebsequent setup for these two args will grab the data * * from this local location. * *********************************************************************** BAL R9,GETDATA Get data/name from ACEE or profile ``` -------------------------------- ### z/OS which command usage examples Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-Tools-and-Toys/which/README.md Demonstrates how to invoke the 'which' REXX procedure to search for procedures in the PROCLIB concatenation. Shows cases where a procedure is not found and where it is found. ```tso @WHICH TYRONE TYRONE not found in PROCLIB concatenation PROC00 @WHICH TYRONE PROC01 TYRONE not found in PROCLIB concatenation PROC01 @WHICH LISTMEM PROC01 ADCDMST.EXEC(LISTMEM) @WHICH HLASMC HLA.SASMSAM1(HLASMC) ``` -------------------------------- ### Check SECLEVEL Logging Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/IRRXUTIL/XSETRAUD.txt Checks if SECLEVEL logging is enabled. No setup is required. ```REXX if RES.BASE.SLEVAUDT.1 = "TRUE" then say " SECLEVEL logging is enabled" else say " SECLEVEL logging is not enabled" ``` -------------------------------- ### Get Job Status Source: https://github.com/ibm/ibm-z-zos/blob/main/zOSMF/ZosmfRESTClient/rest-jobs.html Retrieves the status of a specific job on the z/OS system. ```APIDOC ## GET /jobs/{jobname}/{jobid} ### Description Retrieves the status of a specific job on the z/OS system. ### Method GET ### Endpoint /zosmf/restjobs/jobs/{jobname}/{jobid} ### Parameters #### Path Parameters - **jobname** (string) - Required - The name of the job. - **jobid** (string) - Required - The ID of the job. ### Request Example ```javascript function getJobStatus() { var jobname = document.getElementById("jobname").value; var jobid = document.getElementById("jobid").value; var xhr = new XMLHttpRequest(); var url = "https://pev076.pok.ibm.com/zosmf/restjobs/jobs/" + jobname + "/" + jobid; xhr.open("GET", url, true); xhr.setRequestHeader("X-CSRF-ZOSMF-HEADER", "zosmf"); xhr.onreadystatechange = function () { if (xhr.readyState === 4 && xhr.status === 200) { document.getElementById("result").innerHTML = xhr.responseText; } }; xhr.send(); } ``` ### Response #### Success Response (200) - **responseText** (string) - The response text containing the job status. ``` -------------------------------- ### Compile and Run Sample Java Program Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-EzNoSQL/EzNoSQL Documentation.md Commands to compile and run the sample Java program Igwznsqsamp1.java. ```shell cd /samples javac -cp /usr/include/java_classes/igwznsq.jar Igwznsqsamp1.java java -cp /usr/include/java_classes/igwznsq.jar:. Igwznsqsamp1 ``` -------------------------------- ### Process Keywords and Build Output Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RacfUnixCommands/oralter.txt This snippet shows the main processing loop for keywords and the construction of output commands. It handles initialization, keyword processing, and error handling. ```REXX If outfileVal /= '' Then outputFile = outfileVal Call buildOutputHeader cmdStart = output.0 + 1 /* Save line number of first command */ execRc = ProcessKeywords(path) If execRc /= 0 Then Signal GETOUT ``` -------------------------------- ### Check Command Violation Logging Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/IRRXUTIL/XSETRAUD.txt Checks if logging for command violations is enabled. No setup is required. ```REXX if RES.BASE.CMDVIOL.1 = "TRUE" then say " Logging of command violations is enabled" else say " Logging of command violations is not enabled" ``` -------------------------------- ### Check APPC Transaction Logging Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/IRRXUTIL/XSETRAUD.txt Checks if logging for APPC transactions is enabled. No setup is required. ```REXX if RES.BASE.APPC.1 = "TRUE" then say " Logging of APPC transactions is enabled" else say " Logging of APPC transactions is not enabled" ``` -------------------------------- ### Initialize Directory and File Counts Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RacfUnixCommands/orlist.txt Initializes variables for directory and file counts, and sets up the initial path for directory traversal. ```REXX call value @stem,'' dirlist='' dirlist.1=path dirlist=1 dirs=1 files=0 ``` -------------------------------- ### ICHPWX11 Initialization and Storage Allocation Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RexxPwExit/ichpwx11.txt This snippet shows the initial setup of the ICHPWX11 program, including setting the base register, establishing addressability for the input parameter list, and allocating dynamic storage using GETMAIN. It specifies subpool 229 for the dynamic area and initializes it using MVCL. ```Assembler &EYECATCHER SETC ' ICHPWX11 V4 IRRPHREX ' * caller of IRRPHREX via Sysrexx ICHPWX11 CSECT , ICHPWX11 AMODE 31 ICHPWX11 RMODE 31 ICHPWX11 CSECT SAVE (14,12),,&EYECATCHER-&SYSDATE-&SYSTIME- LR R12,R15 Program addressability USING ICHPWX11,R12 Set base register LR R10,R1 Save input PWX2PL address USING PWX2PL,R10 Basing for input plist * * need dynamic storage * L R0,DYNSIZE Dynamic area size to R0 GETMAIN RU,LV=(0),SP=229 Getmain dynamic area @L3C LR R11,R1 Dynamic area addressability LR R2,R1 Dynamic address to R2 for MVCL L R3,DYNSIZE Get length to initialize LA R4,0 Source LA R5,0 Source length of 0 + pad byte of 0 MVCL R2,R4 Clear the dynamic area storage ``` -------------------------------- ### Get Field Entry Address Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RACSEQ/racseq.asm.txt Obtains the address of the first field entry and establishes addressability. ```asm LA R5,ADMN_USRADM_FLDSTRT Get address of field entry USING ADMN_USRADM_FLDENTRY,R5 ``` -------------------------------- ### Get Positional Path Name Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RacfUnixCommands/orlist.txt Extracts the first positional argument as the path name for the operation. ```REXX path = Word(keywords,1) /* 1st keyword is the path name */ ``` -------------------------------- ### Initialize REXX Environment and Variables Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RacfUnixCommands/orlist.txt Initializes the UNIX environment using syscalls and prepares a stem variable for output lines. ```REXX call syscalls('ON') /* Initialize UNIX environment */ address syscall output. = '' /* Initialize stem for output lines */ output.0 = 0 ``` -------------------------------- ### Initialize and Parse Input Command Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RACSEQ/racseq.asm.txt Initializes parse structures and invokes IKJPARS to parse the input command image. Sets up PPLUPT, PPLECT, PPLCBUF, PPLPCL, and PPLANS. ```asm * Initialize parse stuff and parse the input command image. * L R1,CPPLPTR Get address of CPPL USING CPPL,R1 And establish addressability LA R6,DYNPPL GET ADDRESS OF PPL USING PPL,R6 AND ESTABLISH ADDRESSABILITY MVC PPLUPT,CPPLUPT PUT IN THE UPT ADDRESS FROM CPPL L R2,CPPLUPT And keep it around in R2 ST R2,UPT@ And save it for extract-next @L1A MVC PPLECT,CPPLECT PUT IN THE ECT ADDRESS FROM CPPL L R3,CPPLECT And keep it around in R3 ST R3,ECT@ And save it for extract-next @L1A MVC PPLCBUF,CPPLCBUF PUT IN THE COMMAND BUFFER ADDRESS L R5,=A(RACPDE) Get address of parse macros (PCL) ST R5,PPLPCL STORE IT IN THE PPL LA R5,PDLPTR Get address of parse result anchor ST R5,PPLANS STORE IT IN THE PPL CALLTSSR EP=IKJPARS,MF=(E,PPL) INVOKE PARSE LTR R15,R15 IF PARSE RETURN CODE IS ZERO BZ GETANS Go process results DROP R1 ``` -------------------------------- ### Locate RCVT Structure Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/IRRXUTIL/XSETRPWD.txt Retrieves the RCVT address from storage and verifies its identifier. This is a prerequisite for checking installed exits. ```REXX cvt = c2d(storage(10,4)) rcvt = C2d(Storage(D2x(CVT + 992),4)) RCVTID = Storage(D2x(RCVT),4) If RCVTID <> 'RCVT' then do say "The RCVT does not have the expected identifier for RACF." exit 2 end ``` -------------------------------- ### ORALTER Example: Remove 'Other' Write Permissions Recursively Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-RACF/Downloads/RacfUnixCommands/oralter.txt Removes write permissions for 'others' in a directory and its subdirectories. ```shell ORALTER /u/brwells PERMS(o-w) RECURSIVE ``` -------------------------------- ### Open EzNoSQL Database Source: https://github.com/ibm/ibm-z-zos/blob/main/zOS-EzNoSQL/EzNoSQL Documentation.md Demonstrates how to open an EzNoSQL database with specific options, including timeout and auto-commit settings. Ensure the database name is correctly specified. ```C char* base_name = "MY.JSON.DATA"; // Database name for primary index created with znsq_create() znsq_connection_t connection = 0; // Initialize connection token unsigned int open_flags = 0; // Initialize open flags znsq_open_options open_options = {0}; open_options.timeout = 5; // Timeout lock waiters after 5 seconds open_options.autocommit = 1; // Auto commit after every update open_flags = VSAMDB_OPEN_FLAG_FORCE_UPDATE; // Set flags to write force on int return_code = znsq_open(&connection, base_name, open_flags, &open_options); if (return_code != 0) { printf("Unexpected return code received from znsq_open()\n"); printf("Return code from znsq_open(): X%x\n", znsq_err(return_code)); } return connection; ```