0 Mitglieder und 1 Gast betrachten dieses Thema.
System: Host: thk-htpc Kernel: 4.19.0-12-amd64 x86_64 bits: 64 Desktop: Xfce 4.12.4 Distro: Debian GNU/Linux 10 (buster) Machine: Type: Desktop Mobo: N/A model: N/A serial: <filter> BIOS: American Megatrends v: 080015 date: 08/13/2009 CPU: Topology: Dual Core model: Intel Atom 330 bits: 64 type: MT MCP L2 cache: 512 KiB Speed: 1600 MHz min/max: N/A Core speeds (MHz): 1: 1600 2: 1600 3: 1600 4: 1600 Graphics: Device-1: NVIDIA ION VGA driver: nouveau v: kernel Display: x11 server: X.Org 1.20.4 driver: modesetting unloaded: fbdev,vesa resolution: 1920x1080~60Hz OpenGL: renderer: NVAC v: 3.3 Mesa 18.3.6 Audio: Device-1: MCS type: USB driver: snd-usb-audio Sound Server: ALSA v: k4.19.0-12-amd64 Network: Device-1: NVIDIA MCP79 Ethernet driver: forcedeth IF: enp0s10 state: up speed: 100 Mbps duplex: full mac: <filter> Device-2: Qualcomm Atheros AR928X Wireless Network Adapter driver: ath9k IF: wlp4s0 state: down mac: <filter> Drives: Local Storage: total: 232.89 GiB used: 9.24 GiB (4.0%) ID-1: /dev/sda vendor: Crucial model: CT250BX100SSD1 size: 232.89 GiB Partition: ID-1: / size: 81.38 GiB used: 9.24 GiB (11.4%) fs: ext4 dev: /dev/sda8 ID-2: swap-1 size: 3.25 GiB used: 0 KiB (0.0%) fs: swap dev: /dev/sda9 Sensors: System Temperatures: cpu: 86.0 C mobo: N/A gpu: nouveau temp: 50 C Fan Speeds (RPM): N/A Info: Processes: 163 Uptime: 12m Memory: 3.18 GiB used: 935.3 MiB (28.7%) Shell: bash inxi: 3.0.32
#!/bin/shexec tail -n +3 $0# 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.menuentry "Windows 7" --class windows --class os { insmod ntfs search --no-floppy --set=root --fs-uuid 01D*************** ntldr /bootmgr}menuentry "Daphile" --class windows --class os { insmod ext4 search --no-floppy --set=root --fs-uuid f26802e7-8b68-46XXXXXXXXXXXXXX21 ntldr /bootmgr}
refix="/usr"exec_prefix="/usr"datarootdir="/usr/share"quick_boot="0"export TEXTDOMAIN=grubexport TEXTDOMAINDIR="${datarootdir}/locale". "$pkgdatadir/grub-mkconfig_lib"found_other_os=adjust_timeout () { if [ "$quick_boot" = 1 ] && [ "x${found_other_os}" != "x" ]; then cat << EOFset timeout_style=menuif [ "\${timeout}" = 0 ]; then set timeout=10fiEOF fi}if [ "x${GRUB_DISABLE_OS_PROBER}" = "xtrue" ]; then exit 0fiif [ -z "`which os-prober 2> /dev/null`" ] || [ -z "`which linux-boot-prober 2> /dev/null`" ] ; then # missing os-prober and/or linux-boot-prober exit 0fiOSPROBED="`os-prober | tr ' ' '^' | paste -s -d ' '`"if [ -z "${OSPROBED}" ] ; then # empty os-prober output, nothing doing exit 0fiosx_entry() { found_other_os=1 if [ x$2 = x32 ]; then # TRANSLATORS: it refers to kernel architecture (32-bit) bitstr="$(gettext "(32-bit)")" else # TRANSLATORS: it refers to kernel architecture (64-bit) bitstr="$(gettext "(64-bit)")" fi # TRANSLATORS: it refers on the OS residing on device %s onstr="$(gettext_printf "(on %s)" "${DEVICE}")" cat << EOFmenuentry '$(echo "${LONGNAME} $bitstr $onstr" | grub_quote)' --class osx --class darwin --class os \$menuentry_id_option 'osprober-xnu-$2-$(grub_get_device_id "${DEVICE}")' {EOF save_default_entry | grub_add_tab prepare_grub_to_access_device ${DEVICE} | grub_add_tab cat << EOF load_video set do_resume=0 if [ /var/vm/sleepimage -nt10 / ]; then if xnu_resume /var/vm/sleepimage; then set do_resume=1 fi fi if [ \$do_resume = 0 ]; then xnu_uuid ${OSXUUID} uuid if [ -f /Extra/DSDT.aml ]; then acpi -e /Extra/DSDT.aml fi if [ /kernelcache -nt /System/Library/Extensions ]; then $1 /kernelcache boot-uuid=\${uuid} rd=*uuid elif [ -f /System/Library/Kernels/kernel ]; then $1 /System/Library/Kernels/kernel boot-uuid=\${uuid} rd=*uuid xnu_kextdir /System/Library/Extensions else $1 /mach_kernel boot-uuid=\${uuid} rd=*uuid if [ /System/Library/Extensions.mkext -nt /System/Library/Extensions ]; then xnu_mkext /System/Library/Extensions.mkext else xnu_kextdir /System/Library/Extensions fi fi if [ -f /Extra/Extensions.mkext ]; then xnu_mkext /Extra/Extensions.mkext fi if [ -d /Extra/Extensions ]; then xnu_kextdir /Extra/Extensions fi if [ -f /Extra/devprop.bin ]; then xnu_devprop_load /Extra/devprop.bin fi if [ -f /Extra/splash.jpg ]; then insmod jpeg xnu_splash /Extra/splash.jpg fi if [ -f /Extra/splash.png ]; then insmod png xnu_splash /Extra/splash.png fi if [ -f /Extra/splash.tga ]; then insmod tga xnu_splash /Extra/splash.tga fi fi}EOF}used_osprober_linux_ids=wubi=for OS in ${OSPROBED} ; do DEVICE="`echo ${OS} | cut -d ':' -f 1`" LONGNAME="`echo ${OS} | cut -d ':' -f 2 | tr '^' ' '`" LABEL="`echo ${OS} | cut -d ':' -f 3 | tr '^' ' '`" BOOT="`echo ${OS} | cut -d ':' -f 4`" if UUID="`${grub_probe} --target=fs_uuid --device ${DEVICE%@*}`"; then EXPUUID="$UUID" if [ x"${DEVICE#*@}" != x ] ; then EXPUUID="${EXPUUID}@${DEVICE#*@}" fi if [ "x${GRUB_OS_PROBER_SKIP_LIST}" != "x" ] && [ "x`echo ${GRUB_OS_PROBER_SKIP_LIST} | grep -i -e '\b'${EXPUUID}'\b'`" != "x" ] ; then echo "Skipped ${LONGNAME} on ${DEVICE} by user request." >&2 continue fi fi BTRFS="`echo ${OS} | cut -d ':' -f 5`" if [ "x$BTRFS" = "xbtrfs" ]; then BTRFSuuid="`echo ${OS} | cut -d ':' -f 6`" BTRFSsubvol="`echo ${OS} | cut -d ':' -f 7`" fi if [ -z "${LONGNAME}" ] ; then LONGNAME="${LABEL}" fi # os-prober returns text string followed by optional counter CLASS="--class $(echo "${LABEL}" | LC_ALL=C sed 's,[[:digit:]]*$,,' | cut -d' ' -f1 | tr 'A-Z' 'a-z' | LC_ALL=C sed 's,[^[:alnum:]_],_,g')" gettext_printf "Found %s on %s\n" "${LONGNAME}" "${DEVICE}" >&2 case ${BOOT} in chain) case ${LONGNAME} in Windows*) if [ -z "$wubi" ]; then if [ -x /usr/share/lupin-support/grub-mkimage ] && \ /usr/share/lupin-support/grub-mkimage --test; then wubi=yes else wubi=no fi fi if [ "$wubi" = yes ]; then echo "Skipping ${LONGNAME} on Wubi system" >&2 continue fi ;; esac found_other_os=1 onstr="$(gettext_printf "(on %s)" "${DEVICE}")" cat << EOFmenuentry '$(echo "${LONGNAME} $onstr" | grub_quote)' $CLASS --class os \$menuentry_id_option 'osprober-chain-$(grub_get_device_id "${DEVICE}")' {EOF save_default_entry | grub_add_tab prepare_grub_to_access_device ${DEVICE} | grub_add_tab if [ x"`${grub_probe} --device ${DEVICE} --target=partmap`" = xmsdos ]; then cat << EOF parttool \${root} hidden-EOF fi case ${LONGNAME} in Windows\ Vista*|Windows\ 7*|Windows\ Server\ 2008*) ;; *) cat << EOF drivemap -s (hd0) \${root}EOF ;; esac cat <<EOF chainloader +1}EOF ;; efi) found_other_os=1 EFIPATH=${DEVICE#*@} DEVICE=${DEVICE%@*} onstr="$(gettext_printf "(on %s)" "${DEVICE}")" cat << EOFmenuentry '$(echo "${LONGNAME} $onstr" | grub_quote)' $CLASS --class os \$menuentry_id_option 'osprober-efi-$(grub_get_device_id "${DEVICE}")' {EOF save_default_entry | sed -e "s/^/\t/" prepare_grub_to_access_device ${DEVICE} | sed -e "s/^/\t/" cat <<EOF chainloader ${EFIPATH}}EOF ;; linux) if [ "x$BTRFS" = "xbtrfs" ]; then LINUXPROBED="`linux-boot-prober btrfs ${BTRFSuuid} ${BTRFSsubvol} 2> /dev/null | tr ' ' '^' | paste -s -d ' '`" else LINUXPROBED="`linux-boot-prober ${DEVICE} 2> /dev/null | tr ' ' '^' | paste -s -d ' '`" fi prepare_boot_cache= boot_device_id= is_top_level=true title_correction_code= OS="${LONGNAME}" for LINUX in ${LINUXPROBED} ; do LROOT="`echo ${LINUX} | cut -d ':' -f 1`" LBOOT="`echo ${LINUX} | cut -d ':' -f 2`" LLABEL="`echo ${LINUX} | cut -d ':' -f 3 | tr '^' ' '`" LKERNEL="`echo ${LINUX} | cut -d ':' -f 4`" LINITRD="`echo ${LINUX} | cut -d ':' -f 5`" LPARAMS="`echo ${LINUX} | cut -d ':' -f 6- | tr '^' ' '`" if [ -z "${LLABEL}" ] ; then LLABEL="${LONGNAME}" fi if [ "${LROOT}" != "${LBOOT}" ]; then LKERNEL="${LKERNEL#/boot}" LINITRD="${LINITRD#/boot}" fi if [ -z "${prepare_boot_cache}" ]; then prepare_boot_cache="$(prepare_grub_to_access_device ${LBOOT} | grub_add_tab)" [ "${prepare_boot_cache}" ] || continue fi found_other_os=1 onstr="$(gettext_printf "(on %s)" "${DEVICE}")" recovery_params="$(echo "${LPARAMS}" | grep 'single\|recovery')" || true counter=1 while echo "$used_osprober_linux_ids" | grep 'osprober-gnulinux-$LKERNEL-${recovery_params}-$counter-$boot_device_id' > /dev/null; do counter=$((counter+1)); done if [ -z "$boot_device_id" ]; then boot_device_id="$(grub_get_device_id "${DEVICE}")" fi used_osprober_linux_ids="$used_osprober_linux_ids 'osprober-gnulinux-$LKERNEL-${recovery_params}-$counter-$boot_device_id'" if [ "x$is_top_level" = xtrue ] && [ "x${GRUB_DISABLE_SUBMENU}" != xy ]; then cat << EOFmenuentry '$(echo "$OS $onstr" | grub_quote)' $CLASS --class gnu-linux --class gnu --class os \$menuentry_id_option 'osprober-gnulinux-simple-$boot_device_id' {EOF save_default_entry | grub_add_tab printf '%s\n' "${prepare_boot_cache}" cat << EOF linux ${LKERNEL} ${LPARAMS}EOF if [ -n "${LINITRD}" ] ; then cat << EOF initrd ${LINITRD}EOF fi cat << EOF}EOF echo "submenu '$(gettext_printf "Advanced options for %s" "${OS} $onstr" | grub_quote)' \$menuentry_id_option 'osprober-gnulinux-advanced-$boot_device_id' {" is_top_level=false fi title="${LLABEL} $onstr" cat << EOF menuentry '$(echo "$title" | grub_quote)' --class gnu-linux --class gnu --class os \$menuentry_id_option 'osprober-gnulinux-$LKERNEL-${recovery_params}-$boot_device_id' {EOF save_default_entry | sed -e "s/^/$grub_tab$grub_tab/" printf '%s\n' "${prepare_boot_cache}" | grub_add_tab cat << EOF linux ${LKERNEL} ${LPARAMS}EOF if [ -n "${LINITRD}" ] ; then cat << EOF initrd ${LINITRD}EOF fi cat << EOF }EOF if [ x"$title" = x"$GRUB_ACTUAL_DEFAULT" ] || [ x"Previous Linux versions>$title" = x"$GRUB_ACTUAL_DEFAULT" ]; then replacement_title="$(echo "Advanced options for ${OS} $onstr" | sed 's,>,>>,g')>$(echo "$title" | sed 's,>,>>,g')" quoted="$(echo "$GRUB_ACTUAL_DEFAULT" | grub_quote)" title_correction_code="${title_correction_code}if [ \"x\$default\" = '$quoted' ]; then default='$(echo "$replacement_title" | grub_quote)'; fi;" grub_warn "$(gettext_printf "Please don't use old title \`%s' for GRUB_DEFAULT, use \`%s' (for versions before 2.00) or \`%s' (for 2.00 or later)" "$GRUB_ACTUAL_DEFAULT" "$replacement_title" "gnulinux-advanced-$boot_device_id>gnulinux-$version-$type-$boot_device_id")" fi done if [ x"$is_top_level" != xtrue ]; then echo '}' fi echo "$title_correction_code" ;; macosx) if [ "${UUID}" ]; then OSXUUID="${UUID}" osx_entry xnu_kernel 32 osx_entry xnu_kernel64 64 fi ;; hurd) found_other_os=1 onstr="$(gettext_printf "(on %s)" "${DEVICE}")" cat << EOFmenuentry '$(echo "${LONGNAME} $onstr" | grub_quote)' --class hurd --class gnu --class os \$menuentry_id_option 'osprober-gnuhurd-/boot/gnumach.gz-false-$(grub_get_device_id "${DEVICE}")' {EOF save_default_entry | grub_add_tab prepare_grub_to_access_device ${DEVICE} | grub_add_tab grub_device="`${grub_probe} --device ${DEVICE} --target=drive`" mach_device="`echo "${grub_device}" | sed -e 's/(\(hd.*\),msdos\(.*\))/\1s\2/'`" grub_fs="`${grub_probe} --device ${DEVICE} --target=fs`" case "${grub_fs}" in *fs) hurd_fs="${grub_fs}" ;; *) hurd_fs="${grub_fs}fs" ;; esac cat << EOF multiboot /boot/gnumach.gz root=device:${mach_device} module /hurd/${hurd_fs}.static ${hurd_fs} --readonly \\ --multiboot-command-line='\${kernel-command-line}' \\ --host-priv-port='\${host-port}' \\ --device-master-port='\${device-port}' \\ --exec-server-task='\${exec-task}' -T typed '\${root}' \\ '\$(task-create)' '\$(task-resume)' module /lib/ld.so.1 exec /hurd/exec '\$(exec-task=task-create)'}EOF ;; minix) cat << EOFmenuentry "${LONGNAME} (on ${DEVICE}, Multiboot)" {EOF save_default_entry | sed -e "s/^/\t/" prepare_grub_to_access_device ${DEVICE} | sed -e "s/^/\t/" cat << EOF multiboot /boot/image_latest}EOF ;; *) # TRANSLATORS: %s is replaced by OS name. gettext_printf "%s is not yet supported by grub-mkconfig.\n" " ${LONGNAME}" >&2 ;; esacdoneadjust_timeout
sudo update-grub
sudo parted --list
[ -d /sys/firmware/efi ] && echo UEFI || echo BIOS
GRUB-Konfigurationsdatei wird erstellt …Found background image: /usr/share/images/desktop-base/desktop-grub.pngLinux-Abbild gefunden: /boot/vmlinuz-4.19.0-12-amd64initrd-Abbild gefunden: /boot/initrd.img-4.19.0-12-amd64Linux-Abbild gefunden: /boot/vmlinuz-4.19.0-11-amd64initrd-Abbild gefunden: /boot/initrd.img-4.19.0-11-amd64Windows 7 auf /dev/sda2 gefundenerledigt
Model: ATA CT250BX100SSD1 (scsi)Disk /dev/sda: 250GBSector size (logical/physical): 512B/512BPartition Table: msdosDisk Flags: Number Start End Size Type File system Flags 1 1049kB 368MB 367MB primary ntfs 2 368MB 97,0GB 96,6GB primary ntfs boot 3 97,0GB 250GB 153GB extended lba 5 97,0GB 145GB 48,2GB logical ntfs 7 145GB 156GB 10,5GB logical ext4 6 156GB 157GB 1509MB logical ext4 8 157GB 247GB 89,3GB logical ext4 9 247GB 250GB 3488MB logical linux-swap(v1)
BIOS
4=Wo ist vier?
#menuentry "Daphile on /dev/sda6" {insmod ext2set root=(hd0,6)chainloader +1}
menuentry "Daphile on /dev/sda6" { insmod chain insmod ext2 set root=(hd0,6) chainloader +1}
[code]menuentry "Daphile on /dev/sda6" { insmod chain insmod ext4 set root=(hd0,6) chainloader +1}
Dann habe ich mir irgendwie den Zugang zu Win7 verbaut. Jetzt habe ich die Linux-Partition mit der Debian-Distro neu aufgesetzt. seit dem geht das Booten des Daphile nicht mehr.
Grundsätzlich gehört Grub dem OS, das als letztes installiert wurde.
Bei UEFI wird es noch komplizierter.
… komme ich nun mit grub2 nicht weiter beim Einbinden des 2. Linux Betriebssystem (Daphile) in die Grub-Auswahl.
...ich habe mich Gestern mit chainload beschäftigt. Zu meinem Glück ist "Daphile" sogar schon dafür ausgelegt den Booteintrag in den PBR zu schreiben. Trotzdem bekomme ich bei "sudo update-grub" schon keine Nachricht, dass die Daphile-Partition (sda6) gefunden wurde. Entsprechend wird bei der Auswahl "Daphile" im Bootmenu nur der "_" dauerhaft, blinkend angezeigt.Da ich mehrere Schreibweisen für die "40_custom" gesehen habe, habe ich einiges ohne Erfolg probiert.
Medium /dev/sda: 465,8 GiB, 500107862016 Bytes, 976773168 SektorenEinheiten: sectors von 1 * 512 = 512 BytesSektorengröße (logisch/physisch): 512 Bytes / 512 BytesI/O Größe (minimal/optimal): 512 Bytes / 512 BytesTyp der Medienbezeichnung: dosGerät Boot Start Ende Sektoren Größe Id Typ/dev/sda1 * 2048 199999487 199997440 95,4G 83 Linux/dev/sda2 199999488 499998719 299999232 143,1G 83 Linux/dev/sda3 499998720 976768064 476769345 227,3G 5 Erweiterte/dev/sda5 500000768 709715967 209715200 100G 83 Linux
...Da ich mehrere Schreibweisen für die "40_custom" gesehen habe, habe ich einiges ohne Erfolg probiert. z.B:...
menuentry "Daphile on /dev/sda6" {insmod ext2set root=(hd0,6)chainloader +1}
menuentry "Daphile on /dev/sda6" { insmod chain insmod ext4 set root=(hd0,6) chainloader +1}
GRUB_DEFAULT=savedGRUB_SAVEDEFAULT=true
...Mir ist nicht bekannt, dass noch zusätzlich gemacht wird. Hiermit funktioniert es bei mir leider nicht.
Jetzt möchte ich noch, dass Grub2 sich meine vorherige Auswahl merkt. Das klappt leider nicht mit den Einträgen:Code: [Auswählen]GRUB_DEFAULT=savedGRUB_SAVEDEFAULT=truein die /etc/default/grub.Mir ist nicht bekannt, was noch zusätzlich gemacht werden müsste.Nur mit diesem Code funktioniert es bei mir leider nicht.
...da steht doch nichts dazu wie man die vorriege Auswahl speichert. Deine Antwort passt hier leider nicht. Vielleicht war ichmissverständlich. Hier nochmal ohne Schreibfehler: