mhVTL 1.5-4 exporting via FC to a AS400

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

Re: mhVTL 1.5-4 exporting via FC to a AS400

Mark Harvey
Administrator
Good news

I'll check out the current logs and most likely generate a new sg_raw script to run

Sent from my autocorrecting iPhone

On 5 Jul 2016, at 02:44, npf [via mhVTL - A Linux Virtual Tape Library] <[hidden email]> wrote:

Hello,

I do see some great improvements :)

When i was trying to "activate" the drive it would have to wait 5 minutes and eventually i would get

vtl kernel: qla2x00t(9): task abort

Now this doesn't happen anymore. The drive activates immediately and deactivates immediately also.
Nevertheless when i try to format/initialize the tape, the as400 box reports:

"Wrong type of cartridge in device TAP23"

Tried with an emulated LTO3 and LTO4 tape. Please find the logs in http://pastebin.com/GcZrkwMq
Should i do a new test using your sg_raw script?

Thanks for your help.

Best regards,
Nuno Fernandes


To start a new topic under mhVTL - A Linux Virtual Tape Library, email [hidden email]
To unsubscribe from mhVTL - A Linux Virtual Tape Library, click here.
NAML
Regards from Australia
Mark Harvey
npf
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

npf
Hello,

Just an additional information. The log that was pasted is only from the moment i do the inztap (initialize tape) from the as400. If you require previous logs please let me know.

Thanks,
Nuno Fernandes
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

Mark Harvey
Administrator
Any chance of mounting virtual media (working vtl) and providing the output of:
sg_raw -r 1k /dev/sgX 44 01 00 00 00 00 00 10 00 00

where /dev/sgX is the appropriate sg path to the drive.
Regards from Australia
Mark Harvey
npf
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

npf
Hello,

Please find the attached log for the working vtl:

No tape inserted:

# /usr/bin/sg_raw -r 10k /dev/sg1 44 01 00 00 00 00 00 10 00 00
SCSI Status: Check Condition

Sense Information:
 Fixed format, current;  Sense key: Not Ready
 Additional sense: Medium not present

No data received


Insert tape1:

# mtx -f /dev/sg2 load 1
Loading media from Storage Element 1 into drive 0...done

# /usr/bin/sg_raw -r 10k /dev/sg1 44 01 00 00 00 00 00 10 00 00
SCSI Status: Good

Received 56 bytes of data:
 00     00 36 74 53 46 46 a0 00  00 00 31 b5 00 7f 03 80    .6tSFF....1.....
 10     00 0c 35 00 4c 54 4f 2d  43 56 45 20 55 2d 34 31    ..5.LTO-CVE U-41
 20     36 20 20 20 55 6c 74 72  69 75 6d 20 34 2f 31 36    6   Ultrium 4/16
 30     54 20 20 20 20 20 20 20                             T


Here is the mhvtl one (with a tape inserted in the drive):

/usr/bin/sg_raw -r 10k /dev/sg1 44 01 00 00 00 00 00 10 00 00
SCSI Status: Good

Received 56 bytes of data:
 00     00 34 00 00 46 46 a0 00  34 00 00 31 00 00 00 00    .4..FF..4..1....
 10     00 00 00 c3 4c 54 4f 2d  43 56 45 20 55 2d 34 31    ....LTO-CVE U-41
 20     36 20 20 20 55 6c 74 72  69 75 6d 20 34 2f 31 36    6   Ultrium 4/16
 30     54 20 20 20 20 20 20 20                             T


Best regards,
Nuno Fernandes
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

Mark Harvey
Administrator
In reply to this post by npf
FWIW: I have pushed the two earlier patches into the git-hub repository.

There is a new patch which fixes the above mentioned problems with 'REPORT DENSITY' op code.

The patch is also available here:
0004-ssc-Fill-in-Report-Density-details-correctly.patch

Please let me know how it works out for you.
Regards from Australia
Mark Harvey
npf
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

npf
Hello,

Next step working :) :)

When i do an initialize tape it works fine. It doesn't report any errors.
Now i'm trying to save data to the tape but it reports and error:

"Save or restore operation ended unsuccessfully."

Please find the logs in http://pastebin.com/fTtbS2PQ

The logs are from when i make the command to save content to the tape. The command in as400 world is:

SAVLIB LIB(MYLIB) DEV(TAP23)

Please let me know if you need any information.

Thanks for your help,
Nuno Fernandes
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

Mark Harvey
Administrator
big step forward..

