Collecting NFS client debug data

Use the NFS client debug script to collect diagnostic data when you encounter any issues that are related to an NFS export access.

Make sure that the following requirements are met to collect the debug data:
  • Python 3.6 or later is installed.
  • The tcpdump is available.
  • You have root privileges on the client system.
  • Sufficient free disk space is available in the /tmp directory.
  • You have access to an IBM Storage Scale protocol node.

Use this procedure when NFS clients experience issues such as mount failures, unresponsive mounts, access errors, or performance problems. The debug script automates the collection of system statistics, network traces, RPC logs, and file system information based on the selected scenario.

  1. Copy the debug script from an IBM Storage Scale node to the affected NFS client.

    The NFS client debug script is available on IBM Storage Scale protocol nodes in the /usr/lpp/mmfs/samples/nfs/nfs_client_debug_script.py directory.

    scp /usr/lpp/mmfs/samples/nfs/nfs_client_debug_script.py <client_host>:/tmp/
  2. Log in to the NFS client system and go to the script location.
  3. Run the script with the appropriate troubleshooting scenario.
    The debug script supports the following command format:
    nfs_client_debug_script.py –scenario
    {trace_mount_error,trace_mount_hang,access_denied_error,trace_perf_issue}
    [--server_ip SERVER_IP]
    [--nfs_share_path NFS_SHARE_PATH]
    [--local_mount_path LOCAL_MOUNT_PATH]
    [--log_directory LOG_DIRECTORY]
    [--nfs_version NFS_VERSION]
    [--username USERNAME]
    [--test_directory TEST_DIRECTORY]
    [--debug]
    Example:
    ./nfs_client_debug_script.py --scenario trace_mount_error \
    --server_ip <server_ip> \
    --nfs_share_path <nfs_export_path> \
    --local_mount_path <mount_point> \
    --nfs_version 4
    A sample output is as follows:
    [2026-02-11 06:57:54]: Starting NFS client debug data collection
    [2026-02-11 06:57:54]: Scenario: trace_mount_error
    [2026-02-11 06:57:54]: Starting tcpdump trace
    [2026-02-11 06:58:00]: Running test scenario
    [2026-02-11 06:58:00]: Running mount test
    [2026-02-11 06:58:01]: Completed test scenario
    [2026-02-11 06:58:06]: Stopping tcpdump trace
    [2026-02-11 06:58:07]: Archive created successfully:
    /tmp/nfs_logs/nfs_debug_logs_20260211_065806.tar.gz
    [2026-02-11 06:58:07]: Final archive location:
    /tmp/nfs_logs/nfs_debug_logs_20260211_065806.tar.gz
    [2026-02-11 06:58:07]: NFS client debug data collection completed
  4. Reproduce the issue while the script is collecting data.
  5. Wait for the script to complete and create the diagnostic archive.
  6. Locate the generated archived-file.

    The logs are saved in the /tmp/nfs_logs/ file.

A compressed archived file that contains diagnostic logs is created. The archived file includes network traces, RPC debug logs, and system statistics that help identify the root cause of the issue.

Share the generated archived-file with your support team or use the archived for further analysis.