Using the Lawson Installer and GlobalPerms Viewer from the Command Line

The installer program can be run in the following modes:

  • GUI mode

  • Command line mode, either interactive or unattended (service packs and patches only)

  • GlobalPerms Viewer mode, which allows you to view the contents of the GlobalPerms file and determine what patches or service packs have been installed on the system.

Java Installer Command Line Usage

java -jar XXX.jar -[c|d|g|h|i|r|x] [-a PathToAnswersFile] [-j Package.jar] [-p PackageName] InstanceName

where

XXX is the filename of the installation package

package.jar is the name of the installation .jar file

PathToAnswersFile is the path to the answers file that contains answers to the prompts.

InstanceName is the name of the instance to patch.

  • If you are installing an application server patch, use the Environment name

  • If you are installing a web server patch, use the web server instance name

Parameters are described below.

Installation Options

Parameter Definition
-a PathToAnswersFile

Can be used in command line or GUI mode. This mode requires an answers file pre-populated with values required by the installation in the format property=value, for example:

GENDIR=/lsfprod1/gen
LAWDIR=/lsfprod1/law
LADBDIR=/lsfprod1/db

When you run the install, values will be automatically filled in for the appropriate question. They may be left as is or changed.

This flag is not valid on a patch or update install, because the installation program reads install.cfg to get the answers it needs.

-b PatchDirectory

Use only when installing patches.

Evaluates all patch files in the PatchDirectory to determine whether they are suitable for installation. Installs suitable patches in batch mode.

InstanceName and -p PackageName are optional

Use with -c, -i, and -d

-c

Interactive command line mode. The installation program goes through the interview. When the interview is complete, displays an installation/summary confirmation screen. Requires InstanceName.

When installing patches, -c displays an installation summary/confirmation screen that requires you to confirm the installation. This flag is optional

-d Detail. Outputs detailed information about installation progress in the command window. This is the same output you would see in GUI mode if you clicked the Detail button. This flag is optional. Use with -c, -i, or -x.
-g Calls the GlobalPerms Viewer. Requires InstanceName. Arguments between -g and InstanceName are passed to GPViewer. For more information on the GPViewer, see GlobalPerms Viewer Options.
-i

Run in batch (unattended) mode. Do not use with -c. Supported for service pack and patch installations only. Requires InstanceName

Note: Lawson does not support running the initial installation of Infor Lawson System Foundation in unattended batch mode.
-j Package.jar Specify an additional product .jar file to install. Can be used in GUI or command line mode.
-l Lists the contents of the .jar file. Overrides other switches except -h.
-p PackageName

Valid package names for Infor Lawson System Foundation are:

LSFCT (Infor Lawson Core Technology)

PORTAL (Lawson Portal application server component)

