How to Collect HNAS Diagnostics Using Command Line Interface CLI
Content

Objective

Collect the HNAS Diagnostics log if there is a problem collecting the logs via System Management Unit (SMU) Graphical User Interface (GUI).

Environment

  • Hitachi NAS Gateway Platform
    • Hitachi NAS Platform 5300 (HNAS 5300)
    • Hitachi NAS Platform 5200 (HNAS 5200)
    • Hitachi NAS Platform 4100 (HNAS 4100)
    • Hitachi NAS Platform 4080 (HNAS 4080)
    • Hitachi NAS Platform 4060 (HNAS 4060)
    • Hitachi NAS Platform 4040 (HNAS 4040)

Procedure

Collect Logs from  the vSMU

  1. Connect to the vSMU using an ssh PuTTY session.  
  2. Log in as manager; enter the current manager password. 
  3. Type q to go to the Linux prompt
  4. Type su; enter the current root password
  5. Type cd /opt/smu/mgr-scripts
  6. Type ./smu-getlogs -p /tmp/usb -n smu_logs_<date>.zip
  7. Type ls -l /tmp (verify the file is present)
  8. Transfer the file from the SMU using an SFTP application or SCP/WinSCP.

Collect logs from the Nodes using the SMU

  1. Connect to SMU using an ssh PuTTY session.  
  2. Log in using the manager credentials.
  3. At the Menu, type the number of the adminEVS for the Cluster to retrieve logs from.
  4. Once connected, type the following commands to collect logs from each Node:
    Note: The output file will be saved to the /home/manager directory of the SMU with a filename similar to NODE-1_diagnostics_2022-12-06_1749+0000.tgz.
    1. getdiagnostic --cnode 1
    2. getdiagnostic --cnode 2
    3. getdiagnostic --cnode x ("x" being the number of the other nodes in the Cluster).
  5. Type exit
  6. Type q
  7. Type ls-al /home/manager (verify the diagnostics are present)
  8. Transfer these files from the SMU using an SFTP application or SCP/WinSCP.

Collect Diagnostic logs from the Nodes using a Serial Connection

  1. Connect the Serial Cable to a Node
  2. Establish a Serial PuTTY session to a Node
  3. Login as manager; enter the current root password
  4. Type getdiagnostic
    The output file will be saved to the /var/opt/mercury-platform-config/home/manager directory of Node with a filename similar to NODE-1_diagnostics_2022-12-06_1749+0000.tgz.
  5. Type cd /var/opt/mercury-platform-config/home/manager.
  6. Type ls -l (verify the file is there)
  7. Transfer these files from Node using an SFTP application or SCP/WinSCP
  8. Perform the above commands to collect diagnostics on the other nodes in the Cluster.

Collecting Historical logs from Nodes to a USB Stick

  1. Collect the Historical Diagnostics from the Node (do this for each Node.)
    1. Connect the Serial Cable to a Node
    2. Establish a Serial PuTTY session to a Node
    3. Login as root; enter the current root password
    4. Type getdiagnostic.linux
      The output file will be saved to the /root directory with a filename similar to NODE-1_diagnostics_2022-12-06_1749+0000.tgz.
    5. Enter mkdir /tmp/usb
    6. Connect the USB drive to a USB port on the back of the Node.
      Note: Once connected, you may see the device name displayed on the screen.
    7. Enter tail -f /var/log/messages to determine the device number from the entries in the log.
    8. If the device found is sdc1
      1. Type mount /dev/sdc1 /tmp/usb
    9. Type pwd (confirm you are in the /root directory
    10. Type ls -l (note the filename similar to the above for today's date)
    11. Type cp <filename> /tmp/usb
    12. Unmount the USB: If the device found was sdc1
      1. Type umount /dev/sdc1pwd
    13. Remove the USB Stick from the Node
    14. Perform the above commands to collect diagnostics on the other nodes.

Collect Logs from a Physical SMU to a USB Stick

  1. Move the serial connection to the SMU
  2. Establish a Serial PuTTY session with the SMU
  3. Insert the USB flash drive into the SMU.
  4. Log into the SMU as root; enter the current root password
  5. Create a directory: Type mkdir /tmp/usb
  6. Mount the USB: Type mount /dev/sdb1 /tmp/usb
  7. Type cd /opt/smu/mgr-scripts
  8. Type ./smu-getlogs -p /tmp/usb -n smu_logs_<date>.zip
  9. Type ls -l /tmp/usb (verify the file is present)
  10. Unmount USB
    1. Type umount /dev/sdb1
  11. Remove the USB from the SMU

Unified NAS (VSP Gx00, Fx00, and Nx00 with NAS)

See How to Collect Node Diagnostics for Unified NAS Using the Maintenance CLI(Internal Article)

Attachments
CXone Metadata

Tags: howto hnas cli LogCollection

Page ID: 8358