- Community Home
- >
- Storage
- >
- Data Protection and Retention
- >
- StoreEver Tape Storage
- >
- determining free space on tape under Linux
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-12-2005 11:32 PM
тАО09-12-2005 11:32 PM
Does anyone know how to check how much space remains on a tape under Linux?
I'm using an Ultrium 460 SCSI drive with 400GB tapes (at 2:1 compression ratio) - under Fedora Core 3.
The drive uses hardware compression, so I don't know how to figure out how much space is left on the tape after doing a "tar cvf" to it.
I've done a lot of searching on this subject but haven't stumbled across anything yet.
Maybe some kind of magic calculation using block counts?
Any ideas would be most appreciated!
Thanks,
Shaun Malone
www.multimap.com
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-13-2005 01:25 AM
тАО09-13-2005 01:25 AM
Re: determining free space on tape under Linux
I think that the only way is to generate a sort of catalog. Let's say, after the backup you should at least run the tvf to verify if the backup was sucessful, the outpub you can save to a file and sum the bytes for all the files.
There are other ways of course to make the catalog, using find for example before the backup, and using the output as input for the backup command.
Also, you cannot predict how much data will fit in the free space, because the compression ratio is variable.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-13-2005 01:28 AM
тАО09-13-2005 01:28 AM
Re: determining free space on tape under Linux
I know how much data I am putting onto the tape - 70GB uncompressed in this instance - but since the compression is done in hardware I can't tell how much of the tape is actually being used / remains.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-13-2005 02:04 AM
тАО09-13-2005 02:04 AM
Re: determining free space on tape under Linux
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-13-2005 02:14 AM
тАО09-13-2005 02:14 AM
Re: determining free space on tape under Linux
I suppose I could keep doing backups until one fails due to lack of tape space - but that seems a bit messy.
Cheers
Shaun
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-13-2005 07:12 AM
тАО09-13-2005 07:12 AM
Re: determining free space on tape under Linux
But remember that having lots of backups on the same media is not always a good idea, if you loss the media, you loss all your backups.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-13-2005 07:02 PM
тАО09-13-2005 07:02 PM
SolutionIf I understood well, maybe the following will help:
1. make a tar -tvf on the last archive you have on the tape, using non-rewind device (or using the mt command forward the tape to the last eof)
2. using the mt command read the position of tape (this will give you the current block number)
3.if you know the capacity of tape then you'll now how much space is left on the tape (last - current block number)
I have no much experience with tape on linux, but above work on tru64.
I think that on linux you will use mt command with eod and tell subcommands.
However even if you know how much space left on tape , this is just to estimate how much data you can put. This because, as said before, the compression is variable.
Regards,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-13-2005 08:58 PM
тАО09-13-2005 08:58 PM
Re: determining free space on tape under Linux
Another way is to use HP Library and Tape Tools (LTT) though it only officially supports Red Hat at the moment (SuSE coming soon). With LTT you can pull the logs from the drive and see; (a) how much space is left on tape and (b) what your recent compression ratio has been. This works best if you pull the logs immediately after the backup.
The logs are best in the HP Ultrium drives which is what you've got so that should be OK.
You can find LTT at www.hp.com/support/tapetools. Select 'support' and 'view support ticket'. Fingers crossed it works for your version of Linux.
If you need help running it then please let me know. There is help on the web.
In future (next few months) LTT will support SuSE and also have clearer log decode for exactly this purpose.
Richard.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-13-2005 09:47 PM
тАО09-13-2005 09:47 PM
Re: determining free space on tape under Linux
mt -f
mt -f
mt -f status
mt -f
mt -f
mt -f status
from a newly loaded tape until the fsf fails.
Otherwise, there's no way to do this. 2:1 is just the average compression ratio that you'll get, but I've seen over 1000:1 on empty databases and about 1.05:1 on compressed graphics files, so it depends on the type of data that you're putting into the backup.
However, with compression, looking at the amount of free space on tape is fairly arbitrary anyway. With an unknown compression ratio, it's near impossible to tell whether the next lot of data will fit onto a tape unless it'll fit uncompressed.
Cheers,
Stuart.