I'll review next set of logs and plan the next patch

Sent from my iPad

On Jul 6, 2016, at 19:29, npf [via mhVTL - A Linux Virtual Tape Library] <[hidden email]> wrote:

Hello,

Next step working :) :)

When i do an initialize tape it works fine. It doesn't report any errors.
Now i'm trying to save data to the tape but it reports and error:

"Save or restore operation ended unsuccessfully."

Please find the logs in http://pastebin.com/fTtbS2PQ

The logs are from when i make the command to save content to the tape. The command in as400 world is:

SAVLIB LIB(MYLIB) DEV(TAP23)

Please let me know if you need any information.

Thanks for your help,
Nuno Fernandes


To start a new topic under mhVTL - A Linux Virtual Tape Library, email [hidden email]
To unsubscribe from mhVTL - A Linux Virtual Tape Library, click here.
NAML
Regards from Australia
Mark Harvey
npf
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

npf
Hello,

I'll be waiting on your feedback.

Meanwhile i've been doing some more tests and found an issue when writing anything to the tape:

[root@vtl ~]# mtx -f /dev/sg2 status
  Storage Changer /dev/sg2:1 Drives, 24 Slots ( 4 Import/Export )
Data Transfer Element 0:Full (Storage Element 1 Loaded):VolumeTag = N00001L4                            
      Storage Element 1:Empty
      Storage Element 2:Full :VolumeTag=N00002L3  
.....
.....

So, i have a LTO4 tape inserted in the drive. I can see that with:

[root@vtl ~]# mt -f /dev/st0 status
SCSI 2 tape drive:
File number=-1, block number=-1, partition=0.
Tape block size 0 bytes. Density code 0x46 (LTO-4).
Soft error count since last status=0
General status bits on (1010000):
 ONLINE IM_REP_EN

Next i do an initialize tape from the as400 box or a savlib command (to save contents to the tape). The initialize tape works fine (it doesn't give any errors). The savlib gives errors (as previous reported).
Nevertheless, the tape is converted to LTO3.

# Initialize tape tape from the as400 box
# check what we got on the linux box:

[root@vtl ~]# mt -f /dev/st0 status
SCSI 2 tape drive:
File number=0, block number=0, partition=0.
Tape block size 0 bytes. Density code 0x44 (LTO-3).
Soft error count since last status=0
General status bits on (41010000):
 BOT ONLINE IM_REP_EN

It changed to LTO-3 ??

Hope this feedback helps on solving the issue.

Best regards,
Nuno Fernandes

Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

Mark Harvey
Administrator
In reply to this post by npf
Any chance of the output of "dump_tape -f <barcode>" of the tape which was initialised by the AS400 ?

Perhaps a set of logs which records the steps during the 'initialisation' process too.

The only attempt to read is one attempt to read 80 bytes of data from block 0.

Which did appear to be successful..


On Wed, Jul 6, 2016 at 7:29 PM, npf [via mhVTL - A Linux Virtual Tape Library] <[hidden email]> wrote:
Hello,

Next step working :) :)

When i do an initialize tape it works fine. It doesn't report any errors.
Now i'm trying to save data to the tape but it reports and error:

"Save or restore operation ended unsuccessfully."

Please find the logs in http://pastebin.com/fTtbS2PQ

The logs are from when i make the command to save content to the tape. The command in as400 world is:

SAVLIB LIB(MYLIB) DEV(TAP23)

Please let me know if you need any information.

Thanks for your help,
Nuno Fernandes


To start a new topic under mhVTL - A Linux Virtual Tape Library, email [hidden email]
To unsubscribe from mhVTL - A Linux Virtual Tape Library, click here.
NAML

Regards from Australia
Mark Harvey
npf
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

npf
In reply to this post by Mark Harvey
Hello,

Here is the logs from the initialization of the tape:

http://pastebin.com/sRwcqxia

Here is dump_tape after the initialization:

[root@vtl ~]# dump_tape  -f N00001L4
Media density code: 0x46
Media type code   : 0x08
Media description : Ultrium 4/16T
Tape Capacity     : 838860800000 (781 GBytes)
Media type        : Normal data
Media             : read-write
Remaining Tape Capacity : 838860799920 (781 GBytes)
Total num of filemarks: 2
Hdr:              data(0b), sz     80/80    , Blk No.: 0, data 0
Hdr:         Filemark(03), sz             0, Blk No.: 1, data 80
Hdr:         Filemark(03), sz             0, Blk No.: 2, data 80
Hdr:      End of Data(05), sz             0, Blk No.: 3, data 80

