todo tomorrorw!
在linux下可以通過
mount IOSFILE.iso /media/myiso/ -o loop
這種方式掛載,然后直接從 目錄中拷貝 iso的內容出來就可以。
但是總是不爽啊,在windows下,如果我需要,我可以直接解壓的,winrar,7zip,uiso,等等都可以做到。但是在linux難道就沒有工具可以直接解壓縮iso的嗎?
好吧,p7zip是7-zip的linux版本,地址:http://sourceforge.net/projects/p7zip
下載p7zip_9.20.1_src_all.tar.bz2后
解壓
tar xvf p7zip_9.20.1_src_all.tar.bz2
cd p7zip_9.20.1_src_all
make all3 && make install
就可以了,具體可以查看makefile 里面生成的文件不盡相同。
然后 可以用 p7zip來解壓iso了。
安裝好的p7z在系統中的名字有:
[root@src-server ~]# 7z
7z 7za 7zFM 7zG 7zr
[root@src-server ~]# 7z
解壓iso文件的命令是:
7z x Windows.iso
查看壓縮文件的內容是:
7z l Windows.iso
查看7z的幫助信息:
7z
7z --help
[root@src-server ~]# 7z --help 7-Zip [64] 9.20 Copyright (c) 1999-2010 Igor Pavlov 2010-11-18 p7zip Version 9.20 (locale=en_US.UTF-8,Utf16=on,HugeFiles=on,4 CPUs) Usage: 7z <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 } /*wind -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 -y: assume Yes on all queries
當然這個7z是通吃的,可以解壓所有支持的文件類型,zip rar cab wim ntfs 等等
7z x arcgis10server_win.zip
好了問題解決。用7z 非root用戶可以輕松解壓iso文件。
貌似有libcdio 的庫 好像也可以。
[root@xen1 ~]# iso【Tab查看】 isodebug isohybrid iso-info isosize isodump isoinfo iso-read isovfy [root@xen1 ~]# iso-read iso-read: you need to specify an ISO-9660 image name. iso-read: Use option --image or try --help. [root@xen1 ~]# rpm -qf `which iso-read` libcdio-0.81-3.1.el6.x86_64 [root@xen1 ~]# iso-read --help Usage: iso-read [OPTION...] -d, --debug=INT Set debugging to LEVEL. -i, --image=FILE Read from ISO-9660 image. This option is mandatory -e, --extract=FILE Extract FILE from ISO-9660 image. This option is mandatory. -k, --ignore Ignore read error(s), i.e. keep going --no-header Don't display header and copyright (for regression testing) -o, --output-file=FILE Output file. This option is mandatory. -V, --version display version and copyright information and exit Help options: -?, --help Show this help message --usage Display brief usage message [root@xen1 ~]#