有朋友问tar 的时候报错,原因可能是tar不能处理长文件名或长目录
建议用cpio
[@more@]错误信息:
tar: 0511-190 File name remove_bak/qyhy/zhwl/qyhy/tgzn/ywlc/xywp/tgzn/tgzn/dmcx/tgzn/fgcx/tgzn/146zcfg/147tjjyjyj/tgzn/146zcfg/150tjbj/tgzn/146zcfg/199tjhg/tgzn/146zcfg/149tjszf/tgzn/146zcfg/151tjhsj/tgzn/146zcfg/tgzn/zyxz/bgxz/tgzn/zyxz/tgzn/zyxz/rjxz/tgzn/zxxz/tgzn/zxxz/ggb/zhxw/kadt/bgtj/kadt/kadt/gktt/kadt/myje/kadt/wztj/kadt/qttj/kadt/cbtj/dzsw/bsqc1/dzsw/dzsw/bsqc2/BMW730LI/dzsw/bsqc2/dzsw/b
说明:
When specifying path names that are greater than 100 characters for the United States Tape Archiver (USTAR) format, remember that the path name is composed of a prefix buffer, a / (slash), and a name buffer.
The prefix buffer can be a maximum of 155 bytes and the name buffer can hold a maximum of 100 bytes. If the path name cannot be split into these two parts by a slash, it cannot be archived. This limitation is due to the structure of the tar archive headers, and must be maintained for compliance with standards and backwards compatibility. In addition, the length of a destination for a hard or symbolic link ( the 'link name') cannot exceed 100 bytes.
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/7318139/viewspace-963875/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/7318139/viewspace-963875/