I saw a very similar kind of query was asked by another HCC user recently hence i am responding to this threads as well so that other users can also get some idea.
Basically in an Ambari Managed Cluster if we make any changes to the "" files on the filesystem manually then those changes will be reverted back as soon as we try to restart those components via Ambari (UI/API) because ambari will try to create and push those file again based on the Templates.
In your case the template can be seen here:
Example: (On Ambari Server Host)
# cat /var/lib/ambari-server/resources/common-services/HBASE/0.96.0.2.0/package/templates/hbase_queryserver_jaas.conf.j2
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
On Agent Host we can find it in the agent cache which is pulled from Ambari Server:
# ls -l /var/lib/ambari-agent/cache/common-services/HBASE/0.96.0.2.0/package/templates/hbase_queryserver_jaas.conf.j2
So if you want those changes to be poersisted then please make the changes in those templates and then restart agent & ambari server.