Troubleshooting


Instance setup

Simple diagnosis tool

Since version 0.4.18, our agent provides a command line tool to check most common setup issues. This tool works with Linux, but does not work on Windows. Run it with the following command:

java -jar sqreen.jar <command>

Where <command> is :

Command Description
version show agent version
status display status for all running JVMs
status <pid> display status for JVM whose PID is <pid>
log-archive create an archive of all running Sqreen agents logs
debug-log-archive <d> same as log-archive plus toggles log_level=DEBUG log for <d> seconds

JVM parameters

Make sure you are passing the -javaagent parameter to the JVM before the -jar parameter.

One way to do this is to look at the parameters provided to the Java process:

ps -ef | grep java

The resulting line should include the -javaagent: parameter with the path to the Sqreen agent JAR. If not, the application startup file is incorrrect.

Adding or changing this parameter requires restarting the JVM to take effect.

Sqreen agent log

By default, Sqreen agent logs to /tmp/sqreen.log.

The agent should create a log file when it starts. If not:

  • Check the configured log location, see configuration.
  • Check that the JVM process has the proper rights to write to it.

You can change the log_level parameter set by default to INFO for more details.

Provide an agent log with log_level=DEBUG when contacting us for support to help us troubleshoot.

-Dsqreen.log_level='DEBUG' -Dsqreen.log_location=/tmp/sqreen.log

Application server logs

When using an application server, check its logs:

  • Look for any unexpected error during startup or while executing requests.
  • Some errors report JVM arguments, and include the -javaagent parameter

Agent unable to communicate with Sqreen

Some application containers like Websphere require advanced configuration to be able to communicate with our servers.

If you see error messages about SSL/TLS and encryption in agent logs, this is the most probable cause.

Refer to advanced configuration for details.

No monitored HTTP requests on Sqreen

Check application traffic

Since Sqreen passively monitors your application, you need to have some traffic on your application.

Sqreen does not show anything under the 'DB requests' field

  • Is your database supported?
  • Is there a data protection plugin enabled?

Contact support if you answered 'yes' to any of the above questions.

Multiple agents

If you use an APM or any other agent on the JVM, make sure the Sqreen agent is the last in the command line.

Ordering matters here because otherwise both agents might misbehave.

Contacting support

When contacting support, please provide the following items for faster diagnosis:

  • Type and version of application server (if any)
  • Type and version of database server (if any)
  • Sqreen agent log with log_level=DEBUG (see Simple diagnosis tool above)
  • List of your application dependencies from your pom.xml, build.gradle or build.xml
  • Output of command java -jar sqreen.jar status