Purpose
Directory listings, collected using the Druva inSync client and E-discovery client, are valuable for resolving data discrepancies, conducting audits, and verifying backup integrity. This article outlines how directory listings can be used for troubleshooting and provides the steps to generate them.
Uses of Directory Listings in Troubleshooting
Directory listings can assist with the following scenarios:
Troubleshooting Backup Issues:
Missing Files/Folders: Verify if specific files exist at the expected location if they are not being backed up.
Skipped Files: Determine if Druva inSync is intentionally skipping hidden/system files, unsupported file types, or paths specified for exclusion.
Permission Issues: Identify files or directories that the inSync client cannot access due to insufficient permissions.
Backup Size Verification:
Pre-Backup Estimation: Estimate the amount of data to be backed up using a directory listing.
Unexpected Backup Size: Compare actual file content (from directory listings) with backup logs when a backup is smaller or larger than expected.
Policy Compliance Checks:
Confirm that folders are correctly included or excluded according to defined backup policies.
Audit whether users are storing data in designated and allowed directories.
Detecting File Changes:
Change Tracking: Track additions, modifications, or deletions of files by comparing directory listings from different time periods.
Aid in data loss investigations.
Exclusion Rule Verification:
Confirm that file types or directories intended to be excluded (based on Backup policies) are present but intentionally skipped.
Client Configuration Validation:
Identify incorrect backup paths in client configuration, such as when the wrong path is specified.
Help resolve queries related to "Misconfigured Backup folder" alerts.
Audit & Documentation:
Provide evidence of stored and protected data as required by organizational policies.
Serve as a record of the file structure at a specific point in time.
Methods
Command Line (Linux/macOS)
Open the terminal.
Navigate to the desired directory using the `cd` command.
Execute the following command: `ls -al > directory_listing.txt`
This command lists all files and directories in long format (`-al`) and redirects the output to a file named `directory_listing.txt`.
Windows Command Prompt
Open the command prompt.
Navigate to the desired directory using the `cd` command.
Execute the following command: `dir /a > directory_listing.txt`
This command lists all files and directories (`/a`) and redirects the output to a file named `directory_listing.txt`.
PowerShell (Windows)
Open PowerShell.
Navigate to the desired directory using the `cd` command.
Execute the following command: `Get-ChildItem | Out-File -FilePath directory_listing.txt`
This command retrieves all items (`Get-ChildItem`) and outputs them to a file named `directory_listing.txt`.
Output File
The output file `directory_listing.txt` will contain the detailed listing of the directory, including:
Detail | Description |
File Names | Names of all files and directories within the specified directory. |
Permissions | Access permissions for each file and directory. |
Size | Size of each file. |
Last Modified | Date and time of last modification. |
Owner/Group | Owner and group associated with each file. |
Directory Flag | Indicator if the item is a directory or a file. |
Other Attributes | Additional attributes depending on the operating system. |
Considerations
Ensure appropriate permissions to access and list the directory.
The output file will be created in the current working directory.
Modify the output filename as needed.
Conclusion
Directory listings are a crucial tool for troubleshooting, auditing, and validating Druva inSync backups. By understanding how to generate and interpret these listings, administrators can more effectively manage and maintain their backup environment.