Solved

Tape backup - Ubuntu linux - HP 72GB internal USB DAT - ML350g6

Posted on 2011-03-08
16
1,261 Views
Last Modified: 2012-06-21
Hi,
I'm having problem with tape backup. When I try " tar -czf /dev/st0 $SOURCE_DIRS", I get error: /bin/tar: /dev/st0: Cannot write: Input/output error.

mt -f /dev/st0 status
 returns:
SCSI 2 tape drive:
File number=-1, block number=-1, partition=0.
Tape block size 0 bytes. Density code 0x0 (default).
Soft error count since last status=0
General status bits on (50000):
 DR_OPEN IM_REP_EN

mt status returns:
  /dev/tape: Inappropriate ioctl for device
Which sounds bad.

My stinit.def:
manufacturer=HP model ="C7438A" {
can-bsr can-partitions auto-lock
mode1 blocksize=0 compression=1
mode2 blocksize=1024 compression=1
mode3 blocksize=0 compression=0
mode4 blocksize = 1024 compression=0 }

Any Ideas how to proceed?
0
Comment
Question by:veli-pekka
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 9
  • 6
16 Comments
 
LVL 9

Expert Comment

by:svs
ID: 35068623
DR_OPEN means there's no tape in the drive.
0
 
LVL 31

Expert Comment

by:farzanj
ID: 35068637
Also do this:
 
mt -f /dev/st0 rewind

Open in new window

0
 

Author Comment

by:veli-pekka
ID: 35071203
Ok, new 'mt -f /dev/st0 status', this time with tape loaded:

SCSI 2 tape drive:
File number=0, block number=0, partition=0.
Tape block size 0 bytes. Density code 0x47 (DDS-5 or TR-5).
Soft error count since last status=0
General status bits on (41010000):
 BOT ONLINE IM_REP_EN

I did rewind, but it didn't help (I didn't get any errors).
0
NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

 
LVL 31

Expert Comment

by:farzanj
ID: 35071330
So can you run your tar command now?
0
 

Author Comment

by:veli-pekka
ID: 35071399
No I can't.
0
 
LVL 31

Expert Comment

by:farzanj
ID: 35071470
Is $SOURCE_DIRS properly set with complete path?  What error message do you get when you try to run it?
0
 

Author Comment

by:veli-pekka
ID: 35071642
Yes it is. I have also tried with single folder. Error message is:
 /bin/tar: /dev/st0: Cannot write: Input/output error.

If I try for example:
 dd if=/dev/zero of=/dev/st0
I get the same "Cannot write: Input/output error"

0
 
LVL 31

Expert Comment

by:farzanj
ID: 35072051
Ok, first try setting the block size and then retry the dd command
mt -f /dev/nst0 setblk 0

Open in new window

0
 

Author Comment

by:veli-pekka
ID: 35086089
I will continue with this on Friday.
0
 

Author Comment

by:veli-pekka
ID: 35106597
Still no success:
  sudo mt -f /dev/st0 setblk 0
  sudo dd if=/dev/zero of=/dev/st0
dd: writing to 'dev/st0': Input/output error
dd: closing output file '/dev/st0': Input/output error
0
 

Author Comment

by:veli-pekka
ID: 35107400

dmesg
[ 6153.745797] st0: Add. Sense: Write error
[ 6153.745801] st0: Error on write filemark.
0
 
LVL 31

Accepted Solution

by:
farzanj earned 500 total points
ID: 35108197
You need to check your driver.  Appears to me that your driver for the tape is not installed or not functioning
0
 

Author Comment

by:veli-pekka
ID: 35108744
Hi,

I checked the drivers and they should be fine (output was similar to this, I'm not at the server right now):
      lsmod | grep usb_storage
      usb_storage 61193 0

      lsmod | grep st
      st 35933 0

Should I check something else as well?
0
 

Author Comment

by:veli-pekka
ID: 35193955
The problem was faulty drive.
0
 
LVL 31

Expert Comment

by:farzanj
ID: 35193969
So my comment 35108197 was close
0
 

Author Closing Comment

by:veli-pekka
ID: 35339492
The drive itself wasn't functioning
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Moving your enterprise fax infrastructure from in-house fax machines and servers to the cloud makes sense — from both an efficiency and productivity standpoint. But does migrating to a cloud fax solution mean you will no longer be able to send or re…
Many businesses neglect disaster recovery and treat it as an after-thought. I can tell you first hand that data will be lost, hard drives die, servers will be hacked, and careless (or malicious) employees can ruin your data.
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
This tutorial will walk an individual through the process of installing the necessary services and then configuring a Windows Server 2012 system as an iSCSI target. To install the necessary roles, go to Server Manager, and select Add Roles and Featu…

717 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question