hostnamectl set-hostname manager-1.example.com
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
10.0.1.239 manager-1.example.com manager-1
10.0.1.240 worker-1.example.com worker-1
10.0.1.241 worker-2.example.com worker-2
10.0.1.238 worker-3.example.com worker-3
yum update
yum install -y java-1.8.0-openjdk-devel
yum install -y wget
/etc/yum.repos.d/
wget https://archive.cloudera.com/cm5/redhat/7/x86_64/cm/cloudera-manager.repo -P /etc/yum.repos.d/
rpm --import https://archive.cloudera.com/cm5/redhat/7/x86_64/cm/RPM-GPG-KEY-cloudera
yum install -y cloudera-manager-daemons cloudera-manager-server
yum install -y postgresql-server
sudo su -l postgres -c "postgresql-setup initdb"
/var/lib/pgsql/data/pg_hba.conf
, 設定 MD5 authenticationhost all all 127.0.0.1/32 md5
/var/lib/pgsql/data/postgresql.conf
listen_addresses = '*'
max_connection = 100
shared_buffers = 256MB
wal_buffers = 8MB
checkpoint_segments = 16
checkpoint_completion_target = 0.9
systemctl enable postgresql
systemctl restart postgresql
sudo -u postgres psql
postgres=# CREATE ROLE scm LOGIN PASSWORD 'scm';
postgres=# CREATE DATABASE scm OWNER scm ENCODING 'UTF8';
postgres=# CREATE ROLE amon LOGIN PASSWORD 'amon';
postgres=# CREATE DATABASE amon OWNER amon ENCODING 'UTF8';
postgres=# CREATE ROLE rman LOGIN PASSWORD 'rman';
postgres=# CREATE DATABASE rman OWNER rman ENCODING 'UTF8';
postgres=# CREATE ROLE nav LOGIN PASSWORD 'nav';
postgres=# CREATE DATABASE nav OWNER nav ENCODING 'UTF8';
postgres=# CREATE ROLE navms LOGIN PASSWORD 'navms';
postgres=# CREATE DATABASE navms OWNER navms ENCODING 'UTF8';
sudo /usr/share/cmf/schema/scm_prepare_database.sh postgresql scm scm
systemctl start cloudera-scm-server
cloudera-scm-server.log
sudo tail -f /var/log/cloudera-scm-server/cloudera-scm-server.log
看到以下log訊息表示cloudera-scm-server已啟動完成
INFO WebServerImpl:com.cloudera.server.cmf.WebServerImpl: Started Jetty server.
http://<manager_server_host>:7180
登入admin
admin
hostnamectl set-hostname worker-1.example.com
yum update
yum install -y java-1.8.0-openjdk-devel
yum install -y wget
/etc/yum.repos.d/
wget https://archive.cloudera.com/cm5/redhat/7/x86_64/cm/cloudera-manager.repo -P /etc/yum.repos.d/
rpm --import https://archive.cloudera.com/cm5/redhat/7/x86_64/cm/RPM-GPG-KEY-cloudera
yum install -y cloudera-manager-daemons cloudera-manager-agent
/etc/cloudera-scm-agent/config.ini
,設定Manager的host, portserver_host=<manager-node ip>
server_port=7182
systemctl start cloudera-scm-agent
IO error:/var/lib/hadoop-yarn/yarn-nm-recovery/yarn-nm-state/LOCK: Permission denied
/var/lib/hadoop-yarn
權限chmod 755 /var/lib/hadoop-yarn
/run/cloudera-scm-agent/process/216-hue-HUE_LOAD_BALANCER/httpd.conf is invalid
httpd
, mod_ssl
yum install -y httpd
yum install -y mod_ssl
systemctl start httpd
/etc/sysconfig/selinux
SELINUX=disabled
SELINUXTYPE=targeted
/var/lib/zookeeper/version-2
/var/lib/zookeeper/version-2
,修改用戶mkdir /var/lib/zookeeper/version-2
chown zookeeper:zookeeper /var/lib/zookeeper/version-2
chmod 755 /var/lib/zookeeper/version-2
/var/lib/oozie
權限及用戶chown oozie:oozie /var/lib/oozie
chmod 755 /var/lib/oozie