Project

General

Profile

Actions

action #28285

closed

Need to provide workaround for getting logs from system without network

Added by asmorodskyi about 7 years ago. Updated over 5 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
Feature requests
Target version:
-
Start date:
2017-11-23
Due date:
% Done:

0%

Estimated time:

Description

CUrrently we face from time to time with scenario where network is broken and we can do much for analyze issues which happening on broken system.
Mainly it is about upload_logs function. Idea is to make upload_logs network agnostic.


Related issues 2 (0 open2 closed)

Related to openQA Tests (public) - action #51098: [kernel][wicked] Copy files to VM without networkClosedcfconrad2019-05-05

Actions
Has duplicate openQA Project (public) - action #45086: Idea: way to get logs out of os-autoinst without network connectionRejectedokurz2018-12-12

Actions
Actions #1

Updated by coolo about 7 years ago

  • Subject changed from [tools] Need to provide workaround for getting logs from system without network to Need to provide workaround for getting logs from system without network
  • Category set to 140

Save to floppies perhaps?

Actions #2

Updated by asmorodskyi about 7 years ago

I know that it limits us to qemu , but still what you think about :

  1. Test fails
  2. In post_fail_hook there is attempt to upload_logs which fails because there is no network
  3. This trigger last standing post fail hook which running not in context of the test but in context of worker itself
  4. Worker shutdown qemu and then trying to do something like this https://www.jamescoyle.net/how-to/1818-access-a-qcow2-virtual-disk-image-from-the-host.

What do you think ?

Actions #3

Updated by sebchlad about 7 years ago

Good idea!

I need to secure a budget for buying a sever with floppy discs.

What do you recon Coolo: 3.5" or 5.25"?

Actions #4

Updated by coolo about 7 years ago

If you have test suites that need to work without network, provide a shared directory through vfat:

http://qemu-buch.de/de/index.php?title=QEMU-KVM-Buch/_Speichermedien/_Virtuelle_FAT-Festplatten and save the logs there. and they will be emulated as floppies in qemu.

Actions #5

Updated by okurz about 6 years ago

  • Related to action #45086: Idea: way to get logs out of os-autoinst without network connection added
Actions #6

Updated by okurz about 6 years ago

  • Related to deleted (action #45086: Idea: way to get logs out of os-autoinst without network connection)
Actions #7

Updated by okurz about 6 years ago

  • Has duplicate action #45086: Idea: way to get logs out of os-autoinst without network connection added
Actions #8

Updated by okurz about 6 years ago

Comment from AdamWill in #45086:

Sometimes, a test failure occurs because there's no network connection in the SUT. Then we hit our post-fail hook, which probably tries to upload logs for diagnosing the problem...over the network...

I'm doing a sorta hacky workaround for this in the Fedora tests: have the post-fail hook check if it can ping the host IP, and if it can't, try and dump the contents of text logs via the serial console. That seems at least better than nothing.

It occurred to me that it may be interesting to do a more generalized implementation of this in os-autoinst - perhaps as a new command similar to upload_logs, or implement it within upload_logs based on whether it can ping the host IP, something like that? Does anyone think this sounds like a useful idea?

Actions #9

Updated by AdamWill about 6 years ago

FWIW, this is my dirty workaround:

https://pagure.io/fedora-qa/os-autoinst-distri-fedora/blob/master/f/lib/installedtest.pm#_41

it works. Of course, it's no use for non-text files, and it's a bit 'messy' (you get the output all mixed in with the script_run exit code lines and stuff). And I dunno what'd happen if your post_fail_hook was actually using the serial console (not a VT)...

Using floppy / USB storage emulation somehow seems like a good idea, not sure if we could actually 'help' with that in os-autoinst or openQA, or if it'd just have to be something implemented in the distro test suites...

Actions #10

Updated by okurz over 5 years ago

  • Category changed from 140 to Feature requests
Actions #11

Updated by asmorodskyi over 5 years ago

  • Related to action #51098: [kernel][wicked] Copy files to VM without network added
Actions #13

Updated by okurz over 5 years ago

  • Status changed from New to Resolved
  • Assignee set to asmorodskyi

well, if you are happy with it so be it :)

Actions

Also available in: Atom PDF