PORTALWEB (Lawson Portal web server component

ECA (Application Developer Workbench)

-r

Redelivers files. Use -r in the following circumstances:

  • You have corrupted a patch file, and need to replace it.

  • Your installation failed during file delivery. Correct any issues, and run the installer again using the -r switch. The install will run to completion.

-x Filename.jarInstanceName

Delete/remove/uninstall the specified package or an individual patch from the Environment InstanceName. The following conditions must be met before you can use this option.

  • The product or patch must have previously been installed on the system.

  • A higher service pack has not been installed.

  • The backup directories must be in place and defined in the BACKUPDIR value in the %LAWDIR%\system\install.cfg file.

Use with -c or -i. When used with -i, the installation program will not display a confirmation prompt before deleting.

-h Help. Prints usage. This flag will override any other switches unless it comes before -g.
-u Unsecured. This flag will not use encryption in configuration files.

Examples: Using the Installer in Command Line Mode

Example command Result
java -jar LSFCT.jar -a c:\install\answers.txt Runs the installation program in GUI mode with answers pre-populated per the answers file.
java -jar LSFCT.jar -a c:\install\answers.txt env1 Installs the LSFCT.jar file to the Environment named env1 in interactive command line mode with answers pre-populated per the answers file.

java -jar LSFCT_WIN2012_10000900P43358.zip -i env1

Installs Lawson Core Technology patch to the Environment named env1. This patch will install without user intervention.

java -jar LSFCT_WIN2012_10000900P43358.zip -c lsfprod1

Installs Environment patch to the Environment named lsfprod1. The following summary screen will appear, asking you to confirm before the installation begins.

Installation summary: Update Environment Technology for Environment lsfprod1

The following actions will be done

Update 4GL tools

The following directories are affected

LADBDIR=\lsfprod1\DB (1 files / 249832 bytes)

GENDIR=\lsfprod1\gen (5 files / 2764665 bytes)

Installer files

Log file is \lsfprod1\law\system\install.log

Configuration is \lsfprod1\law\system\install.cfg

Product registry is \lsfprod1\law\system\GlobalPerms

Backups written to \lsfprod1\law\system\backup

Do you wish to continue?

1: Exit

2: Install

Select number [Install] : 2

java -jar LSFCT_WIN2012_10000900P43358.zip -cx lsfprod1

Removes patch from the Environment named lsfprod1 in interactive command line mode.

GlobalPerms Viewer Options

The GlobalPerms Viewer (GP Viewer) is a utility included with the installer in every product .jar file. This utility reports on the contents of GlobalPerms, which is the repository of file and version information created and used by the installer. This is useful for determining what has been installed on the system.

GlobalPerms Viewer Usage

You can use the GlobalPerms Viewer (GP Viewer) with Product .jar file to list installed components, installation history, and PTs delivered in a package, plus information on specific files delivered by the product installation .jar file.

java -jar Product.jar -g [c|i|h|l|p|f Filename |v Filename] InstanceName

where

Product.jar is the name of the file used to install or update the product.

instanceName is the name of the instance the product was installed to. For application server products, this is the Environment name. For web server-side installs, this is the web server instance name.

You can use the GP Viewer with the %GENDIR%\install\installer.jar file. This is useful if you do not have the original product installation .jar file.

java -cp %GENDIR%\install\installer.jar com.lawson.install.GPViewer [c|i|h|l|p|f Filename |v Filename] %LAWDIR%\System\GlobalPerms

where

Filename is the full path to a file you want to view information on.

Note: For web server installs, GlobalPerms is located in the web server instance directory.

GlobalPerms is the full path to the GlobalPerms file. GlobalPerms is always located in the %LAWDIR%\system directory for application server-side installs, and in the web server instance directory for web server-side installs.

  • Only one switch at a time is valid.

  • If no switches are passed to GPViewer, -p is the default.

  • if using java -jar product.jar -g switches instanceName , the -g is a switch to the installer (product.jar) and anything between -g and instanceName are switches to GPViewer.

Parameter Definition
-c Lists components per package installed.
-f Filename Lists information about the specified file.
-h Help. Prints this usage.
-i Lists installation history
-l Lists installation history for each package.
-p Lists PTs for each package installed. This is the default if no other switches are used.
-v Filename Lists version information about the specified file.

Examples: Using the GlobalPerms Viewer

Example command Result

java -jar LSFCT_WIN2012_10000900P43358.jar -gl lsfprod11

Returns a list of all files delivered with this patch, including version information.
java -jar portal.jar -g lsfprod1 Returns the contents of GlobalPerms in the Environment env1 for files delivered by the Lawson Portal installation.
java -jar installer.jar com.lawson.install GPViewer -fv %GENDIR%\bin\lapm %LAWDIR%\system\GlobalPerms Returns the version and InstallID stored in GlobalPerms for the specified file.

java -jar LSFCT_WIN2012_10000900P43358 -f %GENDIR%\java\jar\ios.jar lsfprod2

Lists information about the ios.jar delivered with this patch.