Bug 14435

Summary: "bug" command failed (USB devices were no more detected)
Product: Mageia Reporter: stephane FLAVIGNY <megastorage>
Component: InstallerAssignee: Thierry Vignaud <thierry.vignaud>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: release_blocker CC: brianpeterson2, eeeemail, ennael1, ftg, mageia, mageia, marja11, rverschelde, seilebost, tarazed25, tmb
Version: Cauldron   
Target Milestone: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard: 5beta3
Source RPM: drakx-installer-binaries CVE:
Status comment:
Attachments: picture from tty
report.bug.xz
ddebug.log retrieved after "upgrade-install" and reboot
mount again debugfs
Diagnostic report from UEFI install

Description stephane FLAVIGNY 2014-11-02 18:00:57 CET
Dear,

When I ask for "bug" command in TTY the result is:

ask_from_list: empty list
 interactive::ask_from_listf_raw() called /usr/lib/libDrakX/interactive.pm:284
 interactive::ask_from_listf() called /usr/lib/libDrakX/install/commands.pm:404
 install::commands::bug() called from /usr/bin/bug:16
(eval)() called from /usr/bin/bug:14


Stéphane.

Reproducible: 

Steps to Reproduce:
Comment 1 stephane FLAVIGNY 2014-11-02 18:03:00 CET
Created attachment 5557 [details]
picture from tty

Picture from TTY.


Stéphane.
Comment 2 stephane FLAVIGNY 2014-11-02 18:05:02 CET
Created attachment 5558 [details]
report.bug.xz

/root/Drakx/report.bug.xz

Stéphane.
Comment 3 Marja Van Waes 2014-11-02 18:35:43 CET
Got exactly the same output here on my second try to (now upgrade-) install with probably the exact same iso: 64bits traditional pre-5beta1 DVD of October 31st. Nothing is written to the USB key.

My first try, a regular install with the same iso, gave another error for "bug", but I didn't make a picture because I was too busy with something else, and because I wrongly thought I'd find the error in the logs (however, the ddebug.log stops before the error). The error was either about the file system not being recognised, or the same as leuhmanu reported here:
https://bugs.mageia.org/show_bug.cgi?id=12263#c1 
I'll try to reproduce

I'm not sure it is all one and the same bug-bug :-/

Source RPM: (none) => drakx-installer-stage2
CC: (none) => marja11
Summary: "bug" command failled => "bug" command failed
Whiteboard: (none) => 5beta1

Manuel Hiebel 2014-11-10 23:19:39 CET

Assignee: bugsquad => thierry.vignaud
Priority: Normal => release_blocker

Comment 4 Anne Nicolas 2014-11-24 23:24:17 CET
Thierry any feedback on that bug?

CC: (none) => ennael1

Comment 5 Marja Van Waes 2015-01-08 21:49:17 CET
Still valid, classical pre-5beta2 64bit iso

* error: ask_from_list: empty list
interactive::ask_from_listf_raw() called from /usr/lib/libDrakX/interactive.pm:284
interactive::ask_from_listf() called from /usr/lib/libDrakX/install/commands.pm:404
install::commands::bug() called from /usr/bin/bug:16
(eval)() called from /usr/bin/bug:14

The USB key that I had inserted was new, empty and FAT32 formatted. I just wrote to it without any problems.

Whiteboard: 5beta1 => 5beta2

Comment 6 Marja Van Waes 2015-01-08 21:55:12 CET
Created attachment 5795 [details]
ddebug.log retrieved after "upgrade-install" and reboot

ddebug log of today's "upgrade install" in which the "bug" command was given
Comment 7 Rémi Verschelde 2015-02-17 21:00:56 CET
Since finding the provenance of the /usr/bin/bug script is not straight-forward for the non-initiated, here are some pointers:

The "bug" command seems to be defined by this script:
http://gitweb.mageia.org/software/drakx/tree/perl-install/install/commands
where $progname is "bug".

It then calls this subroutine which fails when used without arguments on line 404:
http://gitweb.mageia.org/software/drakx/tree/perl-install/install/commands.pm#n387

$part = $in->ask_from_listf('', "Which device?", \&partition_table::description, 
		[ install::any::removable_media__early_in_install() ]) or return;


I'm not fluent enough in perl to tell why it fails though, but at least the issue is located.

CC: (none) => remi

Rémi Verschelde 2015-02-17 21:01:28 CET

Whiteboard: 5beta2 => 5beta3

Comment 8 Rémi Verschelde 2015-02-17 21:16:06 CET
Claire, is this the same bug as what you described in bug 12263? I get the same debug output as you do in tty3, though it's in a VM without USB stick attached so I don't know how relevant it is.
Comment 9 Rémi Verschelde 2015-02-17 21:16:28 CET
Forgot to CC Claire, please see comment 8.

CC: (none) => eeeemail

