Collect all logs
This article explains how to collect all logs and information for a support case in a single operation.
In some scenarios you may have to provide all the available logs and system information from your Exasol solution to enable the Support team to troubleshoot and resolve your issue. You can collect all this information using a single command
To learn more about how to use EXAsupport, see EXAsupport.
Prerequisites
You must have enough free disk space for the logs. For more information, see Check free disk space.
Procedure
This procedure uses the c4 and confd_client command-line tools in a Linux terminal. To learn more about these tools, see Exasol Deployment Tool (c4) and ConfD.
-
You will need the play ID of the deployment in the following steps. To find out the play ID, use
c4 ps.Example:
Copy./c4 ps
N PLAY_ID NODE MEDIUM INSTANCE DB_VERSION EXTERNAL_IP INTERNAL_IP STAGE STATE UPTIME TTL
┌─ 1 c3275f84 10 awscf c5d.large 8.27.0 203.0.113.10 10.0.0.10 c running 00:23:07 +∞
│ 1 c3275f84 11 awscf c5d.2xlarge 8.27.0 203.0.113.11 10.0.0.11 d running 00:23:05 +∞
│ 1 c3275f84 12 awscf c5d.2xlarge 8.27.0 203.0.113.12 10.0.0.12 d running 00:23:06 +∞
│ 1 c3275f84 13 awscf c5d.2xlarge 8.27.0 203.0.113.13 10.0.0.13 d running 00:23:06 +∞
└─ 1 c3275f84 14 awscf c5d.2xlarge 8.27.0 203.0.113.14 10.0.0.14 d running 00:23:06 +∞ -
Connect to the cluster operating system (COS) using
c4 connect -i PLAY_ID -s cos.Example:
Copy./c4 connect -i c3275f84 -s cosTo find the play ID, you can use
c4 ps.For more information about how to use c4 commands, see How to use c4.
-
To find the database name when you are connected to COS, use the ConfD job db_list.
Example:
Copyconfd_client db_list
- MY_DATABASE -
Use
exasupportwith the following options to collect all logs, backtraces, and other information from the database.Specify a start date (
-s) and end date (-t) using the formatYYYY-MM-DD.Specify the database name with the option
-e. If the database name is omitted, logs are collected from all databases.Example:
Copyexasupport -d 0 -x 1 -b 1,2,3,4 -s 2022-08-11 -t 2022-08-11 -e MY_DATABASEIf a file was successfully created, EXAsupport returns a success message with the file name.
Example:
CopySuccessfully stored debug information into file /exa/tmp/support/exacluster_debuginfo_2022_08_11-23_27_20.tar.gz - Use Control+D or type
exitto disconnect from COS. -
Copy the file to your local computer by connecting to COS and using the
catcommand:Copy./c4 connect -t <DEPLOYMENT>.<NODE>/cos -- "cat /exa/tmp/support/$FILENAME" > $FILENAMEExample:
Copy./c4 connect -t 1.11/cos -- "cat /exa/tmp/support/my_log" > my_log
Verification
To verify that the file was successfully copied, use the ls command in the target folder on your local machine.
Example:
ls -lahtr ~/mylogs | grep exacluster_debuginfo
-rwxr-xr-x 1 user group 9.8K Sep 20 17:38 exacluster_debuginfo_2022_08_11-23_27_20.tar.gz
System logs
In many cases the system logs for a specific node will also be required for troubleshooting. To collect system logs for a node, connect to the node over SSH and use sudo journalctl [filter]. If Exasol is installed with a non-root user, omit sudo.
For example, to retrieve system logs for the last 7 days and save the output to a file:
sudo journalctl --since "7 days ago" > node11_journalctllog.txt