Guru: Move Objects with Access Client Solutions
October 14, 2019 Dawn May
Sending objects from one IBM i partition to another is a common task. Access Client Solutions’ IFS task makes it simple to copy or send objects. The IFS task was introduced in ACS in July 2016, so this is not a new development, but it may not be widely known.
Perhaps you need to send a save file to another IBM i partition. There are several ways to do this. FTP and Secure FTP are often used, but using FTP to transfer IBM i objects involves all sorts of complications. The IBM i Knowledge Center dedicates an entire section on data transfer methods and considerations when using FTP.
You can easily sidestep all this by using the ACS IFS task to send an object to another IBM i partition!
First, open the IFS task on each partition.
On the source partition, navigate to the directory where the object is stored – and remember that you can get to the QSYS.LIB file system through the IFS task.
On the target partition, navigate to the directory where you want to store the object. Now all you have to do is drag and drop the object from the source to the target. You can do this with stream files, objects in libraries (including save files), as well as library objects themselves. That’s it!
In addition to drag and drop, you can use copy/paste or send/receive objects between two IBM i partitions; under the covers they all do basically the same thing. The Send… dialog has some additional, useful options. Send…, which you will find under the View menu, has an option to send all objects, only new objects, or only existing objects. In addition, you can select multiple systems for the destination, sending the requested object to many partitions with a single request.
The screen capture below of the Send… dialog shows that you can select the destinations from your list of systems, as well as the options available.
The IFS task also provides an easy way to copy objects on a single partition. Let’s say I have a library with a lot of objects, and I want a subset of that library on my other partitions. I can use the IFS task in a similar manner to copy the desired objects from the large library to a second library on that partition, then easily send that second library to all of my other IBM i partitions.
ACS has a command line interface that allows you to automate actions or initiate them without using the main ACS GUI panel. There is an IFS plugin that allows you to copy and send objects, as well as the other IFS task actions, which would allow you to write scripts to automate moving objects around.
Section 9.12 in the Getting Started guide documents the prerequisites and lists the commands used under the covers to copy or send the objects. You must be authorized to the listed set of commands, as well as having the same user profile with the same password on all IBM i partitions. The QPWDLVL system value must be the same on all partitions involved. There is also the restriction in that you cannot move objects that reside in an independent ASP. Section 9.1.33 in the Getting Started guide documents the IFS plugin for the command line interface.
Access Client Solutions also allows you to transfer files between your IBM i and your PC. You can upload or download files with the IFS tasks or use data transfer. Uploading and downloading files does simply that — uploads or downloads a copy of the file. Data transfer allows you to transfer files to or from you PC for use in spreadsheets, and has been around for a long time.