regarding backup script
i prepared a script to backup a files and directories for a user. It works well. But it displays the following message while running.
tar: removing leading / names Is it really a error message ? I run the following bash script from root user. #! /bin/bash clear tar -uf /backup/a.tar $HOME bzip2 -f /backup/a.tar |
The ultimate answer is to untar the file and see if everything untars and md5sums okay. However I think it's just stripping the leading "/" from filenames, but I'm not sure. FYI, I think you can use bzip2 as an ption to tar, like tar -j (if you don't want two separate commands).
|
Not really an error, it is just telling you that it is removing the leading / from your directory when it stores it in the tar file. For example the path for /home/scooby/file.txt would be stored as home/scooby/file.txt. If you want to keep absolute names use the -P option. While you can use the -j option to create (-cjf) a bzipped tar file you cannot update (-uf) a compressed tar file.
Bill |
All times are GMT -5. The time now is 02:03 AM. |