8.4 Enabling Debug Mode and Core Dumps

If the log files are not generating enough information to identify the cause of a problem, you can run the Access Gateway Service in debug mode. You should not be running in debug mode except when you are trying to isolate a problem because of the following side effects:

  • Debug mode causes the size of the log files to grow quickly. They can grow large enough to consume all available disk space and crash the system. When running in debug mode, you need to carefully monitor available disk space and the size of the log files.

  • Debug mode opens additional ports. Anyone who has local access to the Access Gateway machine can see the information displayed in the following local URLs:

    http://127.0.0.1:8181/server-status 
    http://127.0.0.1:8181/server-info
    
  • Debug mode causes load and response times to slow.

Debug mode enables core dumps, X-Mag headers in LAN traces, and increases log levels by enabling advanced option in the Access Gateway configuration. For example LogLevel debug. This will set apache log level to debug in the error_log file.

You can generate core dumps in the following two ways:

  1. Start /etc/init.d/novell-apache2 in debug mode. When there is a crash, core file will be created as /var/cache/novell-apache2/core.

  2. Without starting novell-apache2 in debug mode, perform the following:

    1. Set ulimit -c unlimited in /etc/init.d/novell-apache2 startup script.

    2. You can create the core directory under /tmp. Choose the file path based on the availability of disk space. Give the following command to create a directory in the Access Gateway component:

      # mkdir -p /tmp/apache2-gdb-dump

    3. Set permission as follows:

      # chown novlwww:www /tmp/apache2-gdb-dump

      # chmod 0777 /tmp/apache2-gdb-dump

    4. Add the following advanced option in the Access Gateway configuration as follows:

      CoreDumpDirectory /tmp/apache2-gdb-dump

    5. Apply changes to the Access Gateway.

Whenever there is a crash, core file will be created as/tmp/apache2-gdb-dump/core.

For some crashes, the /tmp/debug000.log file is created. For more information about the log, see TID 7011804.

This section describes the following tasks:

8.4.1 Starting Apache in Debug Mode

Use the following commands to start debug mode:

Linux: /etc/init.d/novell-apache2 stop OR rcnovell-apache2 stop

/etc/init.d/novell-apache2 start debug OR rcnovell-apache2 start debug

Windows: Use the following steps to enable debug mode:

  1. Create a tmp directory at the root of C:

  2. Stop Apache:

    1. Click Control Panel > Administrative Tools > Services.

    2. Right-click the Apache 2.2 service, then select Stop.

  3. Start Apache:

    1. Right-click the service, then click Properties.

    2. In the Start parameters box, specify

      -D allowServerDebug

    3. Click Start.

8.4.2 Examining the Debug Information

  1. Examine the Apache error log file or copy it so you can send it to NetIQ Technical Support:

    Linux: /var/log/novell-apache2

    Windows: \Program Files\Novell\apache\logs

  2. View the information at the local URLs or copy the pages to send to NetIQ Support:

    • http://127.0.0.1:8181/server-status

      This page displays debug information about caching, SSL, workers, and proxy information.

    • http://127.0.0.1:8181/server-info

      This page displays module and configuration information.

  3. If a crash occurred, examine the core dump file or copy it so you can send it to NetIQ Technical Support.

    Linux: /var/cache/novell-apache2

    Windows: C:\tmp directory that you created

8.4.3 Disabling Debug Mode

Use the following commands to disable debug mode:

Linux: /etc/init.d/novell-apache2 stop OR rcnovell-apache2 stop

/etc/init.d/novell-apache2 start nodebug OR rcnovell-apache2 start nodebug

Windows: Use the following steps to disable debug mode:

  1. Click Control Panel > Administrative Tools > Services.

  2. Right-click the Apache 2.2 service, then select Stop.

  3. Right-click the service, then click Properties.

  4. In the Start parameters box, remove

    -D allowServerDebug

  5. Click Start.