You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/operator-nexus/howto-kubernetes-cluster-log-collector-script.md
+9-11Lines changed: 9 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -21,13 +21,13 @@ Furthermore, the script does network connectivity tests by pinging the default g
21
21
22
22
## Prerequisite
23
23
24
-
Before proceeding, ensure that you have [access to the Nexus Kubernetes cluster node](./howto-kubernetes-cluster-connect.md#azure-arc-for-servers).
24
+
Before proceeding, ensure that you have [SSH access to the Nexus Kubernetes cluster node](./howto-kubernetes-cluster-connect.md#azure-arc-for-servers).
25
25
26
26
27
-
## Execution Steps
27
+
## Execution steps
28
28
29
-
-Navigate to any working directory.
30
-
- Run the log collector script `sudo /opt/log-collector/collect.sh`.
29
+
-Connect to the Nexus Kubernetes cluster node using SSH.
30
+
- Run the log collector script by executing the command `sudo /opt/log-collector/collect.sh`.
31
31
32
32
Upon execution, you observe an output similar to:
33
33
@@ -44,16 +44,14 @@ Trying to collect SELinux status...
44
44
Trying to archive gathered information...
45
45
Finishing up...
46
46
47
-
Done... your bundled logs are located in /var/log/node_name_date_time_2024-03-11_1942-UTC.tar.gz
47
+
Done... your bundled logs are located in /var/log/<node_name_date_time-UTC>.tar.gz
48
48
```
49
49
50
-
## How to Download the Log File
51
-
Once the tar file is generated, exit your cluster and use the following command to download the generated log file from your cluster to local machine.
50
+
## How to download the log file
52
51
53
-
> [!NOTE]
54
-
> The following command will work only on Linux
52
+
Once the log file is generated, you can download the generated log file from your cluster node to your local machine using various methods, including SCP, SFTP or Azure CLI. However, it is important to note that SCP or SFTP are only possible if you have direct IP reachability to the cluster node. If you do not have direct IP reachability, you can use Azure CLI to download the log file.
55
53
56
-
This command is familiar—it’s the same one you’ve used before to access the Nexus Kubernetes cluster node. Now, all you need to do is run it again to copy files from the node to your local machine, just by adding the cat command at the end.
54
+
This command should look familiar to you, as it is the same command used to SSH into the Nexus Kubernetes cluster node. To download the generated log file from the node to your local machine, simply use this command again, with the addition of the `cat` command at the end to copy the file.
57
55
58
56
```azurecli
59
57
az ssh arc --subscription $SUBSCRIPTION_ID \
@@ -64,7 +62,7 @@ az ssh arc --subscription $SUBSCRIPTION_ID \
In the preceding command, replace `node_name_date_time-UTC.tar.gz` with the name of the log file created in your cluster, and `<Local machine path>` with the location on your local machine where you want to save the file.
65
+
In the preceding command, replace `node_name_date_time-UTC.tar.gz` with the name of the log file created in your cluster node, and `<Local machine path>` with the location on your local machine where you want to save the file.
0 commit comments