Hi there,

Maybe this can help!

Cheers.

Jan.

http://www-1.ibm.com/servers/eserver/iseries/optical/cdrom/lodrunrst.htm

Creating a LODRUN CD for iSeries 400 Objects

                           This example shows the process to create a
LODRUN-capable install image for objects that are not a part of a Licensed
Program. If you are
                           creating a Licensed Program (where the application
is restored using the RSTLICPGM command), see our other example
                           Lodrun Method for Licensed Program

                           Under the covers, the LODRUN command restores and
calls a CL program you provide on the CD-ROM which must be called QINSTAPP and
                           located in library QTEMP. This program can either do
the work for your install, or restore and call other programs that you have
prepared.
                           Objects to be saved in this example:

                                  MYPROD - A Product library containing your
product and the install program QINSTAPP
                                  /PRODDIR - An IFS Product directory
containing several stream file (*STMF) objects: filea, fileb, filec and filed.

                           The Product library and a copy of the install
program QINSTAPP need to be first saved to a tape in order to create the
correct format for the
                           restore. The IFS stream file objects do not. Part 1:
Creating the tape images

                           Initialize the tape:

                           INZTAP DEV(TAP01) NEWVOL(MYVOL) NEWOWNID(NEWOWNER)
CHECK(*NO)

                           Copy your QINSTAPP CL program into the QTEMP Library

                           CPY OBJ('/QSYS.LIB/MYPROD.LIB/QINSTAPP.PGM')
TODIR('/QSYS.LIB/QTEMP.LIB')

                           Change the owner to QSYS.

                           CHGOBJOWN OBJ(QTEMP/QINSTAPP) OBJTYPE(*PGM)
NEWOWN(QSYS)

                           Turn on CD mastering state.
                           To simplify calling the QlpHandleCdState() API (or
calling the QLPCDRST program), we created a command CDRST that calls the API.
Using
                           the command
                           CDRST REQSTATE(1), turn on CD mastering state.

                           Save the objects for the application
                           First save the QINSTAPP program.

                           SAVOBJ OBJ(QINSTAPP) LIB(QTEMP) DEV(TAP01)
ENDOPT(*LEAVE) DTACPR(*NO)

                           Next save the library.

                           SAVLIB LIB(MYLIB) DEV(TAP01) DTACPR(*NO)

                           Turn off CD mastering state
                           Use the same user-defined command explained above.

                           CDRST REQSTATE(0)

                           Part 2: Copy tape files back to iSeries 400 files
Create a physical file to receive the tape files

                           CRTPF FILE(MYTEMP/MYPFILE) RCDLEN(28672) MBR(*NONE)
                                 TEXT('My Product Mastering File')
MAXMBRS(*NOMAX)

                           Copy the files on tape back to the iSeries 400 into
physical file members

                           Get QINSTAPP: (Sequence #1 because we saved it
first)

                           CPYFRMTAP FROMFILE(QTAPE) TOFILE(MYTEMP/MYPFILE)
FROMSEQNBR(1)
                                     TOMBR(QTEMP) FROMDEV(TAP01) FROMREELS(*SL)
FROMRCDLEN(28672)
                                     FROMENDOPT(*LEAVE) MBROPT(*REPLACE)
FROMBLKLEN(28672)

                           Get MYPROD Library:

                           CPYFRMTAP FROMFILE(QTAPE) TOFILE(MYTEMP/MYPFILE)
FROMSEQNBR(2)
                                     TOMBR(MYPROD) FROMDEV(TAP01)
FROMREELS(*SL) FROMRCDLEN(28672)
                                     FROMENDOPT(*LEAVE) MBROPT(*REPLACE)
FROMBLKLEN(28672)

                           Part 3: Transfer the files to a PC
                           You can use either FTP or a mapped network drive
using iSeries 400 Support for Windows Network Neighborhood (AS/400 NetServer)
to
                           transfer the files. Do not use the .MBR extension in
the target file names on the PC.

                           The FTP method: FTP the saved files to the PC in
binary mode so that they become stream files. The following files need to be
transferred in
                           this example:
                           (NOTE: The install program must be QTEMP on the CD)

                           /QSYS.LIB/MYTEMP.LIB/MYPFILE.FILE/QTEMP.MBR
                           /QSYS.LIB/MYTEMP.LIB/MYPFILE.FILE/MYPROD.MBR

                           FTP the IFS product directory stream files:
                           /PRODDIR/filea
                           /PRODDIR/fileb
                           /PRODDIR/filec
                           /PRODDIR/filed

                           The mapped drive method: This will not automatically
convert the files to stream files, so you have to perform these copy commands
before
                           transferring the files.

                           CPYTOSTMF

FROMMBR('QSYS.LIB/MYTEMP.LIB/MYPFILE.FILE/QTEMP.MBR')
                                  TOSTMF('/cdftpsrc/qtemp') STMFOPT(*REPLACE)
                                  CVTDTA(*NONE) ENDLINFMT(*FIXED)

                           CPYTOSTMF

FROMMBR('QSYS.LIB/MYTEMP.LIB/MYPFILE.FILE/MYPROD.MBR')
                                  TOSTMF('/cdftpsrc/myprod') STMFOPT(*REPLACE)
                                  CVTDTA(*NONE) ENDLINFMT(*FIXED)


                           Step 4: Create the CD
                           At this point the files are on the PC so it just a
matter of writing them to the CD using your premastering software, or,
providing the images to a
                           vendor who prepares your CDs.

                           Part 5: Restore from the CD
                           For this example, the library and files would be
restored from the CD device opt01 using the following command:

                           LODRUN DEV(OPT01)


                           More Examples
                           iSeries 400 Optical Storage Home Page



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2022 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.