Challenge - 5 Problems
Audit Logging Mastery
Get all challenges correct to earn this badge!
Test your skills under time pressure!
💻 Command Output
intermediate1:30remaining
Audit log file content after enabling HDFS audit logging
You enabled audit logging in HDFS by setting
dfs.namenode.audit.log.enabled=true in hdfs-site.xml. After restarting the NameNode, you perform a file read operation. What will you find in the audit log file?Attempts:
2 left
💡 Hint
Audit logs record detailed info about each operation including user and action.
✗ Incorrect
When audit logging is enabled in HDFS, each file system operation like READ or WRITE is logged with details such as user, operation type, file path, and timestamp in the audit log file.
❓ Configuration
intermediate1:30remaining
Configuring audit logging in Hadoop's hdfs-site.xml
Which configuration snippet correctly enables audit logging for the NameNode in Hadoop?
Attempts:
2 left
💡 Hint
The correct property name is specific and must be exact.
✗ Incorrect
The correct property to enable audit logging on the NameNode is
dfs.namenode.audit.log.enabled set to true. Other options are incorrect property names or values.❓ Troubleshoot
advanced2:00remaining
Why are no audit logs generated despite enabling audit logging?
You set
dfs.namenode.audit.log.enabled=true and restarted the NameNode, but no audit logs appear in the expected directory. What is the most likely cause?Attempts:
2 left
💡 Hint
Check file system permissions for the log directory.
✗ Incorrect
If the NameNode process user lacks write permission to the audit log directory, logs cannot be created even if audit logging is enabled.
✅ Best Practice
advanced1:30remaining
Best practice for managing audit log file size in Hadoop
What is the recommended way to manage audit log file size to prevent disk space issues?
Attempts:
2 left
💡 Hint
Automated log rotation helps keep logs manageable and safe.
✗ Incorrect
Using log rotation tools to archive and compress audit logs regularly is the best practice to prevent disk space exhaustion and maintain logs safely.
🔀 Workflow
expert2:30remaining
Sequence of steps to enable and verify audit logging in Hadoop HDFS
Arrange the following steps in the correct order to enable and verify audit logging on the Hadoop NameNode.
Attempts:
2 left
💡 Hint
Configuration changes require restart before testing and verification.
✗ Incorrect
First configure audit logging, then restart NameNode to apply changes, perform an operation to generate logs, and finally check the audit log file.