-f freshen existing files, create none -t test compressed archive data -u update files, create if necessary -z display archive comment only -v list verbosely/show version info -T timestamp archive to latest -x exclude files that follow (in xlist) -d extract files into exdir modifiers: -n...
-f freshen existing files, create none -t test compressed archive data -u update files, create if necessary -z display archive comment only -v list verbosely/show version info -T timestamp archive to latest -x exclude files that follow (in xlist) -d extract files into exdir modifiers: -n...
-A, --catenate, --concatenate append tar files to an archive -c, --create create anewarchive-d, --diff, --compare find differences between archive and file system --delete delete from thearchive(not on mag tapes!)-r, --append append files to the end of an archive -t, --list list...
Delete from the archive. The arguments supply names of the archive members to be removed. At least one argument must be given. This option does not operate on compressed archives. There is no short option equivalent. -r, --append Append files to the end of an archive. Arguments have the ...
create a new archive. 即,指定创建一个新的归档文件,而不是从归档文件中提取文件。 -r, --append append files to the end of an archive. 即,往已有的归档文件中追加写入新的文件。 -t, --list list the contents of an archive. 即,不用解开归档文件,就能列出归档文件里面打包的文件信息 ...
tar -rvf /backup/config-backup/myarchive.tar myfile mydir myfile mydir Make a Note:You won’t be able to append files or directory to an archive file with compressed by‘gzip’or‘bzip2’. If you try, you will end up with below error messages. ...
Check the directory contents to confirm the operation works correctly. 3. Extract from Archive Extracting from an archive or compressed archive uses the-xor--extractoperation withtar. The additional options depend on the file type and where tar should extract the components. ...
-f- Name the archive -z- Compressed gzip archive file How to exclude files when creating a tar backup In this example, we create agzipbackup calledbackup.tar.gz, but exclude the files namedfile.txtandfile.shby using the--exclude [filename]option. ...
上述选项,对.tar.gz使用时会报错比如: tar rzv -f zipfile.tar.gz new-file tar: Cannot update compressed archives 相关截图 已经尝试哪些方法仍然没有解决(附上相关链接) Google了 append file to .tar.gz append file to .gz append dir to .tar.gz 附:不成熟的吐槽 Linux是不是把事情搞复杂了? 还...
archive.tar.gz:gzip compressed data,from Unix,original size modulo2^3210240$ 4、解压所有文件 使用该x选项可以简单地提取 tar 存档(无论是压缩的还是未压缩的),下面的例子将阐明它的用法: 代码语言:javascript 复制 $ tar xvf archive.tar file1.txt ...