0
0
Hadoopdata~20 mins

NameNode and DataNode roles in Hadoop - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Hadoop Roles Mastery
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
1:30remaining
Role of NameNode in Hadoop
What is the primary responsibility of the NameNode in a Hadoop cluster?
AExecuting MapReduce tasks on data nodes
BStoring the actual data blocks of files
CHandling network communication between clients and data nodes
DManaging the metadata and directory structure of the file system
Attempts:
2 left
💡 Hint
Think about which node keeps track of where files are stored.
🧠 Conceptual
intermediate
1:30remaining
Role of DataNode in Hadoop
Which of the following best describes the role of a DataNode in Hadoop?
AStores the actual data blocks and serves read/write requests
BManages the file system namespace and metadata
CCoordinates job scheduling and resource allocation
DMonitors network traffic between nodes
Attempts:
2 left
💡 Hint
Consider which node physically holds the data.
data_output
advanced
1:00remaining
DataNode Heartbeat Frequency
Given a Hadoop cluster where DataNodes send heartbeats every 3 seconds, how many heartbeats will a single DataNode send in 1 minute?
A20
B60
C30
D15
Attempts:
2 left
💡 Hint
Calculate how many 3-second intervals fit into 60 seconds.
Predict Output
advanced
1:30remaining
NameNode Metadata Access Simulation
What is the output of this Python code simulating NameNode metadata access counts?
Hadoop
metadata_access = {'file1': 5, 'file2': 3, 'file3': 7}
most_accessed = max(metadata_access, key=metadata_access.get)
print(most_accessed)
A7
Bfile2
Cfile3
Dfile1
Attempts:
2 left
💡 Hint
max with key returns the key with the highest value.
🔧 Debug
expert
1:30remaining
DataNode Block Report Error Identification
What error will this Python code raise when simulating a DataNode sending a block report with a missing key?
Hadoop
block_report = {'block1': 'OK', 'block2': 'OK'}
print(block_report['block3'])
AIndexError
BKeyError
CTypeError
DNo error, prints None
Attempts:
2 left
💡 Hint
Accessing a dictionary with a missing key causes a specific error.