cccicl
cccicl
发布于 2个月前

linux下rar包的解压方法

一.widonds下打包rar文件并上传

yum install lrzsz

rz test.rar

<a href="" target="_blank">二、下载并安装rar软件</a>

1.下载:根据主机系统下载合适的版本,当前64为centos系统演示下载:

wget http://www.rarlab.com/rar/rarlinux-x64-5.3.0.tar.gz

2.解压安装

tar xvf rarlinux-x64-5.3.0.tar.gz

cd rar

make install

OK!

压缩一个文件:

rar a -r yii-basic-2.0.15.rar yii-basic-2.0.15

2.1 下载( 版本较低,可能不支持windows压缩rar)

mkdir -p /home/oldboy/tools

cd /home/oldboy/tools

wget http://www.rarlab.com/rar/rarlinux-3.8.0.tar.gz

2.2 安装

tar zxvf rarlinux-3.8.0.tar.gz

cd rar

make

make install

三、rar命令语法

将/etc 目录压缩为etc.rar 命令为:

rar a etc.rar /etc

将etc.rar 解压 命令为:

rar x etc.rar

unrar -e etc.tar

四、具体例子

实例:将/etc 目录压缩为etc.rar

[root@yonggetools]# rar a etc.rar /etc

将etc.rar 解压:

[root@yonggetools]# rar x etc.rar

RAR 3.80 Copyright (c) 1993-2008 Alexander Roshal 16 Sep 2008


[root@localhost www]# cd /usr/etc

[root@localhost etc]# ll

[root@localhost etc]# mkdir tools

[root@localhost etc]# ll

drwxr-xr-x 2 root root 6 Oct 22 21:12 tools

[root@localhost etc]# cd tools

[root@localhost tools]# wget http://www.rarlab.com/rar/rarlinux-3.8.0.tar.gz

[root@localhost tools]# tar zxvf rarlinux-3.8.0.tar.gz

[root@localhost tools]# cd rar

[root@localhost rar]# make && make install

[root@localhost rar]# cd /www

[root@localhost www]# ll

[root@localhost www]# rar x Novel.rar

-bash: /usr/local/bin/rar: /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory

©2020 edoou.com   京ICP备16001874号-3