You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 68 Next »

Checking out Ambari source

The following uses the Ambari git repository for the development process. Please keep in mind that the git repository is read only and patches will have to be uploaded and committed via svn.

git clone git://git.apache.org/ambari.git
cd ambari

We'll refer to the top-level "ambari" directory as AMBARI_DIR in this document.

Tools needed to build Ambari

  • JDK 1.6.0
  • Apache Maven
  • Python 2.6
  • Python setuptools - Download and run:
    sh setuptools-0.6c11-py2.6.egg
  • NodeJS
  • Brunch 1.4.4 (to install it, run the following command after NodeJS is installed):
    npm install -g brunch@1.4.4

Building Ambari

To build tarball artifacts run:

RHEL/CentOS 5:

mvn -X -B -e clean install package rpm:rpm -DskipTests -Pcentos5 -Dpython.ver="python26"

RHEL/CentOS 6:

mvn -X -B -e clean install package rpm:rpm -DskipTests -Dpython.ver="python >= 2.6"

SUSE/SLES 11:

mvn -X -B -e clean install package rpm:rpm -DskipTests -Psuse11 -Dpython.ver="python >= 2.6"

This will build the Server and Agent RPMs.

NOTE: Run everything as root below.

Running the Ambari Server

First, install the Ambari Server RPM:

yum install ambari-server-*.rpm
ambari-server setup

Start up Ambari Server:

ambari-server start

To access Ambari, go to

http://{ambari-server-hostname}:8080

from your web browser.

Install the Ambari Agent Manually (Optional)

yum install ambari-agent-*.rpm
ambari-agent start
/var/log/ambari-agent/ambari-agent.log

Setting up Ambari in Eclipse

$ mvn clean eclipse:eclipse

After doing the above you should be able to import the project via Eclipse "Import > Maven > Existing Maven Project". Choose the root directory where you cloned the git repository. You should be able to see the following projects on eclipse:

ambari
|
|- ambari-project
|- ambari-server
|- ambari-agent
|- ambari-web

Select the top-level "ambari pom.xml" and click Finish.

  • No labels