|
@@ -314,17 +314,17 @@ public final class OzoneManager extends ServiceRuntimeInfoImpl
|
|
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
- * Login KSM service user if security and Kerberos are enabled.
|
|
|
|
|
|
+ * Login OM service user if security and Kerberos are enabled.
|
|
*
|
|
*
|
|
* @param conf
|
|
* @param conf
|
|
* @throws IOException, AuthenticationException
|
|
* @throws IOException, AuthenticationException
|
|
*/
|
|
*/
|
|
- private static void loginKSMUser(OzoneConfiguration conf)
|
|
|
|
|
|
+ private static void loginOMUser(OzoneConfiguration conf)
|
|
throws IOException, AuthenticationException {
|
|
throws IOException, AuthenticationException {
|
|
|
|
|
|
if (SecurityUtil.getAuthenticationMethod(conf).equals
|
|
if (SecurityUtil.getAuthenticationMethod(conf).equals
|
|
(AuthenticationMethod.KERBEROS)) {
|
|
(AuthenticationMethod.KERBEROS)) {
|
|
- LOG.debug("Ozone security is enabled. Attempting login for KSM user. "
|
|
|
|
|
|
+ LOG.debug("Ozone security is enabled. Attempting login for OM user. "
|
|
+ "Principal: {},keytab: {}", conf.get(
|
|
+ "Principal: {},keytab: {}", conf.get(
|
|
OZONE_OM_KERBEROS_PRINCIPAL_KEY),
|
|
OZONE_OM_KERBEROS_PRINCIPAL_KEY),
|
|
conf.get(OZONE_OM_KERBEROS_KEYTAB_FILE_KEY));
|
|
conf.get(OZONE_OM_KERBEROS_KEYTAB_FILE_KEY));
|
|
@@ -336,10 +336,10 @@ public final class OzoneManager extends ServiceRuntimeInfoImpl
|
|
OZONE_OM_KERBEROS_PRINCIPAL_KEY, socAddr.getHostName());
|
|
OZONE_OM_KERBEROS_PRINCIPAL_KEY, socAddr.getHostName());
|
|
} else {
|
|
} else {
|
|
throw new AuthenticationException(SecurityUtil.getAuthenticationMethod
|
|
throw new AuthenticationException(SecurityUtil.getAuthenticationMethod
|
|
- (conf) + " authentication method not supported. KSM user login "
|
|
|
|
|
|
+ (conf) + " authentication method not supported. OM user login "
|
|
+ "failed.");
|
|
+ "failed.");
|
|
}
|
|
}
|
|
- LOG.info("KSM login successful.");
|
|
|
|
|
|
+ LOG.info("Ozone Manager login successful.");
|
|
}
|
|
}
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -495,7 +495,7 @@ public final class OzoneManager extends ServiceRuntimeInfoImpl
|
|
}
|
|
}
|
|
// Authenticate KSM if security is enabled
|
|
// Authenticate KSM if security is enabled
|
|
if (conf.getBoolean(OzoneConfigKeys.OZONE_SECURITY_ENABLED_KEY, true)) {
|
|
if (conf.getBoolean(OzoneConfigKeys.OZONE_SECURITY_ENABLED_KEY, true)) {
|
|
- loginKSMUser(conf);
|
|
|
|
|
|
+ loginOMUser(conf);
|
|
}
|
|
}
|
|
switch (startOpt) {
|
|
switch (startOpt) {
|
|
case INIT:
|
|
case INIT:
|