void setFileACL(String filePath,
                          String ownerName, boolean ownerReadable, boolean ownerWritable,
                          String groupName, boolean groupReadable, boolean groupWritable)
      throws AmbariException {

    ShellCommandUtil.Result result;

    result = ShellCommandUtil.setFileOwner(filePath, ownerName);

    if (result.isSuccessful()) {
      result = ShellCommandUtil.setFileGroup(filePath, groupName);

      if (!result.isSuccessful()) {
        // Ignore, but log, this it is possible that the group does not exist when performing this operation
        LOG.warn("Failed to set the group for the file at {} to {}: {}", filePath, groupName, result.getStderr());
      }

      result = ShellCommandUtil.setFileMode(filePath,
          ownerReadable, ownerWritable, false,
          groupReadable, groupWritable, false,
          false, false, false);
    }

    if (!result.isSuccessful()) {
      throw new AmbariException(result.getStderr());
    }
  }
Sets the access control list for this specified file.
<p>
The owner and group for the file is set as well as the owner's and group's ability to read and write
the file.
<p>
The result of the operation to set the group for the file is ignored since it is possible that
the group does not exist when performing this operation. It is expected this issue will be remedied
when the group becomes available.
<p>
Access for other users is denied and the file is assumed to not be executeable by anyone.

@param filePath      the path to the file
@param ownerName     the username for the owner of the generated keytab file
@param ownerWritable true if the owner should be able to write to this file; otherwise false
@param ownerReadable true if the owner should be able to read this file; otherwise false
@param groupName     the name of the group for the generated keytab file
@param groupWritable true if the group should be able to write to this file; otherwise false
@param groupReadable true if the group should be able to read this file; otherwise false
@throws AmbariException if an error occurs setting the permissions on the fils
ambari-server/src/main/java/org/apache/ambari/server/serveraction/kerberos/ConfigureAmbariIdentitiesServerAction.java