首先,我得说几句,我第一次进行了实验。

压缩文件夹html

rar压缩   成绩5.18M

zip压缩  成绩5.06M

7z压缩   成绩870K

第一种,源代码编译安装

官网下载地址:http://www.7-zip.org/download.html

源文件项目地址:http://sourceforge.net/projects/p7zip/,眼下最新版为9.20.1。

运行下面命令下载安装:

wget http://nchc.dl.sourceforge.net/project/p7zip/p7zip/9.20.1/p7zip_9.20.1_src_all.tar.bz2
tar -jxvf p7zip_9.20.1_src_all.tar.bz2
cd p7zip_9.20.1
make
make install

最后一步make install后出现下面信息。即为安装完成

./install.sh /usr/local/bin /usr/local/lib/p7zip /usr/local/man /usr/local/share/doc/p7zip
- installing /usr/local/bin/7za
- installing /usr/local/man/man1/7z.1
- installing /usr/local/man/man1/7za.1
- installing /usr/local/man/man1/7zr.1
- installing /usr/local/share/doc/p7zip/README
- installing /usr/local/share/doc/p7zip/ChangeLog
- installing HTML help in /usr/local/share/doc/p7zip/DOCS

另外一种,rpm安装

下载地址:http://pkgs.repoforge.org/p7zip/,请以最新版为准。

在 CentOS 5.x 32位下安装7ZIP

wget http://pkgs.repoforge.org/p7zip/p7zip-9.20.1-1.el5.rf.i386.rpm
rpm -ivh p7zip-9.20.1-1.el5.rf.i386.rpm

在 CentOS 5.x 64位下安装7ZIP

wget http://pkgs.repoforge.org/p7zip/p7zip-9.20.1-1.el5.rf.x86_64.rpm
rpm -ivh p7zip-9.20.1-1.el5.rf.x86_64.rpm

在 CentOS 6.x 32位下安装7ZIP

wget http://pkgs.repoforge.org/p7zip/p7zip-9.20.1-1.el6.rf.i686.rpm
rpm -ivh p7zip-9.20.1-1.el6.rf.i686.rpm

在 CentOS 6.x 64位下安装7ZIP

wget http://pkgs.repoforge.org/p7zip/p7zip-9.20.1-1.el6.rf.x86_64.rpm
rpm -ivh p7zip-9.20.1-1.el6.rf.x86_64.rpm

第三种,yum安装

通过《在Centos 5.x或6.x上安装RHEL EPEL Repo》一文,安装RHEL EPEL Repo后,就可以使用yum安装7ZIP。

命令例如以下:

yum install -y p7zip

7-Zip (A) [64] 9.20  Copyright (c) 1999-2010 Igor Pavlov  2010-11-18
p7zip Version 9.20 (locale=zh_CN.UTF-8,Utf16=on,HugeFiles=on,1 CPU) Usage: 7za <command> [<switches>...] <archive_name> [<file_names>...]
[<@listfiles...>] <Commands>
a: Add files to archive
b: Benchmark
d: Delete files from archive
e: Extract files from archive (without using directory names)
l: List contents of archive
t: Test integrity of archive
u: Update files to archive
x: eXtract files with full paths
<Switches>
-ai[r[-|0]]{@listfile|!wildcard}: Include archives
-ax[r[-|0]]{@listfile|!wildcard}: eXclude archives
-bd: Disable percentage indicator
-i[r[-|0]]{@listfile|!wildcard}: Include filenames
-m{Parameters}: set compression Method
-o{Directory}: set Output directory
-p{Password}: set Password
-r[-|0]: Recurse subdirectories
-scs{UTF-8 | WIN | DOS}: set charset for list files
-sfx[{name}]: Create SFX archive
-si[{name}]: read data from stdin
-slt: show technical information for l (List) command
-so: write data to stdout
-ssc[-]: set sensitive case mode
-t{Type}: Set type of archive
-u[-][p#][q#][r#][x#][y#][z#][!newArchiveName]: Update options
-v{Size}[b|k|m|g]: Create volumes
-w[{path}]: assign Work directory. Empty path means a temporary directory
-x[r[-|0]]]{@listfile|!wildcard}: eXclude filenames

版权声明:本文博主原创文章。博客,未经同意不得转载。

