DOKK / manpages / debian 10 / s390-tools / cmsfs-fuse.1.en
CMSFS-FUSE(1) General Commands Manual CMSFS-FUSE(1)

cmsfs-fuse - File system for z/VM CMS disks

Use the cmsfs-fuse command to provide read and write access to files stored on a z/VM CMS disk. The cmsfs-fuse file system translates the record-based EDF file system on the CMS disk to UNIX semantics. After mounting the CMS disk, you can use common Linux tools to access the files on the disk. You can enable automatic conversions of text files from EBCDIC to ASCII.

Attention: You can inadvertently damage files and lose data when directly writing to files within the cmsfs-fuse file system. To avoid problems when writing, multiple restrictions must be observed, especially with regard to linefeeds (see section RESTRICTIONS).

If you are unsure about how to safely write to a file on the cmsfs-fuse file system, copy the file to a location outside the cmsfs-fuse file system, edit the file, and then copy it back to its original location.

Fuse or mount command options. For fuse options see below, for mount options see mount(8).
Print usage information, then exit.
Print version information, then exit.

Interpret all files on the CMS disk as text files and convert them from EBCDIC to ASCII.
The codepage of the files on the CMS disk. If this option is not specified the default codepage CP1047 is used. For a list of all available codepages see iconv --list.
The codepage to which CMS files should be converted to. If this option is not specified the default codepage ISO-8859-1 is used. For a list of all available codepages see iconv --list.
Interpret files on the CMS disk as text files based on the file type and convert them from EBCDIC to ASCII. The file types that are treated as text files are taken from a configuration file (see section CONFIGURATION FILES).

Enable debug output (implies -f)
Foreground operation
Allow access by other users
Allow access by root
Allow mounts over non-empty file/dir
Enable permission checking by kernel
Set maximum size of read requests
Cache files in kernel
Enable caching based on modification times
Set file permissions (octal)
Set file owner
Set file group
Set maximum size of write requests
Set maximum readahead
Perform reads asynchronously (default)
Perform reads synchronously
Enable write operations with more than 4 KB

Use the following extended attributes to handle the CMS characteristics of a file:

user.record_format: The format of a file. Allowed values are F for fixed record length files and V for variable record length files. This attribute can be set only if the file is empty.

user.record_lrecl: The record length of a file. This attribute can be set only for a fixed record length file and if the file is empty. A valid record length is an integer in the range 1-65535.

user.file_mode: The file mode of a file which is interpreted by CMS. The file mode consists of a mode letter from A-Z and mode number from 0-6.

New files are created by default as variable files with file mode A1.

rename and creat: Uppercase file names are enforced.

truncate: Only shrinking of a file is supported. For fixed length record files, the new file size must be a multiple of the record length.

unlink: Creating a file with the name of a previously unlinked file which is still in use is not supported and will fail with -ENOENT.

write: Writes are supported only at the end of the file. A write on a fixed length record file always writes a multiple of the record length. If additional bytes are added, the bytes are filled with zero in binary mode or with spaces in ASCII mode. Sparse files are not supported. If the cp tool is used to write files to a CMS disk the option "--sparse=never" must be specified.

If ASCII translation is enabled for a file a linefeed character determines the end of a record. The following restrictions must be observed for writing files in ASCII mode: For fixed record length files a linefeed must occur exactly after a record of the length specified in the fixed record length. For variable record length files a linefeed must occur after the maximum record length is reached or earlier. If a record of a variable record length file consists only of a linefeed character cmsfs-fuse adds a space to this record since empty records are not supported by the CMS file system.

cmsfs-fuse uses a configuration file for automatic translation based on the file type. Upon startup, cmsfs-fuse evaluates the file .cmsfs-fuse/filetypes.conf in the user's home directory. If the file does not exist cmsfs-fuse evaluates the file /etc/cmsfs-fuse/filetypes.conf.

The filetypes.conf file contains the CMS file types that are automaticaly translated to ASCII if cmsfs-fuse is started with the -t option. The syntax of the configuration file is one file type per line. Lines that start with a # followed by a space are treated as comments and are ignored. The file type is 8 characters long and must consist of valid CMS file name characters only.

The default file types in the configuration file were taken from the z/VM TCPIP.DATA file (z/VM version 5.4.0).

To mount the CMS disk with the name dasde enter:


# cmsfs-fuse /dev/dasde /mnt

To mount the CMS disk with the name dasde and enable automatic translation of known text files enter:


# cmsfs-fuse -t /dev/dasde /mnt

To mount the CMS disk with the name dasde and enable automatic translation of all files to UTF-8 enter:


# cmsfs-fuse --to=UTF-8 -a /dev/dasde /mnt

To unmount the CMS disk mounted on /mnt enter:


# fusermount -u /mnt

To show the record format of file PROFILE.EXEC assuming the CMS disk was mounted on /mnt:


# getfattr -n user.record_format /mnt/PROFILE.EXEC

The following example assumes that an empty, fixed record format file, PROFILE.EXEC, can be accessed on a CMS disk that has been mounted on /mnt. To set the record length of PROFILE.EXEC to 80 bytes:


# setfattr -n user.record_lrecl -v 80 /mnt/PROFILE.EXEC

attr (5), getfattr (1), setfattr(1), iconv(1) and Linux on System z: Device Drivers, Features and Commands

February 2010 s390-tools