petitboot icon indicating copy to clipboard operation
petitboot copied to clipboard

Adding petitboot hooks to aid test frameworks

Open sathnaga opened this issue 7 years ago • 4 comments

It would be helpful if we can add petitboot cmdline utilities to aid test frameworks

E:g:- discover_nw discover_disk

it can just return true or false based on the discovery status, it can be even be sub options to pb-discover also

sathnaga avatar Feb 21 '18 13:02 sathnaga

There are some tests which depends on discover of host n/w interfaces and disk device discovery. @sammj This is some thing can be implementable? We need it on op-test in some code instances.

pridhiviraj avatar Feb 21 '18 13:02 pridhiviraj

Sounds like a helpful thing to add, perhaps via pb-event or pb-config. What kind of information are we looking for? We can do things such as "is a disk with this UUID present", or "have we done PXE on eth0" and so on, but we can't do something like "is all disk discovery finished" because Petitboot doesn't know how many disks it should expect - discovery never really "finishes".

sammj avatar Feb 22 '18 00:02 sammj

Sam Mendoza-Jonas [email protected] writes:

Sounds like a helpful thing to add, perhaps via pb-event or pb-config. What kind of information are we looking for? We can do things such as "is a disk with this UUID present", or "have we done PXE on eth0" and so on, but we can't do something like "is all disk discovery finished" because Petitboot doesn't know how many disks it should expect - discovery never really "finishes".

For some reason I have a memory of there being some SCSI subsystem something something to be able to wait until all controllers had finished scanning for things.... is that a thing? Was I dreaming?

-- Stewart Smith OPAL Architect, IBM.

ghost avatar Feb 22 '18 04:02 ghost

@sammj yes that's right, requirement can be

1.  given mac-id(incase of network) is discovered
2. given disk/by-id(incase of disk) is discovered... etc

And always we can bail out with a reasonable timeout in test framework , as we can just poll for defined time and fail...

sathnaga avatar Feb 23 '18 06:02 sathnaga