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

Database connection error

Important: 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.

If you see the following error:

Error occurred while connecting to database: Database connection to <database> refused: Communications link failure due to underlying exception

Check the host name in the error message. If the host name is not a fully qualified host name that includes the domain (for example, server1.klocwork.com), you need to set the fully qualified domain name for the Database Server.

To do this:

  1. Stop the Database Server:
    kwservice --projects-root <projects_root> stop database 
    
  2. Run the following command:
    kwservice --projects-root <projects_root> set-service-property database host <fully-qualified-host-name> 
    
    For example:
    kwservice --projects-root C:\Klocwork\projects_root set-service-property database host server1.klocwork.com 
    
  3. Start the Database Server:
    kwservice --projects-root <projects_root> start database