Community Articles

Find and share helpful community-sourced technical articles.
Celebrating as our community reaches 100,000 members! Thank you!
Labels (1)
Super Guru

Please follow the steps below to install ambari-shell on your system -

Environment setup details -

Virtual Box : 5.0.14 OS : CentOS release 6.7 (64-bit) Ambari-shell code : Gradle Version: gradle-1.12 [ ] Java Version: 1.7.0_79

Installation steps:

1.Login using root/superuser 2.Install "git" package using rpm/yum command

# yum install -y git

[Note: Make sure you have internet access to your system and /etc/yum.repos.d/CentOS-Base.repo in place unless you have local repository configured to download packages]

3.Download Gradle from the link given above and unzip it in a directory. Here i will download code in /opt directory

# cd /opt # wget # unzip

# cd /opt
# wget
# unzip

4. Export gradle home path

# export PATH=$PATH:/opt/gradle-2.11/bin

5. Make sure you have Java installed and set the JAVA_HOME variable in your path

[root@test opt]# rpm -qa |grep java-1.7.0

#export JAVA_HOME=/usr/jdk64/jdk1.7.0_67/

Note: I have installed java in "/usr/jdk64". Please replace the path, where you have java installed.

6. Download "ambari-shell" code from git and compile the code using gradle -

# cd /opt/# git clone
# cd /opt/ambari-shell
# gradle clean build 

7. The above command will successfully compile ambari-shell code and you should be able to see sample output as shown below -


Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.

Total time: 32.558 secs

8. Once build is successful it will create a jar which will be located in below path -

[root@test ~]# ls  /opt/ambari-shell/build/libs/
ambari-shell-0.1.DEV.jar          ambari-shell-0.1.DEV.jar.original

9. After compiling the project, the shell is ready to use (make sure you use Java 7 or above).

# java -jar /opt/ambari-shell/build/libs/ambari-shell-0.1.DEV.jar --ambari.server=localhost --ambari.port=8080 --ambari.user=admin --ambari.password=admin

Below is sample output after executing above command -


10. Login to ambari-shell and try building your cluster. Please refer "" for more details.

Master Guru

Nice one!

Master Guru

@Sagar Shimpi, nice article! Are there any prebuilt jars (or rpm/tar's) ready to be installed? There are many places where I cannot install git and gradle, but could show up Ambari shell as a kind of "coming soon" add-on for Ambari. Tnx.

Super Guru

I see that there are no ready jars available on internet for ambari shell. But what the best way we can do is to build/compile the ambari-shell code on our test/local environment and use the jar directly at other places. You do no need to compile it everytime.

Ever i can pass you the jar on email and you can directly test with below command in your environment...Just need to ensure the OS and java version should be same.

# java -jar /opt/ambari-shell/build/libs/ambari-shell-0.1.DEV.jar --ambari.server=localhost --ambari.port=8080 --ambari.user=admin --ambari.password=admin


use and not --ambari.server

I have merged the outstanding pull requests from the sequenceiq repo into mine.

Check it out here:


There is a file in the repo. Running it will fetch a version.


@sshimpi I am getting this failure error when I do gradle clean build :



The 'sonar-runner' plugin has been deprecated and is scheduled to be removed in Gradle 3.0. please use the official plugin from SonarQube ( :clean :buildInfo :compileJava FAILURE: Build failed with an exception. * What went wrong: Could not resolve all dependencies for configuration ':compile'. > Could not resolve com.sequenceiq:ambari-client20:2.0.1. Required by: com.sequenceiq:ambari-shell:0.1.DEV > Could not resolve com.sequenceiq:ambari-client20:2.0.1. > Could not get resource ''. > Could not GET ''. > Name or service not known > Could not resolve com.sequenceiq:ambari-client20:2.0.1. > Could not get resource ''. > Could not GET ''. > > Could not resolve com.sequenceiq:ambari-client20:2.0.1. > Could not get resource ''. > Could not GET ''. > * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. BUILD FAILED Total time: 11.708 secs



Please help!