Even if the dump_tape reports Ultrium 4, the mt status reports:

[root@vtl ~]# mt -f /dev/st0 status
SCSI 2 tape drive:
File number=0, block number=0, partition=0.
Tape block size 0 bytes. Density code 0x44 (LTO-3).
Soft error count since last status=0
General status bits on (41010000):
 BOT ONLINE IM_REP_EN

Best regards,
Nuno Fernandes
npf
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

npf
Hello,

Is there any information/logs that you require so that i can arrange that?

Thanks,
Nuno Fernandes
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

Mark Harvey
Administrator
initial review doesn't throw any obvious 'fix me' hints...

i'll need to pull apart the mode sense/select - but that will be a job for next week

Sent from my iPad

On Jul 12, 2016, at 19:12, npf [via mhVTL - A Linux Virtual Tape Library] <[hidden email]> wrote:

Hello,

Is there any information/logs that you require so that i can arrange that?

Thanks,
Nuno Fernandes


To start a new topic under mhVTL - A Linux Virtual Tape Library, email [hidden email]
To unsubscribe from mhVTL - A Linux Virtual Tape Library, click here.
NAML
Regards from Australia
Mark Harvey
npf
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

npf
Hello,

Hope you have time to see this issue. If there anything i can do to help (logs, commands) please ask.

Thanks,
Nuno Fernandes
npf
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

npf
Hello,

I'm going on vacations for the next week. If you have any time to see this issue, please let me know.

Thanks,
Nuno Fernandes
npf
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

npf
Hello,

Did you have any time to see this? Anything i can do to help?

Best regards,
Nuno Fernandes
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

Mark Harvey
Administrator
Darn, where did that time go...

I'll put together something most likely tomorrow..
I need to chase up some internal physical resources to compare against too.

Thanks for hanging in there....

Sent from my iPad

On Aug 29, 2016, at 19:22, npf [via mhVTL - A Linux Virtual Tape Library] <[hidden email]> wrote:

Hello,

Did you have any time to see this? Anything i can do to help?

Best regards,
Nuno Fernandes


To start a new topic under mhVTL - A Linux Virtual Tape Library, email [hidden email]
To unsubscribe from mhVTL - A Linux Virtual Tape Library, click here.
NAML
Regards from Australia
Mark Harvey
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

Mark Harvey
Administrator
When I run the MODE SELECT command against a 'real' LTO4 tape drive I get an error:

# sg_raw -i as400_mode_select -s 32 /dev/sg1 55 10 00 00 00 00 00 00 20 00
SCSI Status: Check Condition

Sense Information:
 Fixed format, current;  Sense key: Illegal Request
 Additional sense: Invalid field in parameter list
  Field replaceable unit code: 48
  Sense Key Specific: Error in Data byte 26 bit 3

mhVTL happily accepts the data.

I've now got something concrete to work against.. yet another patch due shortly ;)
Regards from Australia
Mark Harvey
npf
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

npf
Hello,

Great!! I'm just rebooting the server and will do the same test from the closed-source VTL. I will post in a few minutes..

Best regards,
Nuno Fernandes
npf
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

npf
In reply to this post by Mark Harvey
Hello,

I just realized that i need as400_mode_select file to test in the  closed-source VTL... If there is value in that test, that is..


Best regards,
Nuno Fernandes
Reply | Threaded
Open this post in threaded view
|

Re: mhVTL 1.5-4 exporting via FC to a AS400

Mark Harvey
Administrator
Here it is.. Feel free to test with closed source vtl.
Although I can't see anything spectacularly wrong with mhVTL behavior.

Note: it's a quick & dirty script - need to obviously update/tweak the /dev/nst & /dev/sg paths to suit your test environment.

  ======= Start script ========
#!/bin/bash

mt -f /dev/nst1 status

printf '\x00\x00\x48\x10\x00\x00\x00\x08\x44\x00\x00\x00\x00\x00\x00\x00' > as400_mode_select
printf '\x10\x0e\x00\x00\x00\x00\x00\x64\x40\x00\x18\x00\x00\x00\x00\x00' >> as400_mode_select

sg_raw -i as400_mode_select -s 32 /dev/sg3 55 10 00 00 00 00 00 00 20 00

mt -f /dev/nst1 status
  ======= end script ========
Regards from Australia
Mark Harvey
123