LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   trying to tar some files (https://www.linuxquestions.org/questions/linux-newbie-8/trying-to-tar-some-files-4175492754/)

jyunker 01-27-2014 10:35 AM

trying to tar some files
 
I am trying to rebuild a database in Centos 6.5, 64 bit version. I found what I think is the way to do it here.

http://unixbhaskar.wordpress.com/201...lcentosfedora/

When I gave it the first command as instructed at the website:

Code:

tar -czvf rpm-1-27-2014.tar.gc rpm
I got the follwing error:

Code:

tar : rpm cannot stat; No such file or directory
tar : Exiting with failure status due to previous errors


Now all I want to do is tar some files what am I doing wrong?

Thanks in advance.

R,

jyunker

netnix99 01-27-2014 10:51 AM

jyunker...

It should be tar -czvf name_of_tar_file.tar file_or_directory_to be tarred

So, if I want to tar the folder /tmp and name it tmp.tar.gz

then the command will be:

Code:

tar -czvf tmp.tar.gz /tmp

jyunker 01-27-2014 11:07 AM

it worked but file changed as we read it
 
I did what you said and it seemed to work. The final command was


tar -czvf rpm-1-27-2014.tar.gx

and it listed its progress:

however it gave this output:

.
.
.
tar: /var.lib/rpm/rpm-1-27-2014.tar.gz: file changed as we readit
var/lib/rpm/Group
/var/librpm/Triggername

I am not sure what "file changed as we read it means".

Thanks in advance.

R,

jyunker

szboardstretcher 01-27-2014 11:18 AM

It means that you are tarring up your tar, which is changing while you are tarring it.


All times are GMT -5. The time now is 08:02 AM.