Copy a File to a New IBM i Source Physical File

Copy a File to a New IBM i Source Physical File

This example copies, in text mode, a file from a remote UNIX system to a Source Physical File on IBM i. The Source Physical File does not exist on IBM i; UDM is instructed to create it.

The Source Physical File is allocated based on the local UDM allocation attributes. UDM provides default attributes that can be changed to meet local requirements. The UDM defaults, as delivered, create a Data Physical File with a logical record length of 92 and maximum members of 1.

This example changes the file type to src in order to demonstrate how to set allocation attributes.

LIB File System

1 set _echo=yes _halton=warn
2 open unix=sol9 user=top098 pwd=p100m
3 cd unix=/opt/app/data
4 mode type=text
5 attrib local filetype=src
6 copy unix=data10.txt local=MYLIB/APPDATA(DAILY)
7 quit 


Almost all data set allocation attributes can be specified as UDM attributes giving you the ability to dynamically allocate any supported Data Physical File.

Care should be taken that conflicting allocation attributes are not specified. The results of the allocation should be checked to verify they meet your intentions. Although UDM checks attribute values, some values are provided by the system from sources that UDM cannot verify and may result in invalid or unintentional attribute combinations.

Components

Universal Data Mover Manager for IBM i