mhvtl
mhvtl copied to clipboard
Log Sense TAPE_CAPACITY - definition of datasets
This is a bit pedantic and will most likely not influence any backup software you throw at mhVTL. As an FYI..
Log Sense page 0x30 (Tape Usage) has a field called 'volumeDatasetsWritten'. The routine update_tape_usage() puts the number of filemarks minus one in there. This suggests that Datasets stands for the number of application data sections. That's not correct.
Datasets is defined in ECMA319 as "The smallest complete unit of information written to, or received from, the tape" Each dataset is about 400KB in size on LTO-1. So to be a bit more precise that field should contain the bytes written to disk after compression, divided by 400.000.
Feel free to close right away..
Thanks for bug report. Hopefully it’ll be easy to implement ;)
Sent from my iPhone
On 2 Mar 2020, at 08:50, scsirob [email protected] wrote:
This is a bit pedantic and will most likely not influence any backup software you throw at mhVTL. As an FYI..
Log Sense page 0x30 (Tape Usage) has a field called 'volumeDatasetsWritten'. The routine update_tape_usage() puts the number of filemarks minus one in there. This suggests that Datasets stands for the number of application data sections. That's not correct.
Datasets is defined in ECMA319 as "The smallest complete unit of information written to, or received from, the tape" Each dataset is about 400KB in size on LTO-1. So to be a bit more precise that field should contain the bytes written to disk after compression, divided by 400.000.
Feel free to close right away..
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.
static void update_tape_usage(struct TapeUsage *b, struct priv_lu_ssc *lu_ssc) { -uint64_t datasets = filemark_count(); +uint64_t datasets = lu_ssc->bytesWritten_M/400000;
You are welcome ;)
Not quite that simple.. e.g. TS3100 states this contains a 72byte struct
- Minutes of Operation
- Number of Power-ups
- Number of Firmware updates
- Number of Loader moves
- Number of event entries
- Number of Error entries
- Number of Informational entries
- Number of Warning entries
- Number of Configuration Change Entries (All 4 byte unsigned)
Looks like page 0x30 is going to have to be moved into each personality module.
Checking LTO-7 and it is stating:
6.4.17 LP 30h: Tape Usage See LOG SELECT - 4Ch (see 5.2.7 on page 90) and LOG SENSE - 4Dh (see 5.2.8 on page 91) for directions on how to use this page. This page contains non-volatile information relating to volume usage. WARNING WARNING This page has been replaced by the standard log page Volume Statistics log page (17h) (see 6.4.15). This page is included for legacy applications and may become obsolete in future generation drives. WARNING
Well, TS3100 is a library so that's to be expected. In my project I keep separate Log Sense generators for libraries and for tape drives, as pages with the same number have different meanings.
I wouldn't worry about it too much for tape drives. As it's considered an obsolete page and no software actually uses it, it's fine as is.
As for LP 0x17, that is a lot harder to implement if you really want to do it right. It has subpages that keep stats on previous tapes. The partition records change in size depending on the number of partitions on tape, and HP generates different partition records than IBM (both legal).. mhVTL doesn't do partitions (yet), but in my own project I'm having quite a lot of fun with those. If you ever do implement partitions, getting LTFS not to complain about some corner case is quite a challenge.