Open System Services Porting Guide (G06.29+, H06.06+, J06.03+)
The setacl Utility
For filesets that support OSS ACLs, use the setacl utility to change access control lists for an OSS
file. For each file specified, the setacl utility does one of two things:
• Replaces the entire ACL.
• Adds, modifies, or deletes the specified ACL entries, including default entries for directories.
Only a user with a user ID equal to the super ID or file owner, or with a user ID or group affiliation
qualifying for membership in the Safeguard SECURITY-OSS-ADMINISTRATOR group can use the
setacl utility to change the file access permissions for a file.
OSS ACLs are not supported on Guardian files. Refer to the Open System Services Programmer’s
Guide for more information about OSS ACLs and their use.
The cp Utility
You can use the OSS cp utility to copy files in the OSS environment, within the portion of the
Guardian file system accessible through the /G directory, or between different file systems. By
copying files within /G, you obtain the same results as using the Guardian procedure FUP DUP.
A complete binary copy is made, preserving all attributes.
The following example copies a file within /G and creates another file in /G:
cp /G/data01/stu01/report /G/data01/stu01/reprtold
cp copies ASCII text files (type 180) and untyped files (type 0) from the Guardian environment to
the OSS environment without conversion. EDIT files (type 101) are converted to ASCII text files.
Attempts to copy any other type of file return an error.
The cp utility converts (and truncates, if necessary) OSS pathnames to compatible Guardian
filenames.
Normally, when files are copied to /G, the file has the date and timestamp of when the copy
occurred. If the -Wclobber parameter is specified, cp sets the date and timestamp to that of the
from file.
The file Utility
You can use the OSS file utility to detect Guardian file types. File types in /G are based on the
Guardian file codes (types). The following command displays the pathname of the file and the file
type:
file /G/data01/stu01/teditpfl
The ls Utility
The OSS ls utility lists and generates statistics for files. You can use the -W parameter and a /G
filename to display a Guardian file type. No other ls flags can be specified with the -W parameter;
it is reserved for only Guardian files.
The following ls utility example is followed by its output:
ls -W /G/data01/stu01/report
/G/data01/stu01/report 101
The mv Utility
Use the OSS mv utility moves the location of files and directories and renames them. You can use
mv to rename filenames in /G only if the specified filenames reside within the same volume.
The following is an example of using the mv utility within /G:
mv /G/data01/stu01/record /G/data01/stu01/record2
Using OSS Commands to Manage Guardian Objects 69