apache/hadoop · error · IOException
Can't get Master Kerberos principal for the RM to use as ren
Error message
Can't get Master Kerberos principal for the RM to use as renewer
What it means
Error "Can't get Master Kerberos principal for the RM to use as renewer" thrown in apache/hadoop.
Source
Thrown at hadoop-tools/hadoop-dynamometer/hadoop-dynamometer-infra/src/main/java/org/apache/hadoop/tools/dynamometer/Client.java:608
// Set the necessary command to execute the application master
amContainer.setCommands(getAMCommand());
Resource capability = Records.newRecord(Resource.class);
capability.setMemorySize(amMemory);
capability.setVirtualCores(amVCores);
appContext.setResource(capability);
// Setup security tokens
if (UserGroupInformation.isSecurityEnabled()) {
ByteBuffer fsTokens;
if (tokenFileLocation != null) {
fsTokens = ByteBuffer
.wrap(Files.readAllBytes(Paths.get(tokenFileLocation)));
} else {
Credentials credentials = new Credentials();
String tokenRenewer = getConf().get(YarnConfiguration.RM_PRINCIPAL);
if (tokenRenewer == null || tokenRenewer.length() == 0) {
throw new IOException("Can't get Master Kerberos principal for the "
+ "RM to use as renewer");
}
// For now, only getting tokens for the default file-system.
final Token<?>[] tokens = fs.addDelegationTokens(tokenRenewer,
credentials);
if (tokens != null) {
for (Token<?> token : tokens) {
LOG.info("Got dt for " + fs.getUri() + "; " + token);
}
}
DataOutputBuffer dob = new DataOutputBuffer();
credentials.writeTokenStorageToStream(dob);
fsTokens = ByteBuffer.wrap(dob.getData(), 0, dob.getLength());
}
amContainer.setTokens(fsTokens);
}
View on GitHub (pinned to 2add963021)
Solutions
- Configure yarn.resourcemanager.principal (and matching keytab) so the RM renewer principal can be resolved in a secure cluster.
When it happens
Trigger: In a Kerberos-enabled deployment the dynamometer Client cannot resolve the ResourceManager master principal to use as a token renewer, typically because yarn-site.xml is missing yarn.resourcemanager.principal or the principal is misconfigured.
Common situations: See trigger scenarios.
AI-assisted analysis of apache/hadoop@2add963021 (2026-08-22).
Data as JSON: /api/errors/1d943098e56944a2.
Report an issue: GitHub.