LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices


Reply
  Search this Thread
Old 11-01-2006, 03:53 PM   #1
kaplan71
Member
 
Registered: Nov 2003
Posts: 809

Rep: Reputation: 39
Tar error: cannot write: invalid argument


I am trying to do a tar backup to a locally attached tape drive. The tape drive is attached via an Adaptec 2930 SCSI card, and is a DAT drive with the SCSI ID 3. The device file that I am using is /dev/st0.

Whenever I try to do a backup I use the following syntax:

# tar -cvf /dev/st0 /tmp <directory>

The error message I am getting is the following:

tar: /dev/st0: Cannot write: Invalid argument
tar: Error is not recoverable: exiting now.

The operating system is Fedora Core 5, and the version of tar is GNU tar 1.15.1.
 
Old 11-01-2006, 04:18 PM   #2
stress_junkie
Senior Member
 
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873

Rep: Reputation: 335Reputation: 335Reputation: 335Reputation: 335
Quote:
Originally Posted by kaplan71
# tar -cvf /dev/st0 /tmp <directory>
You have too many parameters. Remove /tmp and see what happens.

Last edited by stress_junkie; 11-01-2006 at 09:10 PM.
 
Old 11-02-2006, 07:14 AM   #3
kaplan71
Member
 
Registered: Nov 2003
Posts: 809

Original Poster
Rep: Reputation: 39
When I run the command tar -cvf /dev/st0 the error message I get is the following:

tar: Cowardly refusing to create an empty archive.
 
Old 11-02-2006, 10:37 AM   #4
stress_junkie
Senior Member
 
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873

Rep: Reputation: 335Reputation: 335Reputation: 335Reputation: 335
Well now you don't have enough parameters. Apparently you removed both the /tmp and the <directory>. Here is an example to back up the /home directory tree to /dev/st0.
Code:
tar -cvf /dev/st0 /home
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Invalid argument runtime error on sendmsg(). JohnHubert Linux - Networking 3 08-30-2010 09:44 AM
Invalid Argument Error ahmedb72 Red Hat 1 02-25-2006 07:52 AM
C(sockets): 'Invalid argument' error when using MSG_OOB elluva Programming 6 06-08-2005 09:16 AM
installation Error mounting sda1: Invalid Argument sadirmata Linux - Software 4 01-31-2002 10:37 AM
installation error: Error mounting sda1: Invalid Argument sadirmata Linux - Newbie 1 01-29-2002 02:28 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat

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

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration