Avamar: How to run "getlogs" to gather Avamar server logs

Summary: This article provides information about the getlogs utility, used to gather Avamar server logs.

This article applies to This article does not apply to This article is not tied to any specific product. Not all product versions are identified in this article.

Instructions

What is getlogs?

getlogs is utility that is run on the Avamar Utility Node. 

The utility gathers extensive logs from all nodes and stores them in a tar file.
(The tar file is created and stored in the directory that the getlogs script is run from.)

The "--server" flag can be used to specify how many days of logs to collect. If this flag is not used, then everything since the last restart is captured (which can result in a large tar file)

Note: using the "--server" flag, ensure that it covers the timeframe of the incident that logs are being collected for. Adding an extra day or two ensures that enough data is captured, and does not add a significant amount of size to the log file.

For example, if a node went offline yesterday, use "--server=2" or "--server=3" to ensure that sufficient information is collected.
 
 
What does getlogs do when run?
  • The "getnodelogs" script is copied to every node and run
  • The getnodelogs script bundles all the logs collected into a file called "nodelogs.tgz" on each node
  • It then gathers all the "nodelogs.tgz" files and adds them into one logs.xxxx.tar file
  • The "logs.xxxx.tar" file is the file to collect
    • It is important to understand the distinction between getlogs vs getnodelogs, and nodelogs.tgz vs logs.xxxx.tar. Grabbing nodelogs.tgz from a single node is not sufficient, and the logs.xxxx.tar file should ALWAYS be collected
    • Depending on the file size, it should either be attached to the Service Request (SR) or uploaded to the MFT site (this information will be provided by your Avamar support engineer if required)
Note: If a grid is being rolled back, getlogs must be run BEFORE the rollback. Once the rollback is performed, the current logs are erased.
 
 

Procedure

1. Log in to the grid as admin and load the ssh keys. See Avamar: How to Log in to an Avamar Server and Load Various Keys for information about loading keys.

2. From Avamar version 18.1, getlogs must be run as root (but not run from the root home directory).

a. Switch to root: 

su -

Enter the root password when prompted.

b. Load the root keys: 

ssh-agent bash
ssh-add .ssh/rootid
 

Sample output: 

Identity added: .ssh/rootid (.ssh/rootid)
 

c. It is important to change to the /home/admin directory:

cd /home/admin
Warning: This step is important as running the utility in the root home directory can cause capacity issues.
 
 

3. Run the getlogs command:

getlogs --server=x

Where "x" is the number of days of logs to gather. (The "getlogs" command can be run without "--server=" and gathers all server logs)

Sample output:

Copying getnodelogs script to nodes
Running getnodelogs script on nodes
Getting nodelogs.tgz from nodes
Creating tar file: logs.130218.120930.tar
Done with getlogs
 

4. The file is created in the format "logs.ddmmss.hhmmss.tar". Verify that the tar file mentioned above exists in the directory the command was run in:

ls -lh logs.130218.120930.tar
 

Sample output:

-rw-rw-r-- 1 admin admin 324M Feb 13 12:10 logs.130213.120930.tar

(This also indicates how big the file is.)

 

Notes

  • During the rollback process, getlogs is run automatically as a precaution
  • If getlogs was not run manually before rolling back the grid, the copy captured during the rollback can be found in /usr/local/avamar/var/log/rollback
    • Check the timestamp on the tar files to verify that the correct log.xxxx.tar file is being collected:
ls -ltrh /usr/local/avamar/var/log/rollback/
 
Sample output: 
total 54G
-rw-rw-r--  1 admin admin  18G Feb 17 11:01 logs.140217.102740.tar
-rw-rw-r--  1 admin admin  19G Feb 19 12:57 logs.140219.122325.tar
-rw-rw-r--  1 admin admin  18G Feb 21 12:34 logs.140217.184444.tar

(On a production grid, these logs can be large (2GB+)  

  •  Once the .tar file has been created, it must be provided to Avamar support personnel for troubleshooting purpose
    • If the size of the file is less than 2 GB, it can be directly attached to the Service Request
    • If the size of the file is bigger than 2 GB (likely), contact the Avamar support personnel to assist uploading the file to an MFT site.

Additional Information

Logs transfer to FTP general best practices:
  • Generally, it is necessary to have a conversation between the Avamar Support Engineer and the Customer about the environment, especially if the FTP process starts to get difficult or time consuming
  • The Customer might be able to give instructions on the best way to push files out of their environment and could save a lot of time and effort in the process
    • For example, the environment might have FTP access blocked on the affected grid but have access from another grid that could be used to get the files uploaded to the MFT server 
  • Depending on the situation, it might also be best to use an alternative and temporary MFT link provided by Avamar support personnel
 

See this video:

Affected Products

Avamar

Products

Avamar, Avamar Server
Article Properties
Article Number: 000022859
Article Type: How To
Last Modified: 25 Sep 2025
Version:  17
Find answers to your questions from other Dell users
Support Services
Check if your device is covered by Support Services.