Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
09-10-2004, 08:45 AM
|
#1
|
LQ Newbie
Registered: Jul 2004
Posts: 13
Rep:
|
using tar
hi, i tried to using tar to create aa archive, i succeed but now having problem to restore it
i used tar to create an archive for my floppy disk, as below
tar -cvf files.tar /mnt/floppy/files
then i delete all the things in floppy
then when i used this command to restore,
tar -xvf /mnt/floppy files.tar
it stated that floppy is a directory, an error found
then it quits
what should i do to restore the data to the floppy using tar?
|
|
|
09-10-2004, 08:58 AM
|
#2
|
Moderator
Registered: Aug 2002
Posts: 26,862
|
The correct syntax is:
tar -xvf files.tar /mnt/floppy/
|
|
|
09-10-2004, 09:52 AM
|
#3
|
Member
Registered: Apr 2003
Location: Buenos Aires, Argentina
Distribution: Slackware, Gentoo
Posts: 397
Rep:
|
No, that returns an error.
The correct syntax would be this:
tar -xvf files.tar -C /mnt/floppy/
|
|
|
09-10-2004, 10:08 AM
|
#4
|
LQ Newbie
Registered: Jul 2004
Posts: 13
Original Poster
Rep:
|
thanks, guys, i will try for the commands..
|
|
|
09-10-2004, 10:15 AM
|
#5
|
Senior Member
Registered: Jul 2004
Distribution: Slackware
Posts: 2,140
|
Or if the create command was this :
tar -cvf files.tar /mnt/floppy/files
you restore files like this (assuming /mnt/floppy is mounted) :
tar xvf files.tar
|
|
|
All times are GMT -5. The time now is 07:36 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|