관리 메뉴

리눅스 CentOS7 YUM 사용 방법 본문

리눅스/Linux 공부내용

리눅스 CentOS7 YUM 사용 방법

ª_ª 2023. 5. 3. 10:04
728x90
반응형

1. yum이란?

YUM (Yellowdog Updater, Modified) 명령어는 CentOS 및 Red Hat Enterprise Linux (RHEL)과 같은 RPM 기반 리눅스 배포판에서 사용되는 패키지 관리자입니다. YUM을 사용하면 쉽게 소프트웨어를 설치, 업데이트, 삭제할 수 있습니다.

2. yum 명령어 정리

2_1) yum 패키지 설치하기

- 명령어 : yum install 패키지이름

yum install 패키지이름
[root@localhost ~]# yum install telnet
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirror.kakao.com
 * extras: mirror.kakao.com
 * updates: mirror.kakao.com
Resolving Dependencies
--> Running transaction check
---> Package telnet.x86_64 1:0.17-66.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

==============================================================================================================================================================================================================
 Package                                        Arch                                           Version                                                  Repository                                       Size
==============================================================================================================================================================================================================
Installing:
 telnet                                         x86_64                                         1:0.17-66.el7                                            updates                                          64 k

Transaction Summary
==============================================================================================================================================================================================================
Install  1 Package

Total download size: 64 k
Installed size: 113 k
Is this ok [y/d/N]: y
Downloading packages:
telnet-0.17-66.el7.x86_64.rpm                                                                                                                                                          |  64 kB  00:00:00
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : 1:telnet-0.17-66.el7.x86_64                                                                                                                                                                1/1
  Verifying  : 1:telnet-0.17-66.el7.x86_64                                                                                                                                                                1/1

Installed:
  telnet.x86_64 1:0.17-66.el7

Complete!
[root@localhost ~]#

 

2_2) yum 패키지 업데이트하기

- 명령어 : yum update 패키지이름

[root@localhost ~]# yum update telnet
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirror.kakao.com
 * extras: mirror.kakao.com
 * updates: mirror.kakao.com
No packages marked for update
[root@localhost ~]#

 

2_3) yum 패키지 삭제하기

- 명령어 : yum remove 패키지이름

yum remove 패키지이름
[root@localhost ~]# yum remove telnet
Loaded plugins: fastestmirror
Resolving Dependencies
--> Running transaction check
---> Package telnet.x86_64 1:0.17-66.el7 will be erased
--> Finished Dependency Resolution

Dependencies Resolved

==============================================================================================================================================================================================================
 Package                                        Arch                                           Version                                                 Repository                                        Size
==============================================================================================================================================================================================================
Removing:
 telnet                                         x86_64                                         1:0.17-66.el7                                           @updates                                         113 k

Transaction Summary
==============================================================================================================================================================================================================
Remove  1 Package

Installed size: 113 k
Is this ok [y/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Erasing    : 1:telnet-0.17-66.el7.x86_64                                                                                                                                                                1/1
  Verifying  : 1:telnet-0.17-66.el7.x86_64                                                                                                                                                                1/1

Removed:
  telnet.x86_64 1:0.17-66.el7

Complete!
[root@localhost ~]#

 

2_4) yum 패키지 검색하기

- 명령어 : yum search 검색어

yum search 검색어
[root@localhost ~]# yum search telnet
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirror.kakao.com
 * extras: mirror.kakao.com
 * updates: mirror.kakao.com
============================================================================================ N/S matched: telnet =============================================================================================
perl-Net-Telnet.noarch : Net-Telnet Perl module
telnet.x86_64 : The client program for the Telnet remote login protocol
telnet-server.x86_64 : The server program for the Telnet remote login protocol
tn5250.i686 : 5250 Telnet protocol and Terminal
tn5250.x86_64 : 5250 Telnet protocol and Terminal

  Name and summary matches only, use "search all" for everything.
[root@localhost ~]#

 

2_5) yum 패키지 정보 확인

- 명령어 : yum info 패키지이름

yum info 패키지이름
[root@localhost ~]# yum info telnet
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirror.kakao.com
 * extras: mirror.kakao.com
 * updates: mirror.kakao.com
Installed Packages
Name        : telnet
Arch        : x86_64
Epoch       : 1
Version     : 0.17
Release     : 66.el7
Size        : 113 k
Repo        : installed
From repo   : updates
Summary     : The client program for the Telnet remote login protocol
URL         : http://web.archive.org/web/20070819111735/www.hcs.harvard.edu/~dholland/computers/old-netkit.html
License     : BSD
Description : Telnet is a popular protocol for logging into remote systems over the
            : Internet. The package provides a command line Telnet client
[root@localhost ~]#

 

728x90
반응형
Comments