dump_tape crashes

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

dump_tape crashes

rohr22
Hi, Mark.

On our RHEL 7.9 x86_64 system, and other RHEL 7.x systems I have tested on, the dump_tape tool crashes. I ran the tool like this:

# dump_tape -f F01030L5
crc32c using Intel sse4.2 hardware optimization
Media density code: 0x58
Media type code   : 0x0b
Media description : Ultrium 5/16T
Tape Capacity     : 53687091200 (50 GBytes)
Media type        : Normal data
Media             : read-write
Remaining Tape Capacity : 53687091147 (49 GBytes)
Total num of filemarks: 1
Segmentation fault (core dumped)

I ran gdb on the resulting core dump file and it shows:
Core was generated by `dump_tape -f F01030L5'.
Program terminated with signal 11, Segmentation fault.
#0  0x00000000004012af in main (argc=<optimized out>, argv=<optimized out>)
    at dump_tape.c:559
559 while (c_pos->blk_type != B_EOD) {

(gdb) l
554 if (verbose) {
555 printf("Dumping filemark meta info\n");
556 print_metadata();
557 }
558
559 while (c_pos->blk_type != B_EOD) {
560 print_raw_header();
561 if (dump_data) {
562 read_data(&sam_stat);
563 }

I don't think this issue occurs on RHEL 8. I am using the latest mhvtl version as of this writing.
Reply | Threaded
Open this post in threaded view
|

Re: dump_tape crashes

Mark Harvey
Administrator
Can I obtain the index & meta files from the F01030L5 please ?

I'll spin up a CentOS7 and test as well.

Thanks for the bug report.
Regards from Australia
Mark Harvey
Reply | Threaded
Open this post in threaded view
|

Re: dump_tape crashes

rohr22
This post was updated on .
F01050L5.gz


Hi, Mark. The problem happens when using the dump_tape command on any of the mhvtl tape volumes, even ones that we haven't written to. I attached the index and meta files from an empty one (F01050L5) that just had these files:

# ls -l F01050L5/
total 12
-rw-r----- 1 root root   53 Sep 23  2020 data
-rw-r----- 1 root root 1024 Sep 23  2020 indx
-rw-r----- 1 root root 1540 Apr  7 03:38 meta

# dump_tape -f F01050L5
Media density code: 0x58
Media type code   : 0x0b
Media description : Ultrium 5/16T
Tape Capacity     : 53687091200 (50 GBytes)
Media type        : Normal data
Media             : read-write
Remaining Tape Capacity : 53687091147 (49 GBytes)
Total num of filemarks: 1
Segmentation fault (core dumped)

The contents of our /etc/mhvtl/mhvtl.conf file are:
# cat /etc/mhvtl/mhvtl.conf
#
# mhvtl.conf
#

# Home directory for tape emulation files
MHVTL_HOME_PATH=/opt/vtl

# Default media capacity (50 GB)
CAPACITY=51200

# Set default verbosity [0|1|2|3]
VERBOSE=3

# Set kernel module debugging [0|1]
VTL_DEBUG=0

# vtltape and vtllibrary debugging [Blank or -d]
#DAEMON_DEBUG=-d

Thank you,
Peter
Reply | Threaded
Open this post in threaded view
|

Re: dump_tape crashes

Mark Harvey
Administrator
In reply to this post by rohr22
I've pushed out a fix for this.

A fix was provided via GitHub - issue is due to global / local variable name conflict.
Regards from Australia
Mark Harvey