Install Ambari in CentOS 6.5
Linux: CentOS 6.5
I. preparations:
1. Basic tools
Yum
Rpm
Scp
Curl
Wget
Pdsh
The first few general systems have their own, pdsh needs to be installed: yum install pdsh
This command fails to run the dig command to download pdsh.tar.bz2 and decompress it with tar-jxvf filename.tar. bz. Then enter the filename folder, execute./configure, and then execute the make and make install commands. Installation is complete.
In addition, you can solve the problem of not successfully installing epel by using yum install pdsh. Epel is a project that provides high-quality software packages. The installation process is as follows:
1. Check whether to install: rpm-q epel-release
2. If not, run the rpm command to install: rpm-ivh http://dl.Fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm (you can also manually download the installation package for installation)
3. Check the attached software package: rpm-qR epel-release.
4. import key: rpm -- import/etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
5. install yum-priority: yum install yum-priorities
6. cd/etc/yum. repos. d
Ls | grep epel
7. install pdsh: yum install pdsh
Ambari documentation says "The Python version is shipped with SUSE 11, 2.6.0-8.12.2, has a critical bug that may cause the Ambari Agent to fail with 24 hours. If you are installing on
SUSE 11, please update all your hosts to Python version 2.6.8-0.15.1 ."
Use the yum update python command to update the python version.
2. Configure/etc/hosts and/etc/sysconfig/network respectively.
Take the hosts file modified under the ambari node as an example: (the host machine 192.168.235.138, the master node IP address is 192.168.235.139, And the slave node IP address is 192.168.235.140)
127.0.0.1 ambari
: 1 ambari
192.168.235.139 master
192.168.235.140 slave
(Modify the host name, for example, ambari:
Hostname ambari
Set ambari in vi/etc/sysconfig/network
No need to restart)
3. Set password-free login:
[Root @ ambari ~] # Ssh-keygen
[Root @ ambari ~] # Cat ~ /. Ssh/id_rsa.pub> ~ /. Ssh/authorized_keys
[Root @ ambari ~] # Scp ~ /. Ssh/authorized_keys master:/root/. ssh/
[Root @ ambari ~] # Scp ~ /. Ssh/authorized_keys slave:/root/. ssh/
4. Disable SELinux:
Temporarily close the command: setenforce 0
Permanently close the command: vi/etc/selinux/config
Set SELinux to SELINUX = disabled.
5. Disable the Firewall:
Permanently disable: chkconfig iptables off
Close:/etc/init. d/iptables stop
(You can also choose not to Enable Firewall During setup)
6. Set to disable packagekit
Vi/etc/yum/pluginconf. d/refresh-packagekit.conf
Set enabled to 0
7. Optional: Configure the Local Repositorie (no network connection, or Configure a large cluster and want to maintain bandwidth)
Reference: http://ambari.apache.org/1.2.2/installing-Hadoop-using-ambari/content/ambari-chap1-6.html
Ii. Installation
1. Download the repo File
Wget http://public-repo-1.hortonworks.com/ambari/centos6/1.x/GA/ambari.repo
Cp ambari. repo/etc/yum. repos. d
2. Install epel repository
Yum install epel-release
To check whether the configuration is successful, run the following command:
Yum repolist
If successful, it should be displayed (different systems may be slightly different ):
Repo id repo name status
HDP-UTILS-1.1.0.16 Hortonworks Data Platform Utils Version-HDP-UTILS-1. 61
Updates-ambari-1.x ambari-1.x-Updates 65
Ambari-1.x Ambari 1.x 5
Base CentOS-6-Base 6,367
Epel Extra Packages for Enterprise Linux 6-x86_64 10,633
CentOS-6-extras 14
Updates CentOS-6-Updates 0
Repolist: 17,145
Then install ambari bits:
Yum install ambari-server
This command also installs PostgreSQL.
3. Execute the command: ambari-server setup
If SELinux has not been disabled, you will be prompted to select y when you execute this command. Then, PostgreSQL is configured. Select y to automatically download and install jdk. Then configure the database, select n to use the default database username ambari-server and password bigdata, and select y to create your own username and password.
Run ambari-server start to start the service. Enter "Host Name: 8080" in the browser to enter the logon interface. The default username and password are admin/admin.
You can modify the port number:
In the/etc/ambari-server/conf/ambari. properties file, add
Client. api. port = <port_number>
View ambari process: ps-ef | grep Ambari
Stop the ambari process: ambari-server stop
Restart the ambari process: ambari-server restart
Install Hadoop Cluster Monitoring Tool Ambari
Use Ambari to quickly deploy the Hadoop Big Data Environment
This article permanently updates the link address: