You are not logged in.
ich habe grub-btrfs installiert und überwache timeshift auf Snapshots, die dann als Menüpunkt zu grub hinzugefügt werden. Wenn ich aktualisiere, tritt der folgende Fehler auf.
Generating grub configuration file ...
Found theme: /boot/grub/themes/Arch/theme.txt
Found linux image: /boot/vmlinuz-linux-lts
Found initrd image: /boot/intel-ucode.img /boot/initramfs-linux-lts.img
Found fallback initrd image(s) in /boot: intel-ucode.img initramfs-linux-lts-fallback.img
Warning: os-prober will not be executed to detect other bootable partitions.
Systems on them will not be added to the GRUB boot configuration.
Check GRUB_DISABLE_OS_PROBER documentation entry.
Adding boot menu entry for UEFI Firmware Settings ...
»/boot/grub/grub.cfg.new« kann nicht geöffnet werden: Datei oder Verzeichnis nicht gefundenAufruf: /usr/bin/grub-script-check [OPTION...] [PFAD]
Try '/usr/bin/grub-script-check --help' or '/usr/bin/grub-script-check
--usage' for more information.
Syntax errors are detected in generated GRUB config file.
Ensure that there are no errors in /etc/default/grub
and /etc/grub.d/* files or please file a bug report with
/boot/grub/grub.cfg.new file attached.
Last edited by barnd3 (2023-08-25 01:39:46)
Offline
/boot/grub/grub.cfg.new wird von grub-mkconfig erzeugt und mit grub-script-check getestet bevor /boot/grub/grub.cfg ersetzt wird.
Wenn grub-mkconfig /boot/grub/grub.cfg.new nicht schreibt ist entweder die Partition voll oder als readonly eingebunden oder grub-mkconfig läuft nicht als root.
Offline
Jetzt läuft "grub-btrfs" durch und erstellt auch die Einträge.
Es erscheint aber ein neuer Fehler
Aug 25 10:41:44 I-NET grub-btrfsd[3327]: [!] Error during grub menu creation (grub/ grub-btrfs error)
Last edited by barnd3 (2023-08-25 08:53:58)
Offline
https://github.com/Antynea/grub-btrfs/b … trfsd#L219
Ohne Kontext ist das wenig hilfreich - grub-mkconfig scheitert vorweg und das führt zu der Fehlermeldung durch grub-btrfsd.
Offline
Was für einen Kontext kann ich liefern?
Offline
Die volle Ausgabe - es muß vorweg einen Fehler in grub-mkconfig gegeben haben der dazu führt, daß es mit einem Status != 0 endet.
Offline
Ich kann keinen Fehler entdecken.
grub-btrfs laüft durch und erstellt die Einträge und trotzdem kommt der Fehler
:: Installation fortsetzen? [J/n] j
(1/1) Schlüssel im Schlüsselbund werden geprüft [##################################] 100%
(1/1) Paket-Integrität wird überprüft [##################################] 100%
(1/1) Paket-Dateien werden geladen [##################################] 100%
(1/1) Auf Dateikonflikte wird geprüft [##################################] 100%
(1/1) Verfügbarer Festplattenspeicher wird ermittelt [##################################] 100%
:: Pre-transaction-Hooks werden gestartet …
(1/1) Creating Timeshift snapshot before upgrade...
Using system disk as snapshot device for creating snapshots in BTRFS mode
Mounted '/dev/sda2' at '/run/timeshift/24063/backup'
Mounted '/dev/sdc2' at '/run/timeshift/24063/backup-home'
btrfs: Quotas are not enabled
Creating new backup...(BTRFS)
Saving to device: /dev/sda2, mounted at path: /run/timeshift/24063/backup
Saving to device: /dev/sdc2, mounted at path: /run/timeshift/24063/backup-home
Created directory: /run/timeshift/24063/backup/timeshift-btrfs/snapshots/2023-08-25_16-28-56
Created subvolume snapshot: /run/timeshift/24063/backup/timeshift-btrfs/snapshots/2023-08-25_16-28-56/@
Created control file: /run/timeshift/24063/backup/timeshift-btrfs/snapshots/2023-08-25_16-28-56/info.json
BTRFS Snapshot saved successfully (0s)
Tagged snapshot '2023-08-25_16-28-56': ondemand
------------------------------------------------------------------------------
Mounted '/dev/sda2' at '/run/timeshift/24256/backup'
Mounted '/dev/sdc2' at '/run/timeshift/24256/backup-home'
btrfs: Quotas are not enabled
------------------------------------------------------------------------------
Removing snapshot: 2023-08-25_10-06-46
Deleting subvolume: @ (Id:275)
Deleted subvolume: @ (Id:275)
Deleted directory: /run/timeshift/24256/backup/timeshift-btrfs/snapshots/2023-08-25_10-06-46
Removed snapshot: 2023-08-25_10-06-46
------------------------------------------------------------------------------
Generating grub configuration file ...
Found theme: /boot/grub/themes/Arch/theme.txt
Found linux image: /boot/vmlinuz-linux-lts
Found initrd image: /boot/intel-ucode.img /boot/initramfs-linux-lts.img
Found fallback initrd image(s) in /boot: intel-ucode.img initramfs-linux-lts-fallback.img
Warning: os-prober will not be executed to detect other bootable partitions.
Systems on them will not be added to the GRUB boot configuration.
Check GRUB_DISABLE_OS_PROBER documentation entry.
Adding boot menu entry for UEFI Firmware Settings ...
Detecting snapshots ...
Found snapshot: 2023-08-25 16:28:56 | timeshift-btrfs/snapshots/2023-08-25_16-28-56/@ | ondemand | {timeshift-autosnap} {created before upgrade} |
Found snapshot: 2023-08-25 16:24:10 | timeshift-btrfs/snapshots/2023-08-25_16-24-10/@ | ondemand | {timeshift-autosnap} {created before upgrade} |
Found snapshot: 2023-08-25 10:41:42 | timeshift-btrfs/snapshots/2023-08-25_10-41-42/@ | ondemand | {timeshift-autosnap} {created before upgrade} |
Found snapshot: 2023-08-25 03:00:01 | timeshift-btrfs/snapshots/2023-08-25_03-00-01/@ | daily | N/A |
Found snapshot: 2023-08-24 01:59:39 | timeshift-btrfs/snapshots/2023-08-24_01-59-39/@ | ondemand daily weekly monthly | N/A |
Found 5 snapshot(s)
Unmount /tmp/grub-btrfs.bXkSvykzKF .. Success
done
:: Paketänderungen werden verarbeitet …
(1/1) Aktualisiert wird acpid [##################################] 100%
:: Post-transaction-Hooks werden gestartet …
(1/4) Reloading system manager configuration...
(2/4) Arming ConditionNeedsUpdate...
(3/4) Cleaning pacman cache...
==> no candidate packages found for pruning
(4/4) Removing old packages from pacman cache...
Removing old installed packages...
==> no candidate packages found for pruning
Removing old uninstalled packages...
==> no candidate packages found for pruning
sudo grub-mkconfig
[sudo] Passwort für andre:
Generating grub configuration file ...
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#
### BEGIN /etc/grub.d/00_header ###
insmod part_gpt
insmod part_msdos
if [ -s $prefix/grubenv ]; then
load_env
fi
if [ "${next_entry}" ] ; then
set default="${next_entry}"
set next_entry=
save_env next_entry
set boot_once=true
else
set default="0"
fi
if [ x"${feature_menuentry_id}" = xy ]; then
menuentry_id_option="--id"
else
menuentry_id_option=""
fi
export menuentry_id_option
if [ "${prev_saved_entry}" ]; then
set saved_entry="${prev_saved_entry}"
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi
function savedefault {
if [ -z "${boot_once}" ]; then
saved_entry="${chosen}"
save_env saved_entry
fi
}
function load_video {
if [ x$feature_all_video_module = xy ]; then
insmod all_video
else
insmod efi_gop
insmod efi_uga
insmod ieee1275_fb
insmod vbe
insmod vga
insmod video_bochs
insmod video_cirrus
fi
}
if [ x$feature_default_font_path = xy ] ; then
font=unicode
else
insmod part_gpt
insmod btrfs
set root='hd0,gpt2'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt2 --hint-efi=hd0,gpt2 --hint-baremetal=ahci0,gpt2 d1d0bf85-943b-4600-b667-3351008ec7e5
else
search --no-floppy --fs-uuid --set=root d1d0bf85-943b-4600-b667-3351008ec7e5
fi
font="/@/usr/share/grub/unicode.pf2"
fi
if loadfont $font ; then
set gfxmode=auto
load_video
insmod gfxterm
set locale_dir=$prefix/locale
set lang=de_DE
insmod gettext
fi
terminal_input console
terminal_output gfxterm
Found theme: /boot/grub/themes/Arch/theme.txt
insmod part_gpt
insmod fat
set root='hd0,gpt1'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt1 --hint-efi=hd0,gpt1 --hint-baremetal=ahci0,gpt1 81D7-E685
else
search --no-floppy --fs-uuid --set=root 81D7-E685
fi
insmod gfxmenu
loadfont ($root)/grub/themes/Arch/terminus-12.pf2
loadfont ($root)/grub/themes/Arch/terminus-14.pf2
loadfont ($root)/grub/themes/Arch/terminus-16.pf2
loadfont ($root)/grub/themes/Arch/terminus-18.pf2
loadfont ($root)/grub/themes/Arch/ubuntu_regular_17.pf2
loadfont ($root)/grub/themes/Arch/ubuntu_regular_20.pf2
insmod png
set theme=($root)/grub/themes/Arch/theme.txt
export theme
if [ x$feature_timeout_style = xy ] ; then
set timeout_style=menu
set timeout=5
# Fallback normal timeout code in case the timeout_style feature is
# unavailable.
else
set timeout=5
fi
### END /etc/grub.d/00_header ###
### BEGIN /etc/grub.d/10_linux ###
Found linux image: /boot/vmlinuz-linux-lts
Found initrd image: /boot/intel-ucode.img /boot/initramfs-linux-lts.img
menuentry 'Arch Linux' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-d1d0bf85-943b-4600-b667-3351008ec7e5' {
load_video
set gfxpayload=keep
insmod gzio
insmod part_gpt
insmod fat
set root='hd0,gpt1'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt1 --hint-efi=hd0,gpt1 --hint-baremetal=ahci0,gpt1 81D7-E685
else
search --no-floppy --fs-uuid --set=root 81D7-E685
fi
echo 'Loading Linux linux-lts ...'
linux /vmlinuz-linux-lts root=UUID=d1d0bf85-943b-4600-b667-3351008ec7e5 rw rootflags=subvol=@ intel_pstate=disable nowatchdog loglevel=3 quiet
echo 'Loading initial ramdisk ...'
initrd /intel-ucode.img /initramfs-linux-lts.img
}
submenu 'Advanced options for Arch Linux' $menuentry_id_option 'gnulinux-advanced-d1d0bf85-943b-4600-b667-3351008ec7e5' {
menuentry 'Arch Linux, with Linux linux-lts' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-lts-advanced-d1d0bf85-943b-4600-b667-3351008ec7e5' {
load_video
set gfxpayload=keep
insmod gzio
insmod part_gpt
insmod fat
set root='hd0,gpt1'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt1 --hint-efi=hd0,gpt1 --hint-baremetal=ahci0,gpt1 81D7-E685
else
search --no-floppy --fs-uuid --set=root 81D7-E685
fi
echo 'Loading Linux linux-lts ...'
linux /vmlinuz-linux-lts root=UUID=d1d0bf85-943b-4600-b667-3351008ec7e5 rw rootflags=subvol=@ intel_pstate=disable nowatchdog loglevel=3 quiet
echo 'Loading initial ramdisk ...'
initrd /intel-ucode.img /initramfs-linux-lts.img
}
Found fallback initrd image(s) in /boot: intel-ucode.img initramfs-linux-lts-fallback.img
menuentry 'Arch Linux, with Linux linux-lts (fallback initramfs)' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-lts-fallback-d1d0bf85-943b-4600-b667-3351008ec7e5' {
load_video
set gfxpayload=keep
insmod gzio
insmod part_gpt
insmod fat
set root='hd0,gpt1'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt1 --hint-efi=hd0,gpt1 --hint-baremetal=ahci0,gpt1 81D7-E685
else
search --no-floppy --fs-uuid --set=root 81D7-E685
fi
echo 'Loading Linux linux-lts ...'
linux /vmlinuz-linux-lts root=UUID=d1d0bf85-943b-4600-b667-3351008ec7e5 rw rootflags=subvol=@ intel_pstate=disable nowatchdog loglevel=3 quiet
echo 'Loading initial ramdisk ...'
initrd /intel-ucode.img /initramfs-linux-lts-fallback.img
}
}
### END /etc/grub.d/10_linux ###
### BEGIN /etc/grub.d/20_linux_xen ###
### END /etc/grub.d/20_linux_xen ###
### BEGIN /etc/grub.d/25_bli ###
if [ "$grub_platform" = "efi" ]; then
insmod bli
fi
### END /etc/grub.d/25_bli ###
### BEGIN /etc/grub.d/30_os-prober ###
Warning: os-prober will not be executed to detect other bootable partitions.
Systems on them will not be added to the GRUB boot configuration.
Check GRUB_DISABLE_OS_PROBER documentation entry.
### END /etc/grub.d/30_os-prober ###
### BEGIN /etc/grub.d/30_uefi-firmware ###
Adding boot menu entry for UEFI Firmware Settings ...
if [ "$grub_platform" = "efi" ]; then
fwsetup --is-supported
if [ "$?" = 0 ]; then
menuentry 'UEFI Firmware Settings' $menuentry_id_option 'uefi-firmware' {
fwsetup
}
fi
fi
### END /etc/grub.d/30_uefi-firmware ###
### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###
### BEGIN /etc/grub.d/41_custom ###
if [ -f ${config_directory}/custom.cfg ]; then
source ${config_directory}/custom.cfg
elif [ -z "${config_directory}" -a -f $prefix/custom.cfg ]; then
source $prefix/custom.cfg
fi
### END /etc/grub.d/41_custom ###
### BEGIN /etc/grub.d/41_snapshots-btrfs ###
Detecting snapshots ...
Found snapshot: 2023-08-25 16:28:56 | timeshift-btrfs/snapshots/2023-08-25_16-28-56/@ | ondemand | {timeshift-autosnap} {created before upgrade} |
Found snapshot: 2023-08-25 16:24:10 | timeshift-btrfs/snapshots/2023-08-25_16-24-10/@ | ondemand | {timeshift-autosnap} {created before upgrade} |
Found snapshot: 2023-08-25 10:41:42 | timeshift-btrfs/snapshots/2023-08-25_10-41-42/@ | ondemand | {timeshift-autosnap} {created before upgrade} |
Found snapshot: 2023-08-25 03:00:01 | timeshift-btrfs/snapshots/2023-08-25_03-00-01/@ | daily | N/A |
Found snapshot: 2023-08-24 01:59:39 | timeshift-btrfs/snapshots/2023-08-24_01-59-39/@ | ondemand daily weekly monthly | N/A |
if [ ! -e "${prefix}/grub-btrfs.cfg" ]; then
echo ""
else
submenu 'Arch Linux snapshots' {
configfile "${prefix}/grub-btrfs.cfg"
}
fi
Found 5 snapshot(s)
Unmount /tmp/grub-btrfs.545I1f5ZcH .. Success
### END /etc/grub.d/41_snapshots-btrfs ###
done
Last edited by barnd3 (2023-08-25 14:45:50)
Offline
Das ist aber die AUsgabe von irgendeinen "sudo pacman -S linux-foo", richtig?
Wichtig ist, was das grub-btrfsd script da macht.
Ändere mal die Funktion
create_grub_menu() {
exec > /tmp/grub_btrfs.log 2>&1
set -x
# create the grub submenu of the whole grub menu, depending on wether the submenu already exists
…
err "[!] Error during grub menu creation (grub/ grub-btrfs error)" "${RED}"
fi
set +x
}
und starte danach den daemon neu, Du solltest dann nach dem nächsten Lauf debug Ausgaben in /tmp/grub_btrfs.log haben.
Offline
Ich weiß nicht, ob ich das richtig gemacht habe.
Das steht in dem log drin
+ …
/usr/bin/grub-btrfsd: Zeile 227: …: Kommando nicht gefunden.
+ err '[!] Error during grub menu creation (grub/ grub-btrfs error)' '[0;31m'
+ echo '[0;31m[!]' Error during grub menu creation '(grub/' grub-btrfs 'error)[0m'
[0;31m[!] Error during grub menu creation (grub/ grub-btrfs error)[0m
+ '[' true = true ']'
+ logger -p user.error -t grub-btrfsd '[!] Error during grub menu creation (grub/ grub-btrfs error)'
+ '[' 1 -gt 1 ']'
+ set +x
55494: detected timeshift shutdown[0m
Watching /run/timeshift for timeshift to start[0m
Offline
Die Ellipsis ist ein Auslassungszeichen, die einzigen Änderungen wären "exec > /tmp/grub_btrfs.log 2>&1", "set -x" und am Ende "set +x"
Der Rest der Funktion muß bleiben wie er ist.
Offline
Ahhh...
+ grep snapshots-btrfs '{grub_directory}/grub.cfg'
grep: {grub_directory}/grub.cfg: Datei oder Verzeichnis nicht gefunden
+ grub-mkconfig -o /boot/grub/grub.cfg
Generating grub configuration file ...
Found theme: /boot/grub/themes/Arch/theme.txt
Found linux image: /boot/vmlinuz-linux-lts
Found initrd image: /boot/intel-ucode.img /boot/initramfs-linux-lts.img
Found fallback initrd image(s) in /boot: intel-ucode.img initramfs-linux-lts-fallback.img
Warning: os-prober will not be executed to detect other bootable partitions.
Systems on them will not be added to the GRUB boot configuration.
Check GRUB_DISABLE_OS_PROBER documentation entry.
Adding boot menu entry for UEFI Firmware Settings ...
Detecting snapshots ...
Found snapshot: 2023-08-25 18:01:53 | timeshift-btrfs/snapshots/2023-08-25_18-01-53/@ | ondemand | {timeshift-autosnap} {created before upgrade} |
Found snapshot: 2023-08-25 17:58:26 | timeshift-btrfs/snapshots/2023-08-25_17-58-26/@ | ondemand | {timeshift-autosnap} {created before upgrade} |
Found snapshot: 2023-08-25 17:52:19 | timeshift-btrfs/snapshots/2023-08-25_17-52-19/@ | ondemand | {timeshift-autosnap} {created before upgrade} |
Found snapshot: 2023-08-25 03:00:01 | timeshift-btrfs/snapshots/2023-08-25_03-00-01/@ | daily | N/A |
Found snapshot: 2023-08-24 01:59:39 | timeshift-btrfs/snapshots/2023-08-24_01-59-39/@ | ondemand daily weekly monthly | N/A |
Found 5 snapshot(s)
Unmount /tmp/grub-btrfs.mY8aWPQePn .. Success
Fehler: out of memory.
Fehler: syntax error.
Fehler: Incorrect command.
Fehler: syntax error.
Syntaxfehler in Zeile 159
Syntax errors are detected in generated GRUB config file.
Ensure that there are no errors in /etc/default/grub
and /etc/grub.d/* files or please file a bug report with
/boot/grub/grub.cfg.new file attached.
+ err '[!] Error during grub menu creation (grub/ grub-btrfs error)' '[0;31m'
+ echo '[0;31m[!]' Error during grub menu creation '(grub/' grub-btrfs 'error)[0m'
[0;31m[!] Error during grub menu creation (grub/ grub-btrfs error)[0m
+ '[' true = true ']'
+ logger -p user.error -t grub-btrfsd '[!] Error during grub menu creation (grub/ grub-btrfs error)'
+ '[' 1 -gt 1 ']'
+ set -x
Offline
Fehler: out of memory.
Fehler: syntax error.
Fehler: Incorrect command.
Fehler: syntax error.
Syntaxfehler in Zeile 159
Syntax errors are detected in generated GRUB config file.
df -h
cat /boot/grub/grub.cfg.new | curl -F 'file=@-' 0x0.st
Offline
df -h
Dateisystem Größe Benutzt Verf. Verw% Eingehängt auf
dev 16G 0 16G 0% /dev
run 16G 1,5M 16G 1% /run
/dev/sda2 466G 12G 453G 3% /
tmpfs 16G 22M 16G 1% /dev/shm
/dev/sda2 466G 12G 453G 3% /.snapshots
/dev/sda2 466G 12G 453G 3% /var/cache
/dev/sda2 466G 12G 453G 3% /var/log
tmpfs 16G 14M 16G 1% /tmp
/dev/sdc2 924G 3,5G 919G 1% /home
/dev/sdb1 1,9T 430G 1,4T 24% /run/media/andre/platte2
/dev/sda1 511M 113M 399M 23% /boot
tmpfs 3,2G 160K 3,2G 1% /run/user/1000
/dev/sdd1 30G 1,3G 29G 5% /run/media/andre/USB_P
cat /boot/grub/grub.cfg.new | curl -F 'file=@-' 0x0.st
cat: /boot/grub/grub.cfg.new: Datei oder Verzeichnis nicht gefunden
Offline
Ich habe ein script runter geladen und es scheint zu funktionieren.
Vielen Dank für die Hilfe...
Offline
Du has *was* für ein script runtergeladen und *wie* scheint es zu funktionieren?
Ausgehend von den bisherigen Erkenntnissen hätte ich mir als nächstes angeschaut, mit welchen Rechten grub-btrfsd überhaup läuft, bzw. die fehlherhafte /boot/grub/grub.cfg.new (so sie je geschrieben wird) gesichert.
ps aux | grep grub-btrfsd
sudo cat /boot/grub/grub.cfg | curl -F 'file=@-' 0x0.st
Offline
Das "grub-btrfsd" hab ich genommen und es funktioniert...
https://github.com/Antynea/grub-btrfs
Edit:
ps aux | grep grub-btrfsd
root 39154 0.0 0.0 8812 4300 ? Ss 21:04 0:00 bash /usr/bin/grub-btrfsd --syslog --timeshift-auto
root 39157 0.0 0.0 8812 2820 ? S 21:04 0:00 bash /usr/bin/grub-btrfsd --syslog --timeshift-auto
andre 42091 0.0 0.0 7640 2632 pts/0 S+ 21:06 0:00 grep --color=auto grub-btrfsd
Last edited by barnd3 (2023-08-25 19:08:22)
Offline
Und was hast Du vorher benutzt??
grub.cfg sieht ok aus - jedenfalls ist da kein Fehler in Zeile 159 oder der näheren Umgebung.
Offline
Oh ich habe das alte Script leider nicht gesichert...
Aber solange es funktioniert, bin ich zufrieden.
Offline