"CentOS expect 설치"의 두 판 사이의 차이

4번째 줄: 4번째 줄:


==설치 확인==
==설치 확인==
===실행===
<source lang='dos'>
;명령어
[root@jmnote ~]# rpm -qa | grep expect
<source lang='bash'>
expect
which expect
</source>
</source>


;실행결과
==설치==
<source lang='dos'>
<source lang='dos'>
[root@jmnote ~]# expect
[root@jmnote ~]# yum install expect -y
-bash: expect: command not found
Loaded plugins: fastestmirror
[root@jmnote ~]# which expect
Loading mirror speeds from cached hostfile
/usr/bin/which: no expect in (/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin)
Setting up Install Process
</source>
Resolving Dependencies
--> Running transaction check
---> Package expect.i386 0:5.43.0-8.el5 set to be updated
--> Processing Dependency: libtcl8.4.so for package: expect
---> Package expect.x86_64 0:5.43.0-8.el5 set to be updated
--> Running transaction check
---> Package tcl.i386 0:8.4.13-4.el5 set to be updated
--> Finished Dependency Resolution
 
Dependencies Resolved
 
================================================================================================================
Package                  Arch                    Version                        Repository              Size
================================================================================================================
Installing:
expect                  i386                    5.43.0-8.el5                    Daum                  158 k
expect                   x86_64                  5.43.0-8.el5                    Daum                  161 k
Installing for dependencies:
tcl                      i386                    8.4.13-4.el5                    Daum                  956 k
 
Transaction Summary
================================================================================================================
Install      3 Package(s)
Upgrade      0 Package(s)
 
Total download size: 1.2 M
Downloading Packages:
(1/3): expect-5.43.0-8.el5.i386.rpm                                                      | 158 kB    00:00   
(2/3): expect-5.43.0-8.el5.x86_64.rpm                                                    | 161 kB    00:00   
(3/3): tcl-8.4.13-4.el5.i386.rpm                                                        | 956 kB    00:00   
----------------------------------------------------------------------------------------------------------------
Total                                                                          2.3 MB/s | 1.2 MB    00:00   
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing    : expect                                                                                  1/3
  Installing    : tcl                                                                                      2/3
  Installing    : expect                                                                                  3/3


===yum===
Installed:
;명령어
  expect.i386 0:5.43.0-8.el5                            expect.x86_64 0:5.43.0-8.el5                         
<source lang='bash'>
yum info expect
</source>


;실행결과
Dependency Installed:
<source lang='dos'>
  tcl.i386 0:8.4.13-4.el5                                                                                     
[root@jmnote ~]# yum info expect
Loaded plugins: fastestmirror, refresh-packagekit
Loading mirror speeds from cached hostfile
* fedora: ftp.tsukuba.wide.ad.jp
* updates: ftp.cuhk.edu.hk
Available Packages
Name      : expect
Arch      : i586
Version    : 5.43.0
Release    : 17.fc11
Size      : 265 k
Repo      : fedora
Summary    : A program-script interaction and testing utility
URL        : http://expect.nist.gov/
License    : Public Domain
Description: Expect is a tcl application for automating and testing
          : interactive applications such as telnet, ftp, passwd, fsck,
          : rlogin, tip, etc. Expect makes it easy for a script to
          : control another program and interact with it.
          :
          : This package contains expect and some scripts that use it.


Name      : expect
Complete!
Arch      : x86_64
Version    : 5.43.0
Release    : 17.fc11
Size      : 267 k
Repo      : fedora
Summary    : A program-script interaction and testing utility
URL        : http://expect.nist.gov/
License    : Public Domain
Description: Expect is a tcl application for automating and testing
          : interactive applications such as telnet, ftp, passwd, fsck,
          : rlogin, tip, etc. Expect makes it easy for a script to
          : control another program and interact with it.
          :
          : This package contains expect and some scripts that use it.
</source>
</source>
:→ Repo 에 installed라고 나온 것이 없으므로 설치되지 않았다.


==설치==
==설치==

2012년 8월 13일 (월) 23:28 판

expect
리눅스 expect 설치
yum으로 expect 설치

1 설치 확인

[root@jmnote ~]# rpm -qa | grep expect

2 설치

[root@jmnote ~]# yum install expect -y
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package expect.i386 0:5.43.0-8.el5 set to be updated
--> Processing Dependency: libtcl8.4.so for package: expect
---> Package expect.x86_64 0:5.43.0-8.el5 set to be updated
--> Running transaction check
---> Package tcl.i386 0:8.4.13-4.el5 set to be updated
--> Finished Dependency Resolution

Dependencies Resolved

================================================================================================================
 Package                  Arch                     Version                         Repository              Size
================================================================================================================
Installing:
 expect                   i386                     5.43.0-8.el5                    Daum                   158 k
 expect                   x86_64                   5.43.0-8.el5                    Daum                   161 k
Installing for dependencies:
 tcl                      i386                     8.4.13-4.el5                    Daum                   956 k

Transaction Summary
================================================================================================================
Install       3 Package(s)
Upgrade       0 Package(s)

Total download size: 1.2 M
Downloading Packages:
(1/3): expect-5.43.0-8.el5.i386.rpm                                                      | 158 kB     00:00     
(2/3): expect-5.43.0-8.el5.x86_64.rpm                                                    | 161 kB     00:00     
(3/3): tcl-8.4.13-4.el5.i386.rpm                                                         | 956 kB     00:00     
----------------------------------------------------------------------------------------------------------------
Total                                                                           2.3 MB/s | 1.2 MB     00:00     
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing     : expect                                                                                   1/3 
  Installing     : tcl                                                                                      2/3 
  Installing     : expect                                                                                   3/3 

Installed:
  expect.i386 0:5.43.0-8.el5                            expect.x86_64 0:5.43.0-8.el5                           

Dependency Installed:
  tcl.i386 0:8.4.13-4.el5                                                                                       

Complete!

3 설치

명령어
yum install expect -y
실행결과
[root@jmnote ~]# yum install expect -y
Loaded plugins: fastestmirror, refresh-packagekit
Loading mirror speeds from cached hostfile
 * fedora: ftp.tsukuba.wide.ad.jp
 * updates: ftp.cuhk.edu.hk
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package expect.x86_64 0:5.43.0-17.fc11 set to be updated
--> Finished Dependency Resolution

Dependencies Resolved

===========================================================================================
 Package            Arch               Version                    Repository          Size
===========================================================================================
Installing:
 expect             x86_64             5.43.0-17.fc11             fedora             267 k

Transaction Summary
===========================================================================================
Install       1 Package(s)
Upgrade       0 Package(s)

Total download size: 267 k
Downloading Packages:
http://ftp.tsukuba.wide.ad.jp/Linux/fedora-archive/fedora/linux/releases/11/Everything/x86_64/os/Packages/expect-5.43.0-17.fc11.x86_64.rpm: [Errno 4] IOError: <urlopen error [Errno 101] Network is unreachable>
Trying other mirror.
expect-5.43.0-17.fc11.x86_64.rpm                                    | 267 kB     00:01     
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing     : expect-5.43.0-17.fc11.x86_64                                        1/1 
Unable to connect to dbus

Installed:
  expect.x86_64 0:5.43.0-17.fc11                                                           

Complete!

4 테스트

명령어
which expect
expect
실행결과
[root@jmnote ~]# which expect
/usr/bin/expect
[root@jmnote ~]# expect
expect1.1> ^C[root@jmnote ~]# 
[root@jmnote ~]#
→ expect 프롬프트가 나오는 것을 확인하고 Ctrl+C를 눌러 종료하였다.
문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}