ITPub博客

首页 > Linux操作系统 > Linux操作系统 > Linux下使用unrar解压RAR包

Linux下使用unrar解压RAR包

Linux操作系统 作者:minxuan2013 时间:2014-12-30 13:43:19 0 删除 编辑

一.下载地址:
http://www.rpmfind.net/linux/rpm2html/search.php?query=unrar

二.安装:

[root@centos sybaseiq]# cat /etc/redhat-release
CentOS release 5.4 (Final)
[root@centos sybaseiq]# uname -r
2.6.18-164.el5
[root@centos sybaseiq]# rpm -ivh unrar-3.9.4-1.el5.rf.i386.rpm

三.帮助:
[root@centos lib]# unrar

UNRAR 3.90 beta 3 freeware      Copyright (c) 1993-2009 Alexander Roshal

Usage:     unrar - -
               <@listfiles...>


  e             Extract files to current directory
  l[t,b]        List archive [technical, bare]
  p             Print file to stdout
  t             Test archive files
  v[t,b]        Verbosely list archive [technical,bare]
  x             Extract files with full path


  -             Stop switches scanning
  ad            Append archive name to destination path
  ai            Ignore file attributes
  ap      Set path inside archive
  c-            Disable comments show
  cfg-          Disable read configuration
  cl            Convert names to lower case
  cu            Convert names to upper case
  dh            Open shared files
  ep            Exclude paths from names
  ep3           Expand paths to full including the drive letter
  f             Freshen files
  id[c,d,p,q]   Disable messages
  ierr          Send all messages to stderr
  inul          Disable all messages
  kb            Keep broken extracted files
  n       Include only specified file
  n@            Read file names to include from stdin
 
n@>      Include files listed in specified list file
  o[+|-]        Set the overwrite mode
  or            Rename files automatically
  ow            Save or restore file owner and group
  p[password]   Set password
  p-            Do not query password
  r             Recurse subdirectories
  sl      Process files with size less than specified
  sm      Process files with size more than specified
  ta      Process files modified after in YYYYMMDDHHMMSS format
  tb      Process files modified before in YYYYMMDDHHMMSS format
  tn
  to
  ts[N]  Save or restore file time (modification, creation, access)
  u             Update files
  v             List all volumes
  ver[n]        File version control
  vp            Pause before each volume
  x       Exclude specified file
  x@            Read file names to exclude from stdin
 
x@>      Exclude files listed in specified list file
  y             Assume Yes on all queries

四.例子:

1.查看rar包中的内容:
#unrar l *.rar
或者
#unrar v *.rar

2.测试rar包是否能解压成功:
#unrar t *.rar

3.解压到当前文件夹:
#unrar e *.rar

4.解压到指定文件夹:
#unrar x *.rar /tmp

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/29615408/viewspace-1384939/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2014-12-30

  • 博文量
    112
  • 访问量
    95870