Newsletters   Subscriptions  Forums  Store   Career  Media Kit  About Us  Contact  Search   Home 
fhg
Volume 5, Number 4 -- January 26, 2005

The Save-Restore Commands

Hey, Ted:


We have a new machine and have joined the world of logical partitioning. We have a partition for production and one for development. I am struggling with copying data and source code between the two machines. FTP copies source members without a problem, but it drops the modification dates on the source records. To copy data files, I've been transmitting save files in binary mode, which is a hassle. Also, I'd like to set up a scheduled job to refresh certain files on the test system from the production system at night, and while FTP would work, it would be difficult for my job to determine if the transmission succeeded. Do you have any other ideas?

--Andrew


I use FTP heavily, but only because it's convenient. For robust computing, you need something more than cobbled-together utilities. The iSeries system on which I spend most of my time also has two partitions, as you've described. The administrator has it set up for both TCP/IP and SNA communications. He tells me that it is possible to use both protocols if you have an Ethernet card for each partition.

If you can use SNA, let me suggest you look at the SAVRSTxxx commands, especially Save Restore Object (SAVRSTOBJ). Two other commands that you might need occasionally are Save Restore Library (SAVRSTLIB) and Save Restore Objects (SAVRST), for the IFS. There are also Save Restore Configuration (SAVRSTCFG), Save Restore Changed Objects (SAVRSTCHG), and Save Restore Doc/Lib Object (SAVRSTDLO) commands. The SAVRSTxxx commands have been around for a while, but I never had much use for them until I began working on a partitioned system.

The SAVRSTxxx commands go through a process similar to the binary FTP of save files, but without the hassle. Here are some examples.

This command copies data file SOMEFILE from the production system to the TEST system.

SAVRSTOBJ OBJ(SOMEFILE) LIB(MYLIB) RMTLOCNAME(TEST) 
   OBJTYPE(*FILE)

This command copies an entire source physical file to the test system.

SAVRSTOBJ OBJ(QRPGLESRC) LIB(MYLIB) RMTLOCNAME(TEST)

Here's a command to copy one RPG source member, MYSRCMBR, from production to TEST. Notice MBROPT(*NEW) was used here, because the source member did not already exist in QRPGLESRC on the TEST system.

SAVRSTOBJ OBJ(QRPGLESRC) LIB(MYLIB) RMTLOCNAME(TEST)
   OBJTYPE(*FILE) FILEMBR((QRPGLESRC (MYSRCMBR))) MBROPT(*NEW)                

If all goes well, you'll see message CPCAD80 (x objects saved and restored). If you get message CPFAD8D (an error occurred during the SAVRSTOBJ operation), check the messages in the job log to find the exact cause. Depending on things like object ownership and authority, you may have to specify MBROPT(*ALL) ALWOBJDIF(*ALL). If so, you have a problem, because you must have *ALLOBJ authority to use ALWOBJDIF(*ALL). Do not assume that the transfer did not take place when you see CPFAD8D. The transfer may have been successful, but the error may have been sent because authority changes took place.

Another nice thing about the SAVRSTxxx commands is that they do not require enrollment in the system distribution directory, as SNDNETF (Send Network File) does.

--Ted


Click here to contact Ted Holt by e-mail.

Sponsored By
GUILD COMPANIES

On Sale Now!
The iSeries Express Web Implementer's Guide
by Brian W. Kelly

Setting up WebSphere Express, IBM's business solutions, WebFacing, iSeries Access
for Web, and HATS/LE is a snap with this how-to guide.

WebSphere Express for iSeries is the new free server for all of IBM's iSeries dynamic Web-enabling offerings. Whether your applications are in RPG, COBOL, or Java,
you can now enjoy the benefits of bringing them to the Web.
There's only one small issue: No applications can run unless you first have your WebSphere Application Server Express running.

Learn how to order, install, fix, and run all of IBM's Web application enablers for the iSeries, including: WebSphere Express Server, Apache HTTP Server, WDSc, WebFacing, IBM Telephone Directory, IBM Survey Creator, iSeries Access for the Web, and HATS/LE.

Sale Price $39 (Regular Price $59)
Sale Ends January 31
Get Your Copy Today!

Shop at the IT Jungle Store
http://store.itjstore.com/imgu.html


Technical Editors: Howard Arner, Joe Hertvik, Ted Holt,
Shannon O'Donnell, Kevin Vandever
Managing Editor: Shannon Pastore
Contributing Technical Editors: Joel Cochran, Wayne O. Evans, Raymond Everhart,
Bruce Guetzkow, Marc Logemann, David Morris
Publisher and Advertising Director: Jenny Thomas
Advertising Sales Representative: Kim Reed
Contact the Editors: To contact anyone on the IT Jungle Team
Go to our contacts page and send us a message.


THIS ISSUE
SPONSORED BY:

Advanced Systems Concepts
Patrick Townsend & Associates
Guild Companies


BACK ISSUES

TABLE OF
CONTENTS
An Introduction to WDSc Table Views

Another Reason to Use P-Fields

The Save-Restore Commands


The Four Hundred
Oracle Lays Out Plans to Fuse Its Three ERP Suites

ERP Vendors Target PeopleSoft, JDE Bases

IBM Ends 2004 with Most Profitable Quarter in Its History

Four Hundred Stuff
2005: A SOX Auditor's Odyssey

iSeries Plays a Central Role in MoMA's Expansion

CXL Debuts iSeries Security Reporting Tool

Four Hundred Monitor


Copyright © 1996-2008 Guild Companies, Inc. All Rights Reserved.
Guild Companies, Inc. (formerly Midrange Server), 50 Park Terrace East, Suite 8F, New York, NY 10034
Privacy Statement