SDL-Hercules-390 / hyperion

The SDL Hercules 4.x Hyperion version of the System/370, ESA/390, and z/Architecture Emulator
Other
240 stars 90 forks source link

Formating FBA device under VM/ESA v1 shows invalid file mask 48 and CMDREJ #473

Closed fbi-ranger closed 2 years ago

fbi-ranger commented 2 years ago

Hercules version 4.4.1.10647-SDL-gd0ccfbc9

Running DSF under VM/ESA V1 (P370) formating a FBA device as CPVOLUME leads to following errors on the Hercules console.

HHC00511E 0:0308 FBA file /local/sys1/s390/vmesa/vm/maint.19e: invalid file mask 48
HHC00007I Previous message from function 'fba_dasd_execute_ccw' at fbadasd.c(1128)
HHC01315I 0:0308 CHAN: ccw 63C43325 40800010=>48000000 00000000 00000000 00000000 ................
HHC01312I 0:0308 CHAN: stat 0E00, count 0000
HHC01313I 0:0308 CHAN: sense 80000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
HHC01314I 0:0308 CHAN: sense CMDREJ
HHC01315I 0:0308 CHAN: ccw F3C4334D 0080000C=>0A000008 00010000 0000000F          ............
HHC01312I 0:0308 CHAN: stat 0E00, count 0000
HHC01313I 0:0308 CHAN: sense 80000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
HHC01314I 0:0308 CHAN: sense CMDREJ

The DASD as such as far as I see is usable and works under VM/ESA V1.

BR Florian

Fish-Git commented 2 years ago

Hi Florian!

According to page 3-4 of "GA26-1661-09 3880 Storage Control Models 1, 2, 3 and 4 Description Manual", bit 4 (X'08') of a Define Extent (X'63') CCW's Mask byte is defined as "CE area. Used for maintenance purposes only", and CCW X'F3' is defined as "Diagnostic Control", with subcommand X'0A' being the "Read Id" subcommand, defined as "used to generate a defective block map".

These are basically FBA commands equivalent to the those used on CKD devices to access/update the device's Alternate Track information. Real CKD devices always have, in addition to their usual primary number of cylinders, a set of reserved "alternate cylinders" containing tracks that can be used to replace defective primary tracks. Special I/O (CCW) commands are used to assign an alternate track to a defective primary track, and the commands that your DSF was trying to issue was essentially the same thing but for FBA devices. It was trying to read the device's "map" of assigned alternate blocks.

The only problem is, while alternate cylinders for CKD devices are indeed supported by Hercules, alternate blocks for FBA devices are not! That is to say, currently, Hercules does not provide alternate block support for FBA devices.

Such support could certainly be provided (all(?) of the information needed to code it is known/available), but it would take quite a bit of time/effort to develop and test it. Time and effort that I personally would rather not have to do if we don't really need to. I will do it if we absolutely must do it! But I suspect we more than likely don't really need to do it.

I suspect there is likely a DSF option that requests formatting of the device but without accessing the device's diagnostic area. I'm not experienced with DSF, but I believe it might be the "INSPECT" or "VERIFY" options? That is to say, maybe you just need to specify "NOVERIFY" and/or "NOINSPECT" when you do your format?

If that works, if that allows you to workaround (prevent) the problem, then I would suggest doing that to prevent the problem you're currently having. Otherwise, if you are unable to workaround the problem, then we are left with no choice but for me to take the time and effort to add FBA alternate block support to Hercules (which, as explained, is something that will take a bit of time/effort to accomplish).

