hadoop密码
- 作者: 非凡之享
- 来源: 51数据库
- 2020-09-30
将密钥写入ssh中
cat /root/.ssh/id_rsa.pub >> /root/.ssh/authorized_keys
/etc/init.d/ssh reload1212
再次启动hadoop就没有密码输入的要求了。
是因为没有设置ssh无密码登录,在你机器上运行一下两个命令,增加当前用户使用ssh无密码登录权限
ssh-keygen -t dsa -p '' -f ~/.ssh/id_dsa
cat ~/.ssh/id_dsa.pub >> ~/.ssh/authorized_keys
之后,使用ssh localhost不需要输入任何密码就能登录的话,你启动的时候就不需要再输入密码了。
ssh localhost还需要密码的话,请检查你的跟目录权限是否为700,不会700的话,使用chmod -r 700 ~之后应该就好了。
cat /root/.ssh/id_rsa.pub >> /root/.ssh/authorized_keys
/etc/init.d/ssh reload1212
再次启动hadoop就没有密码输入的要求了。
是因为没有设置ssh无密码登录,在你机器上运行一下两个命令,增加当前用户使用ssh无密码登录权限
ssh-keygen -t dsa -p '' -f ~/.ssh/id_dsa
cat ~/.ssh/id_dsa.pub >> ~/.ssh/authorized_keys
之后,使用ssh localhost不需要输入任何密码就能登录的话,你启动的时候就不需要再输入密码了。
ssh localhost还需要密码的话,请检查你的跟目录权限是否为700,不会700的话,使用chmod -r 700 ~之后应该就好了。
推荐阅读
