Start here

Home
About Klocwork
What's new
Fixed issues
Release notes
Installation

Reference

C/C++ checkers
Java checkers
C# checkers
MISRA C 2004 checkers
MISRA C++ 2008 checkers
MISRA C 2012 checkers
MISRA C 2012 checkers with Amendment 1
Commands
Metrics
Troubleshooting
Reference

Product components

C/C++ Integration build analysis
Java Integration build analysis
Desktop analysis
Refactoring
Klocwork Static Code Analysis
Klocwork Code Review
Structure101
Tuning
Custom checkers

Coding environments

Visual Studio
Eclipse for C/C++
Eclipse for Java
IntelliJ IDEA
Other

Administration

Project configuration
Build configuration
Administration
Analysis performance
Server performance
Security/permissions
Licensing
Klocwork Static Code Analysis Web API
Klocwork Code Review Web API

Community

View help online
Visit RogueWave.com
Klocwork Support
Rogue Wave Videos

Legal

Legal information

Installing the Klocwork Server package on Unix -- Upgrade only

Installing the Klocwork Server package on Unix -- Upgrade only

This page provides instructions for installing the Server package if you are upgrading.

Important: This is not the starting point for upgrading. Make sure you start with Upgrading from a previous version.

Before you begin

Where do I get the software?

Download the packages from Klocwork Support. Typically, only one or two users in an organization have access to Klocwork Developer Network. If you don't have access, you can register for a new account.

Installation notes

  • Linux only: There are separate installation packages for 32-bit and 64-bit Java. Make sure you select the one that matches your operating system.
  • ulimit —n must be 2048 in order to run the Klocwork Server.
  • Ensure that the downloaded .sh file is executable. Use the chmod command to set the appropriate permissions:chmod 755 <kw-installer.sh>
  • To control permissions when you are installing Klocwork, change the value of umask.
  • Install Klocwork software as a non-root user.
  • Ensure that the path in which you install the product is the same path from which users invoke the product. For example, the local path to the installation might be /local/tools/klocwork, but users on other machines have to use the NFS path /opt/tools/klocwork to invoke the product. Therefore, to ensure that users can invoke the product, use the /opt/tools/klocwork path during installation.
  • Due to issues with file locking, user home directories should not be located on NFS. See Failed to lock file or directory: No locks available.
  • The Klocwork Server and Database Server need to be running on the same machine.
Note: Due to MySQL limitations, the projects_root directory should not be located on NFS. It has a special file locking implementation which is not fully supported by MySQL. See also the warning in the MySQL documentation.

Run the installation package

Run the following command:

kw-server-installer-18.1.x.x.<platform>.sh -p <projects_root> [options] <install_directory> [component ...]

where

  • <platform> is solaris, linux, or aix
  • <projects_root> is the location of the old projects_root directory that you want to migrate
  • [<options>] are any of the options listed in Command-line options for the Server package
    Note: You do not need to set host names and port numbers for the Klocwork Servers during installation. This information will be picked up from your old projects_root directory when it is migrated.
  • <install_directory> specifies the directory in which you want to install Klocwork. Do not specify a subdirectory of the projects_root directory. Note that if the chosen directory is not empty, you will not be able to continue with the installation.
  • [<component ...>] is any of the arguments from Arguments for Server components. Separate multiple components with spaces. If you do not specify one or more components, the entire package will be installed. You can also see a list of arguments for the various components with the --list option. Note that an asterisk in the returned output means the component is already installed.

Example

kw-server-installer-18.1.0.0.linux.sh -p /space/old_projects_root /opt/klocwork

Command-line options for the Server package

Name Short name Description
--agree -a Agree to license terms and do not display license agreement.
--database-port <port_number>   Specify the port number that you will use to run the Database Server. Default: 3306. This option is equivalent to specifying the port number with kwservice.
--debug   Print debug information
--force -f Install without integrity checks
--help -h Display this help and exit
--klocwork-port <port_number>   Specify the port number that you will use to run the Klocwork Server. Default: 8080. This option is equivalent to specifying the port number with kwservice.
--license-port <port_number>   Specify that the License Server will be run locally, but on a non-default port. Default: 27000. This option is equivalent to specifying the port number with kwservice .
--license-server <host>[:<port>]   Specify a remote License Server host. The host argument is required; the port argument is optional. Default: localhost:27000. This option is equivalent to specifying the host and port with kwservice. See also Using your organization's FlexNet Publisher serverUsing your organization's FlexNet Publisher server.
--list -l List available features (components)
--projects-root <directory> -p Specify the complete path to a non-default projects_root directory. Default: <install_directory>/projects_root. The directory you specify must meet one of the following conditions:
  • it does not yet exist
  • it is empty
  • it is a valid projects_root directory created previously Do not specify the same directory as the root Klocwork installation directory you have specified. Do not install Klocwork in a subdirectory of the projects_root directory.
IMPORTANT: If you are upgrading, specify the old projects_root directory that you want to migrate.
--version -v display the version of Klocwork software and exit

Arguments for Server components

To install this Server component (feature)... ...enter the argument...
License Server LicenseServer
Klocwork Server KlocworkServer
Administration and analysis management tools BuildTools

Add Klocwork to your PATH

On Unix, we recommend adding <klocwork_install>/bin to your PATH. Otherwise, you need to execute commands from <klocwork_install>/bin.