[root@nsBunny/]# yum -y install openssh*

[root@nsBunny/]# cd /etc/ssh

[root@nsBunny/etc/ssh]# vi sshd_config

#### 지정된 포트로 접속시 사용가능 #####

Port 22

###### 프로토콜 방식을 결정 한다. #######

Protocol 2,1

# Protocol 1

###### 해당 인증키의 설정을 관리 #######

# HostKey for protocol version 1

HostKey /etc/ssh/ssh_host_key

# HostKeys for protocol version 2

HostKey /etc/ssh/ssh_host_rsa_key

HostKey /etc/ssh/ssh_host_dsa_key

#LoginGraceTime 2m

##### No<ROOT접속불가> Yes<ROOT접속허가> #####

PermitRootLogin no

UsePrivilegeSeparation yes

UsePAM yes

ClientAliveInterval 300

ClientAliveCountMax 6

### ClientAliveInterval : 데이터 수신이 없을시에 클라이언트가 살아있는지 확인 신호를 보내는 간격을 시간으로 지정.

### ClientAliveCountMax : 확인 신호를 지정된 횟수만큼 보낸다는 의미.

이런식으로 주석을 풀고 설정하면 된다.

[root@nsBunny/etc/ssh]# service sshd restart

sshd 를 정지 중: [ OK ]

sshd ()를 시작 중: [ OK ]

[root@nsBunny/etc/ssh]# su - bunny

[bunny@ns ~]$ ssh-keygen

Generating public/private rsa key pair.

Enter file in which to save the key (/home/bunny/.ssh/id_rsa):

Created directory '/home/bunny/.ssh'.

Enter passphrase (empty for no passphrase): xxxxxxxxxxxxxx

Enter same passphrase again: xxxxxxxxxxxxxxx

[bunny@ns ~]$ ssh -l root xxxxxxxxxx.pe.kr

The authenticity of host 'xxxxxxxxxx.pe.kr (211.238.xxx.xxx)' can't be established.

Are you sure you want to continue connecting (yes/no)? yes

Warning: Permanently added 'xxxxxxxxx.pe.kr,211.238.xxx.xxx' (RSA) to the list of known hosts.

root@xxxxxxxx.pe.kr's password: xxxxxxxxxxxxxxxxxx

Last login: Thu Sep 13 20:46:17 2012 from 118.217.164.49

root@nsBunny~]# è 이런 방식으로 사용하는게 SSH이다.

+ Recent posts