« Return to Thread: How to 'tar" /dev/sdb2 ?

Re: How to 'tar" /dev/sdb2 ?

by James Linder-4 :: Rate this Message:

| View in Thread

Ooops error on tar comand ....

On 28/02/2012, at 9:37 AM, gumstix-users-request@... wrote:

> I am hoping someone out there can help.
> This is probably a really BASIC Linux question so I apologize :-)
>
> I am trying to create a backup of the root file system of my uSD card.
> I tried to "dd" the whole card and it didn't copy all the files properly
> so I am settling for the rootfs partition.
>
> What I want to do is 'tar' all of /dev/sdb2 ...
>
> I tried tar and bzip2. Neither seem to work.
> I tried using the file manager GUI from Ubuntu, but it didn't copy the files
>
> correctly either.
>
> There must be a way to do this?

This is unix stuff, not gumstix but be helped

In general dd is a bad choice. dd makes an exact copy so cloning an exactly-the-same SD card or creating a copy that you can put back etc

tar backs up FILES so eg

mount /dev/sda2 /mnt
ls /mnt # there it all is. Then ...
tar cvjf a-name.tbz /mnt

or as somebody else posted
cd /mnt

then tar cvjf a-name-somewhere-else.tbz *
meaning tar everything HERE to a-name-somewhere-else.tbz

saves all the files in /mnt in a-name.tbz which you cab put back on another file system etc as you will

James
------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
gumstix-users mailing list
gumstix-users@...
https://lists.sourceforge.net/lists/listinfo/gumstix-users

 « Return to Thread: How to 'tar" /dev/sdb2 ?