So, my suggestion would be to try and find a DSF option/parameter to workaround the problem (i.e. to prevent DSF from trying to access the drive's diagnostic control area). If that proves to be impossible, then let me know, and I will begin trying to add FBA alternate block support to Hercules.

But I'd rather not do that if I don't have to.

fbi-ranger commented 2 years ago

Fish,

VERIFY or NOVERIFY tells DSF if it should check the Label of the device or not before doing an action.

I think the option is NOREADCHECK as the default READCKECK invokes INSPECT if it has troubles with the formated block.

Wouldn't it be easier to present a good answer to the request? Simply to say, its all ok?

On the other hand I use FBA device only because that system P370 is for me not available on other device type. I would try to migrate the system to 3380 CKD. This should be possible. Or maybe 9336 would be an alternative.

I think it would not be worth to spend too much time on this issue.

Florian

Fish-Git commented 2 years ago

Wouldn't it be easier to present a good answer to the request? Simply to say, its all ok?

Unfortunately, no.   :(

I think the option is NOREADCHECK as the default READCKECK invokes INSPECT if it has troubles with the formated block.

Wouldn't it be easier to just specify NOREADCHECK?

Fish-Git commented 2 years ago

Florian? (@fbi-ranger)

Have you tried using NOREADCHECK yet? Does it resolve your problem?

fbi-ranger commented 2 years ago

Sorry Fish, I am currently travelling an therefore it takes a little bit longer to react.

I did following:

IPL DSF under MAINT user.

Enter Console / console and then:

cpvolume format unit(101) noverify volid(USER11) NOREADCHECK

This results in output from DSF:

 CPVOLUME FORMAT UNIT(101) NOVERIFY VOLID(USER11) NOREADCHECK
ICK03020I CPVOL IS OPERATING IN VM/370 MODE
ICK00700I DEVICE INFORMATION FOR 0101 IS CURRENTLY AS FOLLOWS:
          PHYSICAL DEVICE = 3370-1
          STORAGE CONTROLLER = 3880
          STORAGE CONTROL DESCRIPTOR = 01
          DEVICE DESCRIPTOR = 00
ICK03090I VOLUME SERIAL = USER11
ICK03011I PAGE RANGE TO BE FORMATTED IS 0 - 69749
ICK003D REPLY U TO ALTER VOLUME 0101 CONTENTS, ELSE T
ENTER INPUT/COMMAND:

and parallel on the Hercules console:

HHC00511E 0:0101 FBA file /local/sys1/s390/vmesa/user/user11.101: invalid file mask 48
HHC00007I Previous message from function 'fba_dasd_execute_ccw' at fbadasd.c(1128)
HHC01315I 0:0101 CHAN: ccw 63BFA325 40800010=>48000000 00000000 00000000 00000000 ................
HHC01312I 0:0101 CHAN: stat 0E00, count 0000
HHC01313I 0:0101 CHAN: sense 80000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
HHC01314I 0:0101 CHAN: sense CMDREJ
HHC01315I 0:0101 CHAN: ccw F3BFA34D 0080000C=>0A000008 00010000 0000000F          ............
HHC01312I 0:0101 CHAN: stat 0E00, count 0000
HHC01313I 0:0101 CHAN: sense 80000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
HHC01314I 0:0101 CHAN: sense CMDREJ
HHC00511E 0:0101 FBA file /local/sys1/s390/vmesa/user/user11.101: invalid file mask C8
HHC00007I Previous message from function 'fba_dasd_execute_ccw' at fbadasd.c(1128)
HHC01315I 0:0101 CHAN: ccw 63D3D9E8 40800010=>C8000000 00000000 00000000 FFFFFFFF H...............
HHC01312I 0:0101 CHAN: stat 0E00, count 0000
HHC01313I 0:0101 CHAN: sense 80000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
HHC01314I 0:0101 CHAN: sense CMDREJ
HHC00511E 0:0101 FBA file /local/sys1/s390/vmesa/user/user11.101: invalid file mask C8
HHC00007I Previous message from function 'fba_dasd_execute_ccw' at fbadasd.c(1128)
HHC01315I 0:0101 CHAN: ccw 63D3D9E8 40800010=>C8000000 00000000 00000000 FFFFFFFF H...............
HHC01312I 0:0101 CHAN: stat 0E00, count 0000
HHC01313I 0:0101 CHAN: sense 80000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
HHC01314I 0:0101 CHAN: sense CMDREJ

So DSF even did not start to format but seems already to access the CE area.

So NOREADCHECK does not help.

BR Florian

Fish-Git commented 2 years ago

So NOREADCHECK does not help.

That might not be completely true.

The originally reported "invalid file mask" error does indeed occur a couple of times before the format even begins (as you have shown above), BUT... the real question is, does the format FAIL because of it?

If the format runs successfully anyway (without any further Hercules "invalid file mask" error messages being issued), then I don't see the need to spend the time and effort needed to "fix" Hercules by adding FBA alternate block support.

BUT... If the format fails because of this problem, then yes, we will obviously need to add such support to Hercules.

Soooo.... the big question is:

Does the format ultimately succeed or fail whenever NOREADCHECK is specified?

_(and does Hercules continue to issue those error messages as the format runs?)_

fbi-ranger commented 2 years ago

Hi Fish,

Hercules issues the messages BEFORE the format runs because one has still specify "U" in order to start really the formatting the DASD.

Format does NOT fail if READCHECK (default) or NOREADCHECK is stated. Seems it makes no difference.

The DASD is usable after format even with the messages stated on the Hercules console.

When invoking DSF it tries immediately to access the CE area.

Florian

Fish-Git commented 2 years ago

Hercules issues the messages BEFORE the format runs because one has still specify "U" in order to start really the formatting the DASD.

Got that the first time. My concern however was whether or not Hercules continued to issue the messages after the format was started. If I am understanding you correctly, it does not. Yes? Correct? That is to say, Hercules ONLY issues the error messages before the format is started, but does not issue the messages after the format is started. Yes? Correct?

If I am right, then that is good news.

Format does NOT fail if READCHECK (default) or NOREADCHECK is stated. Seems it makes no difference.

The DASD is usable after format even with the messages stated on the Hercules console.

Interesting! But that is also VERY GOOD NEWS too! That means adding FBA alternate block support to Hercules is not required.

Rather, we can simply document the fact that FBA alternate block support is not supported and as a result, might cause some error messages to be issued in certain situations (during VM format for example), but should not otherwise cause any problems. All other (i.e. normal) FBA device I/O should continue to work fine.

When invoking DSF it tries immediately to access the CE area.

Understood. And it only does so ONCE, and only when DSF is first started. Correct? But once DSF begins and you start your 'format', then those messages never occur again. Correct?

Presuming that am correct, then from my point of view there is nothing that needs to be done in Hercules. There is nothing that is critical. That is to say, the "invalid file mask" error messages are basically benign (as in: not harmful). Yes? Correct.

So I am going to close this issue as "Won't fix". *`()`**


*`()` _"Won't fix" meaning the problem (bug) technically does exist**, but given its nature, was determined to not be worth the effort to actually fix. That is to say, it's a bug we have determined "we can live with"._

Fish-Git commented 2 years ago

Closing as "Won't Fix".

ivan-w commented 2 years ago

Fine by me - We do not have a CE/Alternate track area because this is a completely virtualized. I'm just a bit squeezy about the returned sense (no ERP), but ICKDSF and VM seem to just seem not do anything about it. I'm not sure there is an ERP for : Does not apply : Virtualized

Fish-Git commented 2 years ago

Fine by me - We do not have a CE/Alternate track area because this is a completely virtualized.

Right. It's the responsibility of the Hercules host system (Windows, Linux, etc) to deal with any bad tracks/blocks and perform the necessary recovery (assignment of alternates).

But our CKD dasd implementation does support alternate tracks. Why, I'm not quite sure. Just as I'm not sure whether the support that Hercules provides is full support or not. I didn't bother to check.

But the overall concept of supporting alternate tracks/blocks for virtualized dasd devices is silly IMO.

I'm just a bit squeezy about the returned sense (no ERP),

I didn't bother checking that. Are you saying (implying) the sense that Hercules returns for "invalid file mask" might not be correct? That's something else I didn't bother checking either. If it's wrong, then I agree that at least that is something that definitely needs to be fixed.

but ICKDSF and VM seem to just seem not do anything about it.

Right. Which is why I'm not concerned about it either.

I'm not sure there is an ERP for : Does not apply : Virtualized

Neither am I, but I'm doubting it.

But I'm glad to hear that you agree that, given the circumstances, trying to fix it wouldn't be worth the effort.

Thanks, Ivan.

ivan-w commented 2 years ago

But our CKD dasd implementation does support alternate tracks. Why, I'm not quite sure. Just as I'm not sure whether the support that Hercules provides is full support or not. I didn't bother to check.

I think this has to do with early versions of ICKDSF which weren't happy if they couldn't find a CE area. By the time when FBA was implemented, it's perfectly possible the people using ICKDSF were told to just ignore any error attempt to access the CE area using a SET FILE MASK CCW!

dasdman commented 2 years ago

But our CKD dasd implementation does support alternate tracks. Why, I'm not quite sure. Just as I'm not sure whether the support that Hercules provides is full support or not. I didn't bother to check.

I think this has to do with early versions of ICKDSF which weren't happy if they couldn't find a CE area. By the time when FBA was implemented, it's perfectly possible the people using ICKDSF were told to just ignore any error attempt to access the CE area using a SET FILE MASK CCW!

Make that BEFORE ICKDSF support for DASD formatting. And the alternate track support is not “real” alternate track support as the utilities fully dealing with alternate tracks fail due to incorrect sense information.

ivan-w commented 2 years ago

Sheesh - and you don't really need to "format" FBA drives! Just a couple of bits here and there on the first few blocks (don't ask me, I have no idea - just think of it as creating a dummy VTOC or a CD header).

ICKDSF was a bit of a beast to start with - and then was basically throttled down to be a basic low format utility (If I got it right - Mark might have a better view on this - and whatever he says trumps whatever I say) --Ivan

Fish-Git commented 2 years ago

Sheesh - and you don't really need to "format" FBA drives! Just a couple of bits here and there on the first few blocks (don't ask me, I have no idea - just think of it as creating a dummy VTOC or a CD header).