centos 之7zip的更多相关文章

  1. 7z

    7zip是一款开源的解压缩软件,不仅自己独有的7z格式,而且支持zip,rar,tar,gzip等众多其他格式,同时7z格式的压缩比例很高,目前很多硬盘版的游戏都采用zip进行打包.下面介绍一下Lin ...

  2. CentOS中如何安装7ZIP

    7-zip以高压缩率著称,并且是一款免费开源的压缩软件.在常规的Linux发行版中,无法通过简单的yum命令来安装该软件.那么在CentOS中,如何安装7ZIP呢?有以下3种方法: 第一种,源码编译安 ...

  3. RHEL/CentOS 7最小化安装后需做的30件事情

    导读 CentOS是一个工业标准的Linux发行版,是红帽企业版 Linux 的衍生版本.你安装完后马上就可以使用,但是为了更好地使用你的系统,你需要进行一些升级.安装新的软件包.配置特定服务和应用程 ...

  4. 安装完最小化 RHEL/CentOS 7 后需要做的 30 件事情(四)码农网

    17. 安装 Webmin Webmin 是基于 Web 的 Linux 配置工具.它像一个中央系统,用于配置各种系统设置,比如用户.磁盘分配.服务以及 HTTP 服务器.Apache.MySQL 等 ...

  5. Windows 8和CentOS 6.4(64)双系统硬盘安装教程

    最近在笔记本上升级原来的系统Win7到Win8,同时又安装了CentOS 6.4(64)系统,实现双系统共存.着实折腾了一番,主要是CentOS6.4(64)的两个iso文件加起来5G多(其实只用第一 ...

  6. CentOS上解压ZIP乱码的解决办法

    今天在学校做实验需要解压缩一些范例程序,我准备在我的电脑上把这个实验做完,所以就把文件copy到我的CentOS里面去了. 但是万万没想到``````解压缩的时候悲剧了,用unzip解压出来一大堆乱码 ...

  7. 安装完最小化 RHEL/CentOS 7 后需要做的 30 件事情(一)转载自码农网

    CentOS 是一个工业标准的 Linux 发行版,是红帽企业版 Linux 的衍生版本.你安装完后马上就可以使用,但是为了更好地使用你的系统,你需要进行一些升级.安装新的软件包.配置特定服务和应用程 ...

  8. 安装完最小化 RHEL/CentOS 7 后需要做的 30 件事情7. 安装 PHP PHP 是用于 web 基础服务的服务器端脚本语言。它也经常被用作通用编程语言。在最小化安装的 CentOS 中安

    CentOS 是一个工业标准的 Linux 发行版,是红帽企业版 Linux 的衍生版本.你安装完后马上就可以使用,但是为了更好地使用你的系统,你需要进行一些升级.安装新的软件包.配置特定服务和应用程 ...

  9. 安装完最小化 RHEL/CentOS 7 后需要做的 30 件事情(一)

    本文导航 -1. 注册并启用红帽订阅 -2. 使用静态 IP 地址配置网络 -3. 设置服务器的主机名称 -4. 更新或升级最小化安装的 CentOS -5. 安装命令行 Web 浏览器 -6. 安装 ...

随机推荐

  1. 【原创】构建高性能ASP.NET站点 第七章 如何解决内存的问题(前中篇)—托管资源优化—监测CLR性能

    原文:[原创]构建高性能ASP.NET站点 第七章 如何解决内存的问题(前中篇)-托管资源优化-监测CLR性能 构建高性能ASP.NET站点 第七章 如何解决内存的问题(前中篇)—托管资源优化—监测C ...

  2. mysql_install_db出错,Unable to lock /usr/local/mysql/var/ibdata1, error: 11

    今天,在一台旧机器上编译一个新的Mysql,install时出了错: /usr/local/mysql_5615/scripts/mysql_install_db --user=mysql --bas ...

  3. JAVA学习课第五十八届 — GUI

    GUI Graghical User Interface(图形用户接口) java为GUI提供的对象都存在java.awt和java.swing包中 Java的GUI做的的确干只是C++等.不打算浪费 ...

  4. VS2012 安装出错 :通道正在关闭

    从微软官网下的安装包iso,解压后安装时总是出现 3个错误,提示什么管道正在关闭,看了很多解决办法,挑了一个简单的:安装包有问题,重新下载一个,就好了(持续更新....)

  5. SQL Server中tempdb的管理

    原文:SQL Server中tempdb的管理 资料来自: http://blogs.msdn.com/b/sqlserverstorageengine/archive/tags/tempdb/ ht ...

  6. SSH深度历险记(八) 剖析SSH核心原则+Spring依赖注入的三种方式

           于java发育.一类程序猿必须依靠类的其他方法,它是通常new依赖类的方法,然后调用类的实例,这样的发展问题new良好的班统一管理的例子.spring提出了依赖注入的思想,即依赖类不由程 ...

  7. TCP/IP、Http、Socket的差别

    网络由下往上分为 物理层.数据链路层.网络层.传输层.会话层.表示层和应用层. 通过初步的了解,我知道IP协议相应于网络层,TCP协议相应于传输层,而HTTP协议相应于应用层, 三者从本质上来说没有可 ...

  8. HDU 1711 Number Sequence(kmp)

    Problem Description Given two sequences of numbers : a[1], a[2], ...... , a[N], and b[1], b[2], .... ...

  9. Codeforces Round #243 (Div. 2) Problem B - Sereja and Mirroring 解读

    http://codeforces.com/contest/426/problem/B 对称标题的意思大概是.应当指出的,当线数为奇数时,答案是线路本身的数 #include<iostream& ...

  10. 结构的具体说明sublime text 2/3的Golang开发环境

    1.下载并安装sublime text 2/3 官网下载:http://www.sublimetext.com/ 2.安装成功sublime text后.启动sublime text.选择菜单栏&qu ...