## What changes were proposed in this pull request?

Cannot connect to MIT KDC admin server when port is specified in 
`kerberos-env/admin_server_host`.  The following error is seen when validating 
the KDC admin credentials:

```
kinit: Server not found in Kerberos database while getting initial credentials
```

The reason for this is due to how the credentials are created for accessing the 
MIT KDC administration server. 

```
kinit -c <path> -S kadmin/<kerberos-env/admin_server_host>  <principal>
```

If a port was added to the {{kerberos-env/admin_server_host}} value then the 
server principal will be generated like `kadmin/kdc.example.com:4749` rather 
than `kadmin/kdc.example.com`. Therefore the server principal is not found.

## How was this patch tested?

Manually tested.

Added new unit tests, all unit tests passed.


Please review [Ambari Contributing 
Guide](https://cwiki.apache.org/confluence/display/AMBARI/How+to+Contribute) 
before opening a pull request.

[ Full content available at: https://github.com/apache/ambari/pull/2147 ]
This message was relayed via gitbox.apache.org for [email protected]

Reply via email to