今天在linux服务器解压zip类型的文件时,提示 -bash: unzip: command not found
原因:没有安装unzip,使用命令:yum install -y unzip zip 进行安装,之后进行解压,就ok了。
linux 解压:
[root@izbp1edw3m2fbu9g67n5thz home]# unzip xxx.zip
-bash: unzip: command not found
[root@izbp1edw3m2fbu9g67n5thz home]# yum install -y unzip zip
Loaded plugins: fastestmirror
base | 3.6 kB 00:00:00
epel | 3.2 kB 00:00:00
extras | 3.4 kB 00:00:00
updates | 3.4 kB 00:00:00
(1/4): extras/7/x86_64/primary_db | 187 kB 00:00:00
(2/4): epel/x86_64/updateinfo | 941 kB 00:00:00
(3/4): epel/x86_64/primary | 3.6 MB 00:00:00
(4/4): updates/7/x86_64/primary_db | 5.2 MB 00:00:00
Determining fastest mirrors
epel 12672/12672
Resolving Dependencies
--> Running transaction check
---> Package unzip.x86_64 0:6.0-19.el7 will be installed
---> Package zip.x86_64 0:3.0-11.el7 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
=================================================================================
Package Arch Version Repository Size
=================================================================================
Installing:
unzip x86_64 6.0-19.el7 base 170 k
zip x86_64 3.0-11.el7 base 260 k
Transaction Summary
=================================================================================
Install 2 Packages
Total download size: 430 k
Installed size: 1.1 M
Downloading packages:
(1/2): unzip-6.0-19.el7.x86_64.rpm | 170 kB 00:00:00
(2/2): zip-3.0-11.el7.x86_64.rpm | 260 kB 00:00:00
---------------------------------------------------------------------------------
Total 3.4 MB/s | 430 kB 00:00
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Installing : zip-3.0-11.el7.x86_64 1/2
Installing : unzip-6.0-19.el7.x86_64 2/2
Verifying : unzip-6.0-19.el7.x86_64 1/2
Verifying : zip-3.0-11.el7.x86_64 2/2
Installed:
unzip.x86_64 0:6.0-19.el7 zip.x86_64 0:3.0-11.el7
Complete!
[root@izbp1edw3m2fbu9g67n5thz home]# unzip xxx.zip