Case found by akhalymon.
- Setup ambari-agent to run as non-root user with its own group
- Set umask=027 for ambari-agent's user
- Deploy cluster with Spark2, including Thrift Server
Result: Spark2 Thrift Server stops soon after being started
This is happens because spark2-hdp-yarn-archive.tar.gz is uploaded to HDFS as empty file due to incorrect permissions on local source file.