hadoop主机更改主机名或者IP后的处理

hadoop主机更改主机名或者IP后的处理

# rm /var/run/cloudera-scm-agent.pid
rm: remove regular file `/var/run/cloudera-scm-agent.pid’? y
#
#
# service cloudera-scm-agent status
cloudera-scm-agent is stopped
#
#
# grep password /etc/cloudera-scm-server/db.properties
com.cloudera.cmf.db.password=AAECUdv73e
# psql -h localhost -p 7432 -U scm
Password for user scm:
psql: fe_sendauth: no password supplied
# psql -h localhost -p 7432 -U scm
Password for user scm:
psql (9.0.17)
Type “help” for help.

scm=> select host_id,host_identifier,name,ip_address from hosts;
host_id | host_identifier | name | ip_address
———+————————————–+———–+—————–
1 | fda8d3e4-377a-493c-b5f0-e9fb4293fa0e | master243 | 192.168.100.243

scm=>update hosts set (host_identifier,name,ip_address) = (‘fda8d3e4-377a-493c-b5f0-e9fb4293fa0e’,’master236′,’192.168.100.236′) where host_id=1;
( update hosts set (host_identifier,name,ip_address) = (‘yosemite001-10g.somedomain.com’,’yosemite001-10g.somedomain.com’,’192.168.10.11′) where host_id=2; // 网上看到的例子 )

UPDATE 1
scm=>
scm=> select host_id,host_identifier,name,ip_address from hosts;
host_id | host_identifier | name | ip_address
———+————————————–+———–+—————–
1 | fda8d3e4-377a-493c-b5f0-e9fb4293fa0e | master236 | 192.168.100.236

scm=> \q

Print Friendly

发表评论

电子邮件地址不会被公开。 必填项已用*标注