Comment 10 claire robinson 2015-02-17 21:46:45 CET
looks like the same bug. close the old one if you like
Comment 11 Rémi Verschelde 2015-02-17 21:50:50 CET
*** Bug 12263 has been marked as a duplicate of this bug. ***
Comment 12 Rémi Verschelde 2015-02-17 21:51:18 CET
Interesting photo of the debug output from bug 12263: https://dl.dropboxusercontent.com/u/4147101/mga4rc/DSC02476.JPG
Comment 13 Thierry Vignaud 2015-02-17 22:42:54 CET
(In reply to Rémi Verschelde from comment #7)
No it fails b/c it didn't find any removable device.
You need to either put a floppy or a USB key.
Comment 14 Rémi Verschelde 2015-02-17 22:44:19 CET
(In reply to Thierry Vignaud from comment #13)
> (In reply to Rémi Verschelde from comment #7)
> No it fails b/c it didn't find any removable device.
> You need to either put a floppy or a USB key.

Ok, thanks for the precision. Shouldn't it say that it can't find a removable device instead of erroring out because of an empty list?
Comment 15 claire robinson 2015-02-17 23:07:07 CET
it fails even with a usb key Thierry. It works still if you manually specify the partition (eg. bug /dev/sdc1) but used to work with just bug on it's own.
Comment 16 Thierry Vignaud 2015-02-17 23:18:32 CET
I'll first make a better error handling then look at USB issue
Comment 17 Mageia Robot 2015-02-17 23:43:49 CET
commit 5eba62f7462c30319ce7dd540cf0cd2600611bc5
Author: Thierry Vignaud <thierry.vignaud@...>
Date:   Tue Feb 17 22:41:25 2015 +0100

    display a nicer message when no removable medium is found (mga#14435)
---
 Commit Link:
   http://gitweb.mageia.org/software/drakx/commit/?id=5eba62f7462c30319ce7dd540cf0cd2600611bc5
Comment 18 Mageia Robot 2015-02-18 00:15:46 CET
commit 377e714008c08a1b8439ae619624b1218627afd9
Author: Thierry Vignaud <thierry.vignaud@...>
Date:   Tue Feb 17 22:41:25 2015 +0100

    display a nicer message when no removable medium is found (mga#14435)
---
 Commit Link:
   http://gitweb.mageia.org/software/drakx/commit/?id=377e714008c08a1b8439ae619624b1218627afd9
Comment 19 Thierry Vignaud 2015-02-18 01:00:44 CET
For USB, the issue is that the {usb_media_type} field is not filled.

It looks like detect_devices::complete_usb_storage_info() failed to retrieve the proper data.
There's something that differs between standalone & install regarding /sys

CC: (none) => mageia, mageia, tmb

Comment 20 Thierry Vignaud 2015-02-18 01:10:28 CET
And the winner is: debugfs is not mounted on /sys/kernel/debug anymore in drakx
Once it's manually mounted, bug works again...

Colin? http://gitweb.mageia.org/software/drakx/commit/?id=63d2a603b9b2bc27090405ba4a05a4aaa8840ea2 was a bit brutal...
Comment 21 Thierry Vignaud 2015-02-18 01:14:04 CET
Created attachment 5929 [details]
mount again debugfs
Comment 22 Mageia Robot 2015-02-18 01:16:06 CET
commit d590e8727f7274119df1f9e98adc11aca6aafaaa
Author: Thierry Vignaud <thierry.vignaud@...>
Date:   Wed Feb 18 01:11:51 2015 +0100

    mount again debugfs for ldetect (mga#14435)
    
    regression from commit 63d2a603b9b2bc27090405ba4a05a4aaa8840ea2
---
 Commit Link:
   http://gitweb.mageia.org/software/drakx/commit/?id=d590e8727f7274119df1f9e98adc11aca6aafaaa
Comment 23 Thierry Vignaud 2015-02-18 01:18:24 CET
Closing

Status: NEW => RESOLVED
Resolution: (none) => FIXED

Comment 24 Colin Guthrie 2015-02-18 08:55:35 CET
(In reply to Thierry Vignaud from comment #20)
> And the winner is: debugfs is not mounted on /sys/kernel/debug anymore in
> drakx
> Once it's manually mounted, bug works again...
> 
> Colin?
> http://gitweb.mageia.org/software/drakx/commit/
> ?id=63d2a603b9b2bc27090405ba4a05a4aaa8840ea2 was a bit brutal...

Oops... a bit brutal indeed :( Wonder why this didn't come up before now (that change was a while back!) Thanks for fixing all the same!
Comment 25 Thierry Vignaud 2015-02-18 10:28:37 CET
*** Bug 15281 has been marked as a duplicate of this bug. ***

CC: (none) => tarazed25

Comment 26 Thierry Vignaud 2015-02-18 10:29:35 CET
*** Bug 15240 has been marked as a duplicate of this bug. ***

CC: (none) => brianpeterson2

Comment 27 Thierry Vignaud 2015-02-18 10:29:52 CET
*** Bug 15239 has been marked as a duplicate of this bug. ***
Comment 28 claire robinson 2015-02-18 10:44:40 CET
Would this also account for stage2 screenshots being created as zero byte files Thierry?
Thierry Vignaud 2015-02-18 11:00:50 CET

Source RPM: drakx-installer-stage2 => drakx-installer-binaries

Thierry Vignaud 2015-02-18 11:02:02 CET

Summary: "bug" command failed => "bug" command failed (USB devices were no more detected)

Comment 29 Thierry Vignaud 2015-02-18 11:09:12 CET
(In reply to Colin Guthrie from comment #24)
What's more it broke detecting USB devices.

At least, udev masked it a bit as we were able to detect USB mass storage b/c drivers were loaded by udev (modulo identifying USB devices like this one & a couple release blockers I'll tag as duplicates)

(In reply to claire robinson from comment #28)
No. That was bug #13684 on UEFI machines.
If you saw empty screenshots, ask Marja about it then open a new bug report
Comment 30 Len Lawrence 2015-02-27 17:42:05 CET
Created attachment 5961 [details]
Diagnostic report from UEFI install
Comment 31 Len Lawrence 2015-02-27 17:42:47 CET
Sending bug.report.xz.
Comment 32 Thierry Vignaud 2015-05-11 09:40:02 CEST
*** Bug 15071 has been marked as a duplicate of this bug. ***

CC: (none) => seilebost

Comment 33 Thierry Vignaud 2015-05-18 04:37:39 CEST
*** Bug 9904 has been marked as a duplicate of this bug. ***

CC: (none) => ftg