달력

07

« 2010/07 »

  •  
  •  
  •  
  •  
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
2009/11/18 15:29

clusterssh 설치 Linux2009/11/18 15:29

OS 환경 : RHEL 5.3, CentOS 5.3 (x86_64)

다운로드



설치

# rpmbuild -ta --target x86_64 clusterssh-3.27.tar.gz
# rpm -Uvh /usr/src/redhat/RPMS.noarch/clusterssh-3.27-1.noarch.rpm

error: Failed dependencies:
        perl(Tk) >= 800.022 is needed by clusterssh-3.27-1.noarch
        perl(Tk::Dialog) is needed by clusterssh-3.27-1.noarch
        perl(Tk::LabEntry) is needed by clusterssh-3.27-1.noarch
        perl(Tk::ROText) is needed by clusterssh-3.27-1.noarch
        perl(Tk::Xlib) is needed by clusterssh-3.27-1.noarch
        perl(X11::Keysyms) is needed by clusterssh-3.27-1.noarch
        perl(X11::Protocol) is needed by clusterssh-3.27-1.noarch
        perl(X11::Protocol::Constants) is needed by clusterssh-3.27-1.noarch

의존성 에러 해결 : 아래의 두 패키지를 다운받아 설치한다.



참고글



Posted by shsch
2009/08/08 08:28

패스워드 입력없이 ssh 로그인 하기 Linux2009/08/08 08:28

rhel5a 시스템의 testuser 계정으로 rhel5b 시스템의 testuser1 계정으로 ssh 로 로그인 하는데 패스워드 입력없이 로그인 하는 방법.

1. rhel5a 에서  키생성 (그냥 엔터키만 누르고 진행)

[testuser@rhel5a ~]$ ssh-keygen -t dsa
Generating public/private dsa key pair.
Enter file in which to save the key (/home/testuser/.ssh/id_dsa):
Created directory '/home/testuser/.ssh'.
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /home/testuser/.ssh/id_dsa.
Your public key has been saved in /home/testuser/.ssh/id_dsa.pub.
The key fingerprint is:
4d:bd:bc:b9:92:bf:eb:22:a8:5a:af:14:de:41:ad:a2 testuser@rhel5a

2. rhel5b의 testuser1 계정으로 키 복사

[testuser@rhel5a ~]$ ssh-copy-id -i .ssh/id_dsa.pub testuser1@rhel5b
15
The authenticity of host 'rhel5b (192.168.123.121)' can't be established.
RSA key fingerprint is 02:c1:b0:19:9e:10:0f:00:f9:a2:95:9e:3b:60:3e:d4.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'rhel5b,192.168.123.121' (RSA) to the list of known hosts.
testuser1@rhel5b's password:
Now try logging into the machine, with "ssh 'testuser1@rhel5b'", and check in:

  .ssh/authorized_keys

to make sure we haven't added extra keys that you weren't expecting.

3. 원격 접속 확인 

[testuser@rhel5a ~]$ ssh testuser1@rhel5b
Last login: Sat Aug  8 08:19:14 2009 from rhel5a
Posted by shsch
제목에서 처럼 sftp 만 사용 하려고 할 경우에 어떻게 해야 하는지에 대해 간략히 정리한다.

- 테스트 환경 : CentOS 5.1, openssh-server-4.3p2-24.el5

1. 패키지 다운로드 및 설치

# wget http://dag.wieers.com/rpm/packages/rssh/rssh-2.3.2-1.2.el5.rf.i386.rpm
# rpm -Uvh rssh-2.3.2-1.2.el5.rf.i386.rpm

2. 설치된 파일 리스트 보기

[root@centos5 ~]# rpm -ql rssh
/etc/rssh.conf (rssh 의 설정 파일)
/usr/bin/rssh (실행 파일)
/usr/libexec/rssh_chroot_helper
/usr/share/doc/rssh-2.3.2
/usr/share/doc/rssh-2.3.2/AUTHORS
/usr/share/doc/rssh-2.3.2/CHROOT
/usr/share/doc/rssh-2.3.2/COPYING
/usr/share/doc/rssh-2.3.2/ChangeLog
/usr/share/doc/rssh-2.3.2/NEWS
/usr/share/doc/rssh-2.3.2/README
/usr/share/doc/rssh-2.3.2/SECURITY
/usr/share/doc/rssh-2.3.2/TODO
/usr/share/man/man1/rssh.1.gz
/usr/share/man/man5/rssh.conf.5.gz

3. 사용자 쉘 변경

# usermod -s /usr/bin/rssh username

4. ssh / sftp 로 로그인 시도

[username@new21 ~]$ ssh rhel5
The authenticity of host 'rhel5 (192.168.1.240)' can't be established.
RSA key fingerprint is 82:33:6e:88:e4:3c:39:1f:73:89:c2:25:ba:16:39:e5.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'rhel5' (RSA) to the list of known hosts.
shsch@rhel5's password:
Last login: Wed Feb 27 18:50:03 2008 from 192.168.1.227

This account is restricted by rssh.
This user is locked out.

If you believe this is in error, please contact your system administrator.

Connection to rhel5 closed.
[
shsch@new21 ~]$ sftp rhel5
Connecting to rhel5...
shsch@rhel5's password:
Connection closed

위의 메세지 처럼 ssh, sftp 를 사용할 수가 없다.

5. sftp  사용할 수 있도록 설정 하기

아주 간단하게 /etc/rssh.conf 파일을 편집기로 열고 'allow sftp' 줄의 앞의 주석을 제거한다.

#allowscp
allowsftp
#allowcvs
#allowrdist
#allowrsync

다시 sftp 접속을 시도해 보면 정상적으로 연결이 될 것이다.



TAG rssh, SFTP, ssh
Posted by shsch