Copying a Product Line to Create a New Product Line
Use this procedure if you want to copy an existing product line to another Environment in order to create a new product line that is a duplicate of the existing one.
This procedure assumes you have completed the preparation steps for copying a product line. See Preparing the "From" Product Line.
To copy a product line in order to create a new product line
-
Log in as LAWSON to the "To" machine.
This user should have access to all Environment executables.
-
If your login does not include a call to LAWENV, set the environment variables.
-
If you installed Lawson Core Technology on an IASP, at the IBM i command prompt, type
SETASPGRP IASPName
-
To set the variables, at the IBM i command line, type
CALL LAWENV
The list of available Lawson Environments appears on your screen.
- Type the appropriate Environment name and press Enter.
-
If you installed Lawson Core Technology on an IASP, at the IBM i command prompt, type
-
Turn off security. At the command line, type
lsconfig -c password OFF
-
Create the product line. At the command line, type
createprodline toPL
- Make sure that the $LAWAPPSRCLIB and $LAWAPPPGMLIB directories exist and that /etc/lawson/lawson.env contains entries for these.
-
Copy the product line source from the "From" system to the "To" product line. You do not need to copy all directories and files from the "From" product line. If you are copying between different machines or servers, you may want to consider creating a compressed version of the files and directories to be copied in order to reduce the copying time.
Exclude the following directories when copying:
-
obj
-
int
-
The int directories within the system code source directories, such as hrsrc/int.
-
map
-
rptmap
-
backup
-
edi
Exclude the following files when copying:
-
The database configuration file, IBM
-
dictlock
-
plda.cfg
-
editdafile
-
$LAWDIR/fromPL/Admin/*.log
-
$LAWDIR/fromPL/Admin/appmetadiff.rpt
-
-
Load the "To" product line application metadata into the GEN metadata runtime repository. At the command line, type
perl $GENDIR/bin/appmetaload -a toPL
-
Set up the "To" product line database and database configuration file. This will overwrite any database configuration (that is, the editdafile and plda.cfg files) resulting from the copying of the existing product line.
At the command line, type
perl $GENDIR/bin/pldbsetup -f toPL
editda -c toPL $LAWDIR/toPL/editdafile
-
Build the dictionary for the "To" product line. At the command line, type
blddbdict toPL
-
Create the "To" product line database. At the command line, type
dbcreate toPL
-
Load the application data in CSV files. At the command line, type
perl $GENDIR/bin/apploadcsv -a toPL
-
Compile all the programs in the "To" product line. At the command line, type
perl $GENDIR/bin/patchcompile -a toPL
Check for compile errors and resolve them.
- Load application data into the new product line database. For instructions, refer to the Data Access guide for your database.
-
If you want to duplicate the security settings of the "From" product line, load the security dump files created from the "From" product lines. At the command line, type
lsload PROFILE dumpFileName -p profileID -d toPL -a toPL -addRoleMapping
-
Turn on security. At the command line, type
lsconfig -c password ON