1. 程式人生 > >解決[email protected]'s password:local

解決[email protected]'s password:local

第一種原因:是當前的登陸密碼識別無效

背景:在裝完的Hadoop及JDK之後,在執行start-all.sh的時候出現

           root @ localhost的密碼:localhost:許可權被拒絕,請再試一次           可是,我記得當時設定的密碼是對的,無論怎麼輸都不對

解決方法:在出現上述問題後,輸入       sudo passwd

       然後,會輸入新的密碼,設定之後,再重新格式化一下名稱節點,最後執行start-all.sh,OK。

第二種原因:根使用者的SSH開啟了認證

su root使用者,設定ssh無密碼登陸

cd ~/.ssh/                     # 若沒有該目錄,請先執行一次ssh localhost
ssh-keygen -t rsa              # 會有提示,都按回車就可以
cat ./id_rsa.pub >> ./authorized_keys  # 加入授權
[email protected]
:~/.ssh# ssh localhost Welcome to Ubuntu 18.10 (GNU/Linux 4.18.0-10-generic x86_64) * Documentation: https://help.ubuntu.com * Management: https://landscape.canonical.com * Support: https://ubuntu.com/advantage * Security certifications for Ubuntu! We now have FIPS, STIG, CC and a CIS Benchmark. - http://bit.ly/Security_Certification * Want to make a highly secure kiosk, smart display or touchscreen? Here's a step-by-step tutorial for a rainy weekend, or a startup. - https://bit.ly/secure-kiosk 29 個可升級軟體包。 0 個安全更新。

希望有幫助