hadoop學習之通過cygwin配置ssh服務

 

快過年了,找了家新單位開始學習hadoop。

 

機器是xp系統,cygwin的安裝過程略去。

 

 

ssh的配置如下:

 

 

 

 寫道

Copying skeleton files.
These files are for the users to personalise their cygwin experience.

They will never be overwritten nor automatically updated.

`./.bashrc' -> `/home/greatwhite//.bashrc'
`./.bash_profile' -> `/home/greatwhite//.bash_profile'
`./.inputrc' -> `/home/greatwhite//.inputrc'
`./.profile' -> `/home/greatwhite//.profile'

greatwhite@IT01020110116 ~
$ ls

greatwhite@IT01020110116 ~
$ ssh-host-config

*** Info: Generating /etc/ssh_host_key
*** Info: Generating /etc/ssh_host_rsa_key
*** Info: Generating /etc/ssh_host_dsa_key
*** Info: Generating /etc/ssh_host_ecdsa_key
*** Info: Creating default /etc/ssh_config file
*** Info: Creating default /etc/sshd_config file
*** Info: Privilege separation is set to yes by default since OpenSSH 3.3.
*** Info: However, this requires a non-privileged account called 'sshd'.
*** Info: For more info on privilege separation read /usr/share/doc/openssh/README.privsep.
*** Query: Should privilege separation be used? (yes/no) no
*** Info: Updating /etc/sshd_config file
*** Info: Added ssh to C:\WINDOWS\system32\driversc\services

*** Query: Do you want to install sshd as a service?
*** Query: (Say "no" if it is already installed as a service) (yes/no) yes
*** Query: Enter the value of CYGWIN for the daemon: []

*** Info: The sshd service has been installed under the LocalSystem
*** Info: account (also known as SYSTEM). To start the service now, call
*** Info: `net start sshd' or `cygrunsrv -S sshd'. Otherwise, it
*** Info: will start automatically after the next reboot.

*** Info: Host configuration finished. Have fun!

greatwhite@IT01020110116 ~
$ cd .ssh

greatwhite@IT01020110116 ~/.ssh
$ ssh-keygen
Generating public/private rsa key pair.
Enter file in which to save the key (/home/greatwhite/.ssh/id_rsa):
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /home/greatwhite/.ssh/id_rsa.
Your public key has been saved in /home/greatwhite/.ssh/id_rsa.pub.
The key fingerprint is:
4a:9e:50:56:88:28:10:c1:2d:a8:4a:61:9f:75:9c:c3 greatwhite@IT01020110116
The key's randomart image is:
+--[ RSA 2048]----+
|Bo.. .o.o |
|o=.....E |
|o.+ o + . |
|.. o o |
|o . . S |
|. + o |
| + |
| |
| |
+-----------------+

greatwhite@IT01020110116 ~/.ssh
$ ls
id_rsa id_rsa.pub

greatwhite@IT01020110116 ~/.ssh
$ cp id_rsa.pub authorized_keys

greatwhite@IT01020110116 ~/.ssh
$ ls
authorized_keys id_rsa id_rsa.pub

greatwhite@IT01020110116 ~/.ssh
$ exit
 

 

先退出cygwin,然後重新打開一個cygwin窗口。

 

 

 寫道

greatwhite@IT01020110116 ~
$ ssh localhost
The authenticity of host 'localhost (127.0.0.1)' can't be established.
ECDSA key fingerprint is 03:df:9e:d4:d2:84:e6:2c:a8:a2:b7:e7:f9:09:83:76.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'localhost' (ECDSA) to the list of known hosts.

greatwhite@IT01020110116 ~
$ who
greatwhite tty1 2011-12-27 11:44 (localhost)
 

 

配置成功。

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章