Right. There is no physical formatting for FBA drives like there is for CKD drives. The entire drive is already physically formatted as just a collection of 'x' number of physical 512 byte blocks (sectors), and that cannot be changed. The only formatting that can be done is logical formatting, like where the VTOC is located and how many sectors long it is, etc. So doing an ICKDSF format of an FBA drive really consists of only defining the VOLSER and VTOC. Period. Nothing else needs to be done.

ivan-w commented 2 years ago

After reading the various reviews from some very fine experts, I would consider this problem-confirmed as "Closed : Behaves as expected"

Fish-Git commented 2 years ago

After reading the various reviews from some very fine experts, I would consider this problem-confirmed as "Closed : Behaves as expected"

It already is, but thanks for the confirmation.   :)

fbi-ranger commented 2 years ago

If you are interested, I have now a complete CCW-trace of DSF format with NOREADCHECK.

BR Florian

On Thu, 17 Feb 2022 at 10:31, Fish-Git @.***> wrote:

After reading the various reviews from some very fine experts, I would consider this problem-confirmed as "Closed : Behaves as expected"

It already is https://github.com/SDL-Hercules-390/hyperion/issues/473#issuecomment-1040785413, but thanks for the confirmation. :)

— Reply to this email directly, view it on GitHub https://github.com/SDL-Hercules-390/hyperion/issues/473#issuecomment-1042743864, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABESU6D4E3DVSQSY3VVTYBTU3S53ZANCNFSM5OEMUIKQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you were mentioned.Message ID: @.***>