| Summary: | grub2 flashes "error: sparse file not allowed" message when booting from btrfs | ||
|---|---|---|---|
| Product: | Mageia | Reporter: | Thierry Vignaud <thierry.vignaud> |
| Component: | RPM Packages | Assignee: | Barry Jackson <zen25000> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | minor | ||
| Priority: | Low | CC: | alejandro.anv, ottoleipala1 |
| Version: | Cauldron | ||
| Target Milestone: | --- | ||
| Hardware: | All | ||
| OS: | Linux | ||
| See Also: | https://bugs.mageia.org/show_bug.cgi?id=27117 | ||
| Whiteboard: | |||
| Source RPM: | grub2-2.02-0.git10457.7.mga6 | CVE: | |
| Status comment: | |||
| Bug Depends on: | |||
| Bug Blocks: | 416 | ||
|
Description
Thierry Vignaud
2016-06-24 13:33:10 CEST
Thierry Vignaud
2016-06-24 13:33:27 CEST
Priority:
Normal =>
Low There's a similar issue for LVM/RAID: "grub2 diskfilter writes not supported" Here is a posible walk around: http://askubuntu.com/questions/100329/message-sparse-file-not-allowed-after-installing-on-a-btrfs-filesystem either comment out or remove this line: if [ -n ${have_grubenv} ]; then save_env recordfail; fi or if [ -n "\${have_grubenv}" ]; then if [ -z "\${boot_once}" ]; then save_env \ recordfail; fi; fi in this file /etc/grub.d/00_header then run update-grub CC:
(none) =>
alejandro.anv That's not a proper fix as it breaks the future for people where it's supported. Barry, I think it's just better to disable the warning and let this feature not work for the "happy few" Even if you wait it will automatically start to boot system so it can be just ignored. I am too against that op posted hack that would break whole grub if you make little mistake. CC:
(none) =>
ozkyster I don't understand why in Mageia 5 with grub 2 there is no problem using btrfs. (In reply to Alejandro Vargas from comment #5) > I don't understand why in Mageia 5 with grub 2 there is no problem using > btrfs. IIRC in Mga5 all grub2 messages to screen were suppressed by a patch, in Mga6 I think the patch was removed, but I have not had time to check. This is very normal case that Cauldron have dropped some patches what may break something and this kind of minor "bugs" are fixed when it hits release freeze. (In reply to Thierry Vignaud from comment #3) > That's not a proper fix as it breaks the future for people where it's > supported. > Barry, I think it's just better to disable the warning and let this feature > not work for the "happy few" OK, I have committed a fix that disables that message and returns without the delay: if (total_length != grub_file_size (file)) { /* Maybe sparse, unallocated sectors. No way in GRUB. */ - return grub_error (GRUB_ERR_BAD_FILE_TYPE, "sparse file not allowed"); + /*return grub_error (GRUB_ERR_BAD_FILE_TYPE, "sparse file not allowed")*/ + return GRUB_ERR_NONE; } It works for me so submitting and closing as fixed. Resolution:
(none) =>
FIXED For me the problem is not the "flash" of a message. The problem is it waits for enter to continue. In case of a power loss the system will not boot after somebody pressed a key. (In reply to Alejandro Vargas from comment #9) > For me the problem is not the "flash" of a message. The problem is it waits > for enter to continue. In case of a power loss the system will not boot > after somebody pressed a key. Please test grub2-2.02-0.git10457.9.mga6 when it appears on your mirror and see if you still have this issue. It worked OK. Fresh install. Added repos, urpmi grub2 for updating only grub2. Rebooted and booted without any message. (In reply to Alejandro Vargas from comment #11) > It worked OK. Fresh install. Added repos, urpmi grub2 for updating only > grub2. Rebooted and booted without any message. Good - thanks for testing. Barry
Florian Hubold
2021-03-03 14:53:46 CET
See Also:
(none) =>
https://bugs.mageia.org/show_bug.cgi?id=27117 |