`cta-tape-label` should have clearer errors
This is the log output we were seeing cta-tape-label
on the failing CI jobs:
Oct 7 13:55:30.095091 tpsrv01 cta-tape-label: LVL="ERROR" PID="347" TID="347" MSG="Label session failed to label the tape" userName="UNKNOWN" tapeVid="V06001" tapeOldLabel="" force="false" tapeLoadTimeout="7200" tapeLabelError="[TapeLabelCmd::checkTapeLabel] - Reading VOL1: Failed ST read in DriveGeneric::readExactBlock Errno=12: Cannot allocate memory"
As discussed in today's dev meeting this message is not so clear for newcomers: we were looking for possible SCSI errors.
Designs
- Show closed items
Activity
-
Newest first Oldest first
-
Show all activity Show comments only Show history only
- Julien Leduc assigned to @vlado
assigned to @vlado
- Contributor
This is the repository with the OSM tape https://gitlab.desy.de/mwai.karimi/osm-mhvtl/
- Owner
I was able to reproduce this easily:
- First of all I labeled our normal tape as a test - no problem:
[INFO] [main] executing command: /usr/bin/cta-tape-label --vid L77744 --debug [INFO] [<lambda>] Oct 10 16:29:53.953047 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session started" userName="vlado" tapeVid="L77744" tapeOldLabel="" force="false" tapeLoadTimeout="7200" [INFO] [<lambda>] Oct 10 16:29:53.953465 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Unit name not specified, choosing first line of TPCONFIG" [INFO] [<lambda>] Oct 10 16:29:53.953920 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session read configuration" catalogueDbType="DBTYPE_ORACLE" catalogueDatabase="cta" catalogueUsername="cta_production" devFilename="/dev/nst0" rawLibrarySlot="smc29" logicalLibrary="IBM1L8" unitName="I1L80942" [INFO] [<lambda>] Oct 10 16:29:53.954019 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session set process capabilities" capabilities="cap_sys_rawio+ep" [INFO] [<lambda>] Oct 10 16:29:54.030740 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session mounting tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="false" [INFO] [<lambda>] Oct 10 16:30:10.272717 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session mounted tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="false" [INFO] [<lambda>] Oct 10 16:30:10.272828 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session loading tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" [INFO] [<lambda>] Oct 10 16:30:17.125689 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session loaded tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" [INFO] [<lambda>] Oct 10 16:30:17.125788 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session rewinding tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" [INFO] [<lambda>] Oct 10 16:30:19.387618 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session successfully rewound tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" [INFO] [<lambda>] Oct 10 16:30:22.347636 tpsrv313.cern.ch cta-tape-label: LVL="WARN" PID="2244" TID="2244" MSG="Label a non-empty tape without the oldLabel option" userName="vlado" tapeVid="L77744" tapeOldLabel="" force="false" tapeLoadTimeout="7200" [INFO] [<lambda>] Oct 10 16:30:22.347765 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session checking non empty tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" [INFO] [<lambda>] Oct 10 16:30:22.465676 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session enabling LBP on drive" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" [INFO] [<lambda>] Oct 10 16:30:22.511379 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session successfully checked non empty tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" tapeLabel="L77744" [INFO] [<lambda>] Oct 10 16:30:22.513347 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session enabling LBP on drive" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" [INFO] [<lambda>] Oct 10 16:30:22.513475 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session is writing label with LBP to tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" [INFO] [<lambda>] Oct 10 16:30:27.714758 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session has written label with LBP to tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" [INFO] [<lambda>] Oct 10 16:30:27.714888 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session unloading tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="false" [INFO] [<lambda>] Oct 10 16:30:56.842409 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session unloaded tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="false" [INFO] [<lambda>] Oct 10 16:30:56.842536 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session dismounting tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="false" [INFO] [<lambda>] Oct 10 16:31:06.503631 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2244" TID="2244" MSG="Label session dismounted tape" userName="vlado" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="false" [INFO] [<lambda>] 2022-10-10 16:31:07 [INFO] [main] labeled tape L77744
- Then I downloaded
L1
file from the above mentioned website:
[root@tpsrv313 ~]# ls -la /tmp/L1 -rw-r--r--. 1 root root 32772 okt 10 16:26 /tmp/L1
- I mounted the above mentioned test tape and re-wrote the label on it using
dd
:
[root@tpsrv313 ~]# mt rewind [root@tpsrv313 ~]# dd if=/tmp/L1 of=/dev/nst0 64+1 záznamov prečítaných 64+1 záznamov zapísaných 32772 skopírovaných bajtov (33 kB), 3,37447 s, 9,7 kB/s
- Then I dismounted the tape and launched
cta-tape-label
. It failed with the above mentioned errorReading VOL1: Failed ST read in DriveGeneric::readExactBlock Errno=12: Cannot allocate memory
:
[root@tpsrv313 ~]# /usr/bin/cta-tape-label --vid L77744 --debug Oct 10 16:34:05.162393 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session started" userName="root" tapeVid="L77744" tapeOldLabel="" force="false" tapeLoadTimeout="7200" Oct 10 16:34:05.162925 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Unit name not specified, choosing first line of TPCONFIG" Oct 10 16:34:05.163341 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session read configuration" catalogueDbType="DBTYPE_ORACLE" catalogueDatabase="cta" catalogueUsername="cta_production" devFilename="/dev/nst0" rawLibrarySlot="smc29" logicalLibrary="IBM1L8" unitName="I1L80942" Oct 10 16:34:05.163446 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session set process capabilities" capabilities="cap_sys_rawio+ep" Oct 10 16:34:05.234286 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session mounting tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="false" Oct 10 16:34:16.557771 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session mounted tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="false" Oct 10 16:34:16.557900 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session loading tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" Oct 10 16:34:23.411519 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session loaded tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" Oct 10 16:34:23.411641 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session rewinding tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" Oct 10 16:34:25.657193 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session successfully rewound tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" Oct 10 16:34:29.676364 tpsrv313.cern.ch cta-tape-label: LVL="WARN" PID="2585" TID="2585" MSG="Label a non-empty tape without the oldLabel option" userName="root" tapeVid="L77744" tapeOldLabel="" force="false" tapeLoadTimeout="7200" Oct 10 16:34:29.676483 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session checking non empty tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="false" Oct 10 16:34:29.745604 tpsrv313.cern.ch cta-tape-label: LVL="ERROR" PID="2585" TID="2585" MSG="Label session failed to label the tape" userName="root" tapeVid="L77744" tapeOldLabel="" force="false" tapeLoadTimeout="7200" tapeLabelError="[TapeLabelCmd::checkTapeLabel] - Reading VOL1: Failed ST read in DriveGeneric::readExactBlock Errno=12: Cannot allocate memory" Oct 10 16:34:29.745714 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session unloading tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="false" Oct 10 16:34:58.274112 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session unloaded tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="false" Oct 10 16:34:58.274290 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session dismounting tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="false" Oct 10 16:35:07.678602 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2585" TID="2585" MSG="Label session dismounted tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="false"
- When using the
--force
option, the tape was labeled successfuly:
[root@tpsrv313 ~]# /usr/bin/cta-tape-label --vid L77744 --debug --force Oct 10 16:41:19.715340 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session started" userName="root" tapeVid="L77744" tapeOldLabel="" force="true" tapeLoadTimeout="7200" Oct 10 16:41:19.716071 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Unit name not specified, choosing first line of TPCONFIG" Oct 10 16:41:19.716496 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session read configuration" catalogueDbType="DBTYPE_ORACLE" catalogueDatabase="cta" catalogueUsername="cta_production" devFilename="/dev/nst0" rawLibrarySlot="smc29" logicalLibrary="IBM1L8" unitName="I1L80942" Oct 10 16:41:19.716622 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session set process capabilities" capabilities="cap_sys_rawio+ep" Oct 10 16:41:19.788115 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session mounting tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="true" Oct 10 16:41:34.784446 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session mounted tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="true" Oct 10 16:41:34.784573 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session loading tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="true" Oct 10 16:41:41.652363 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session loaded tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="true" Oct 10 16:41:41.652475 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session rewinding tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="true" Oct 10 16:41:43.872627 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session successfully rewound tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="true" Oct 10 16:41:47.884657 tpsrv313.cern.ch cta-tape-label: LVL="WARN" PID="2833" TID="2833" MSG="Label a non-empty tape with force option" userName="root" tapeVid="L77744" tapeOldLabel="" force="true" tapeLoadTimeout="7200" Oct 10 16:41:47.886634 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session enabling LBP on drive" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="true" Oct 10 16:41:47.886727 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session is writing label with LBP to tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="true" Oct 10 16:41:51.092220 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session has written label with LBP to tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" force="true" Oct 10 16:41:51.092355 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session unloading tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="true" Oct 10 16:42:19.782662 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session unloaded tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="true" Oct 10 16:42:19.782811 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session dismounting tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="true" Oct 10 16:42:26.933998 tpsrv313.cern.ch cta-tape-label: LVL="INFO" PID="2833" TID="2833" MSG="Label session dismounted tape" userName="root" tapeVid="L77744" tapeOldLabel="" tapeDrive="I1L80942" logicalLibrary="IBM1L8" useLbp="true" driveSupportLbp="true" librarySlot="smc29" force="true"
Edited by Vladimir Bahyl - Owner
Conclusion:
When
/usr/bin/cta-tape-label
tries to read the old label, but it can not because it is not in the CTA/CASTOR format (the file is larger than expected 3 x 80 bytes), then the program should just say:Unable to read old tape label, it is not in the CTA/CASTOR format.
or something like that.
Edited by Vladimir Bahyl 2 - Joao Afonso assigned to @afonso
assigned to @afonso
- Joao Afonso added 1 deleted label
added 1 deleted label
- Owner
This error is actually returned by the SCSI kernel driver itself. We can trigger the same error in the command line by mounting the tape and writing:
[root@tpsrv314 ~]# mt rewind [root@tpsrv314 ~]# dd if=/dev/nst0 bs=80 count=1 dd: error reading '/dev/nst0': Cannot allocate memory 0+0 records in 0+0 records out 0 bytes (0 B) copied, 0.00778685 s, 0.0 kB/s
This prints the following error in
/var/log/messages
:Jan 11 17:39:32 tpsrv314.cern.ch kernel: [7954515.287353] st 2:0:0:0: [st0] Failed to read 512 byte block with 80 byte transfer.
It happens because the first block of the OSM tape is of 512 bytes instead of 80 bytes. Even though the
::read(...)
function is passed the max size80
of the buffer (DriveGeneric.cpp#L1315), it still returns an error (ENOMEM
) if this value is not enough to accommodate the tape block size (512
for this OSM tape). This is a different behaviour compared toMHVTL
.
To conclude this mean this error message is not caused by a wrong label format, but by a mismatched block size.
Edited by Joao Afonso Collapse replies - Owner
I think we could do one of two approaches:
- When the error is
ENOMEM
, have an error message similar to what @vlado suggested, such as:
Unable to read tape label due to 'Cannot allocate memory' system error. Tape may not be in the CTA/CASTOR format.
In this case, the operator know it can use
--force
.- Adapt
/usr/bin/cta-tape-label
code so that it recognises different tape formats. This requires a bit extra of work, but should be safer.
Edited by Joao Afonso - When the error is
- Owner
I discussed with @jcamarer to understand if there is was strong use-case for supporting multiple tape formats in
/usr/bin/cta-tape-label
.For now we agree that modifying the error message should be enough for our current use-cases.
- Joao Afonso created branch
174-cta-tape-label-should-have-clearer-errors
to address this issuecreated branch
174-cta-tape-label-should-have-clearer-errors
to address this issue - Owner
Joao,
I agree, modifying the error message is sufficient. Here is the error message I would suggest:
Unable to read VOL1 tape label due to system error: <Copy of the system error. Example: Cannot allocate memory>. Please check that the VOl1 tape label is in the CTA/CASTOR format.
What do you think?
Edited by Vladimir Bahyl - Joao Afonso mentioned in merge request !145 (merged)
mentioned in merge request !145 (merged)
- Joao Afonso closed with merge request !145 (merged)
closed with merge request !145 (merged)
- Joao Afonso changed milestone to %Release 4.8.5
changed milestone to %Release 4.8.5
- Owner
Joao, I need to reopen this ticket. What I get today is:
Feb 24 13:00:19.014888 tpsrv021.cern.ch cta-tape-label: LVL="ERROR" PID="1372" TID="1372" MSG="Label session failed to label the tape" userName="vlado" tapeVid="I65001" tapeOldLabel="" force="false" tapeLoadTimeout="7200" tapeLabelError="[TapeLabelCmd::checkTapeLabel] - Reading VOL1: Failed ST read in DriveGeneric::readExactBlock. Tape volume label size not be in the CTA/CASTOR format. Errno=12: Cannot allocate memory"
The english:
label size not be in
is confusing. Why didn't you comment on my suggestion above if you didn't like it?Edited by Vladimir Bahyl - Vladimir Bahyl reopened
reopened
- Owner
Hello @vlado ,
Sorry, your previous comment was a few minutes before my merge request closed the ticket, so I did not see it...
Regarding
label size not be in
, it's a typo error. It should be fixed.Anyway, I propose the following message instead:
[TapeLabelCmd::checkTapeLabel] - Reading VOL1: Failed ST read in DriveGeneric::readExactBlock. The buffer length value passed to DriveGeneric::readExactBlock (80 bytes) must match exactly the tape block size. Errno=12: Cannot allocate memory"
Due to the way how the code is written, it's not easy to add the message that you suggested without doing bigger changes to the code.
- Owner
Joao,
thank you for reconsidering fixing this message. Your suggestion is probably fine from the developer perspective, but it is cryptic for operator.
Can you at least add:
Please check that the VOl1 tape label is in the CTA/CASTOR format.
That shouldn't require any big changes, it is just clearer text for the operator.
What do you think?
- Owner
The problem is that the function
DriveGeneric::readExactBlock
(the one that throws this error) is used in many parts of the code and should not care if the block is aVOL1
tape label or any other thing.
The[TapeLabelCmd::checkTapeLabel] - Reading VOL1:
part of the message is just a string it receives from the caller. It can be anything and the method should not check it.I can try to be a bit more specific without mentioning
VOL1
explicitly:[TapeLabelCmd::checkTapeLabel] - Reading VOL1: Failed ST read in DriveGeneric::readExactBlock. Please check the tape format. The buffer length value passed to DriveGeneric::readExactBlock (80 bytes) must match exactly the tape block size. Errno=12: Cannot allocate memory"
Edited by Joao Afonso Collapse replies - Owner
Does this work for you @vlado ?
- Joao Afonso added Tape server label
added Tape server label
- Joao Afonso added prioritylow label
added prioritylow label
- Joao Afonso removed 1 deleted label
removed 1 deleted label