基本上我在笔记本电脑上双启动了 ubuntu 和 windows,但问题是 windows 在双启动后就消失了
这基本上就是我所做的:
1 在我的 Windows 上下载了 unetbootin
2 下载 lubuntu iso
3.为lubuntu创建分区
4.在lubuntu中启动
5 完成lubuntu的设置
大约几周...
6 下载了 kde plasma(也下载了 ubuntu)
7.切换到kde plasma
几天后……
8 检查我的启动菜单是否有 windows,但没有
9.尝试修复它,但都导致我重新安装 windows 或 ubuntu,这可能不是问题(我认为)
- 陷入死胡同,试图找到答案
这基本上就是我记得做过的事情,所以不太准确。
现在我知道我的笔记本电脑上有 Windows,因为分区存在
但在 grub 菜单上找不到它
尝试过 Grub 更新
没用
尝试在 grub 上添加自定义启动选项
没用
尝试使用启动修复
但它只是说 windows 在 uefi 上,或者WINDOWSEFI DETECTED
即使它不在 uefi 上,它在 legacy 上,因为我甚至不记得将启动更改为 uefi,甚至不记得切换到 uefi 模式
向社区询问如何解决此问题
他们说要么在 uefi 上重新安装 ubuntu,要么在 legacy 上重新安装 windows(可能是因为我不太会解释这个问题)
这是我解决问题的所有线索或解决方案:
============================== Boot Info Summary ===============================
=> Grub2 (v2.00) is installed in the MBR of /dev/sda and looks at sector 1 of
the same hard drive for core.img. core.img is at this location and looks
for (,msdos6)/boot/grub. It also embeds following components:
modules
---------------------------------------------------------------------------
fshelp ext2 part_msdos biosdisk
---------------------------------------------------------------------------
sda1: __________________________________________________________________________
File system: ntfs
Boot sector type: Grub2 (v1.99-2.00)
Boot sector info: Grub2 (v2.00) is installed in the boot sector of sda1
and looks at sector 783190272 of the same hard drive
for core.img. core.img is at this location and looks
for (,msdos6)/boot/grub. It also embeds following
components:
modules
-------------------------------------------------------
fshelp ext2 part_msdos biosdisk
-------------------------------------------------------
-------------------------. No errors found in the Boot
Parameter Block.
Operating System: Windows 10 or 11
Boot files: /boot.ini /bootmgr /Boot/BCD
/Windows/System32/winload.exe
sda2: __________________________________________________________________________
File system: ntfs
Boot sector type: NTFS
Boot sector info: No errors found in the Boot Parameter Block.
Operating System:
Boot files:
sda3: __________________________________________________________________________
File system: Extended Partition
Boot sector type: -
Boot sector info:
sda5: __________________________________________________________________________
File system: ntfs
Boot sector type: SYSLINUX 4.07 2013-07-25
Boot sector info: Syslinux looks at sector 25136 of /dev/sda5 for its
second stage. SYSLINUX is installed in the /uui
directory. According to the info in the boot sector,
sda5 starts at sector 2048.
Boot file info: Grub2 (v2.00) in the file
/lubuntu-22.04.3-desktop-amd64.iso looks at sector 0
of the same hard drive for core.img, but core.img can
not be found at this location.
Operating System:
Boot files: /boot/grub/menu.lst
sda6: __________________________________________________________________________
File system: ext4
Boot sector type: -
Boot sector info:
Operating System: Ubuntu 22.04.3 LTS
Boot files: /boot/grub/grub.cfg /etc/fstab /etc/default/grub
/boot/grub/i386-pc/core.img
sda4: __________________________________________________________________________
File system: ntfs
Boot sector type: NTFS
Boot sector info: No errors found in the Boot Parameter Block.
Operating System:
Boot files:
================================ 2 OS detected =================================
OS#1: The OS now in use - Ubuntu 22.04.3 LTS on sda6
OS#2: Windows 10 or 11 on sda1
================================ Host/Hardware =================================
CPU architecture: 64-bit
Video: 3rd Gen Core processor Graphics Controller from Intel Corporation
BOOT_IMAGE of the installed session in use:
/boot/vmlinuz-6.5.0-14-generic root=UUID=debbb09f-4b76-47c6-a6e5-96bebd24b66e ro quiet splash vt.handoff=7
df -Th / : /dev/sda6 ext4 203G 122G 71G 64% /
===================================== UEFI =====================================
BIOS/UEFI firmware: R0200DA(2.0) from Insyde Corp.
The firmware is EFI-compatible, but this installed-session is in Legacy/BIOS/CSM mode (not in EFI mode).
d41d8cd98f00b204e9800998ecf8427e sda4/Boot/bootx64.efi
64349b3622c65f495a99dbf6102496e3 sda1/boot/bootx64.efi
dbb73486aa1fffa648f99f31f209f545 sda1/boot/grubx64.efi
a660182adef313615746a665966d2ccc sda1/boot/mmx64.efi
4c0946eb0d0bdb42144a42b77ec4b6cd sda1/Microsoft/Boot/bootmgfw.efi
e5ce0ea9e43b188dadc15eec1e4cdcb6 sda1/Microsoft/Boot/bootmgr.efi
============================= Drive/Partition Info =============================
Disks info: ____________________________________________________________________
sda : notGPT, no-BIOSboot, has-noESP, not-usb, not-mmc, has-os, has-win, 2048 sectors * 512 bytes
Partitions info (1/3): _________________________________________________________
sda6 : is-os, 64, apt-get, grub-pc , grub2, grub-install, grubenv-ok, update-grub, end-after-100GB
sda4 : no-os, 64, nopakmgr, no-docgrub, nogrub, nogrubinstall, no-grubenv, noupdategrub, end-after-100GB
sda2 : no-os, 64, nopakmgr, no-docgrub, nogrub, nogrubinstall, no-grubenv, noupdategrub, end-after-100GB
sda5 : no-os, 64, nopakmgr, no-docgrub, nogrub, nogrubinstall, no-grubenv, noupdategrub, end-after-100GB
sda1 : is-os, 64, nopakmgr, no-docgrub, nogrub, nogrubinstall, no-grubenv, noupdategrub, end-after-100GB
Partitions info (2/3): _________________________________________________________
sda6 : isnotESP, fstab-without-efi, no-nt, no-winload, no-recov-nor-hid, no-bmgr, notwinboot
sda4 : isnotESP, part-has-no-fstab, no-nt, no-winload, no-recov-nor-hid, no-bmgr, notwinboot
sda2 : isnotESP, part-has-no-fstab, no-nt, no-winload, no-recov-nor-hid, no-bmgr, notwinboot
sda5 : isnotESP, part-has-no-fstab, no-nt, no-winload, no-recov-nor-hid, no-bmgr, notwinboot
sda1 : isnotESP, part-has-no-fstab, no-nt, haswinload, no-recov-nor-hid, bootmgr, is-winboot
Partitions info (3/3): _________________________________________________________
sda6 : not--sepboot, with-boot, fstab-without-boot, not-sep-usr, with--usr, fstab-without-usr, std-grub.d, sda
sda4 : not--sepboot, no---boot, part-has-no-fstab, not-sep-usr, no---usr, part-has-no-fstab, no--grub.d, sda
sda2 : not--sepboot, no---boot, part-has-no-fstab, not-sep-usr, no---usr, part-has-no-fstab, no--grub.d, sda
sda5 : is---sepboot, no-kernel, part-has-no-fstab, not-sep-usr, no---usr, part-has-no-fstab, no--grub.d, sda
sda1 : not--sepboot, no---boot, part-has-no-fstab, not-sep-usr, no---usr, part-has-no-fstab, no--grub.d, sda
fdisk -l (filtered): ___________________________________________________________
Disk sda: 465.76 GiB, 500107862016 bytes, 976773168 sectors
Disk identifier: 0x348654d8
Boot Start End Sectors Size Id Type
sda1 * 17213440 457623975 440410536 210G 7 HPFS/NTFS/exFAT
sda2 457625600 459370495 1744896 852M 27 Hidden NTFS WinRE
sda3 459370496 909731839 450361344 214.7G f W95 Ext'd (LBA)
sda4 909731840 976773119 67041280 32G 7 HPFS/NTFS/exFAT
sda5 893349888 909731839 16381952 7.8G 7 HPFS/NTFS/exFAT
sda6 459372544 893347839 433975296 206.9G 83 Linux
Partition table entries are not in disk order.
Disk zram0: 3.82 GiB, 4096806912 bytes, 1000197 sectors
parted -lm (filtered): _________________________________________________________
sda:500GB:scsi:512:4096:msdos:ATA TOSHIBA MQ01ABF0:;
1:8813MB:234GB:225GB:ntfs::boot;
2:234GB:235GB:893MB:ntfs::msftres;
3:235GB:466GB:231GB:::lba;
6:235GB:457GB:222GB:ext4::;
5:457GB:466GB:8388MB:ntfs::;
4:466GB:500GB:34.3GB:ntfs::;
Free space >10MiB: ______________________________________________________________
sda: 0.03MiB:8405MiB:8405MiB
blkid (filtered): ______________________________________________________________
NAME FSTYPE UUID PARTUUID LABEL PARTLABEL
sda
├─sda1 ntfs 01D385036F91F970 348654d8-01
├─sda2 ntfs 0CF482D0F482BB88 348654d8-02
├─sda3 348654d8-03
├─sda4 ntfs 62DE21ACDE217985 348654d8-04 DriveE
├─sda5 ntfs C2FA1D79FA1D6B45 348654d8-05 UUI
└─sda6 ext4 debbb09f-4b76-47c6-a6e5-96bebd24b66e 348654d8-06
Mount points (filtered): _______________________________________________________
Avail Use% Mounted on
/dev/sda1 43.1G 79% /media/kingrain/01D385036F91F970
/dev/sda2 165.3M 81% /mnt/boot-sav/sda2
/dev/sda4 404K 100% /media/kingrain/DriveE
/dev/sda5 4.9G 37% /media/kingrain/UUI
/dev/sda6 70.7G 60% /
Mount options (filtered): ______________________________________________________
/dev/sda1 ntfs3 rw,nosuid,nodev,relatime,uid=1000,gid=1000,windows_names,iocharset=utf8
/dev/sda2 fuseblk rw,relatime,user_id=0,group_id=0,allow_other,blksize=4096
/dev/sda4 ntfs3 rw,nosuid,nodev,relatime,uid=1000,gid=1000,windows_names,iocharset=utf8
/dev/sda5 ntfs3 rw,nosuid,nodev,relatime,uid=1000,gid=1000,windows_names,iocharset=utf8
/dev/sda6 ext4 rw,relatime
=========================== sda1/boot.ini (filtered) ===========================
C:\ubnldr.mbr="UNetbootin"
====================== sda5/boot/grub/menu.lst (filtered) ======================
# This Menu created with Universal USB Installer https://www.pendrivelinux.com/universal-usb-installer-easy-as-1-2-3/
default 0
timeout 30
color NORMAL HIGHLIGHT HELPTEXT HEADING
foreground=FFFFFF
background=000000
title Boot lubuntu-22.04.3-desktop-amd64
set ISO=/lubuntu-22.04.3-desktop-amd64.iso
set CASPER=/writable
find --set-root %ISO%
map %ISO% (0xff)
#CLUG
map --hook
root (0xff)
kernel /casper/vmlinuz file=/cdrom/preseed/lubuntu.seed fsck.mode=skip cdrom-detect/try-usb=true noprompt boot=casper iso-scan/filename=%ISO% quiet --
initrd /casper/initrd
title Boot lubuntu-22.04.3-desktop-amd64 acpi=off
set ISO=/lubuntu-22.04.3-desktop-amd64.iso
set CASPER=/writable
find --set-root %ISO%
map %ISO% (0xff)
#CLUG
map --hook
root (0xff)
kernel /casper/vmlinuz file=/cdrom/preseed/lubuntu.seed fsck.mode=skip cdrom-detect/try-usb=true noprompt boot=casper iso-scan/filename=%ISO% quiet acpi=off --
initrd /casper/initrd
==================== sda5: Location of files loaded by Grub ====================
GiB - GB File Fragment(s)
428.861846924 = 460.486901760 boot/grub/menu.lst 1
428.860809326 = 460.485787648 vmlinuz 1
428.847053528 = 460.471017472 initrd 1
====================== sda6/boot/grub/grub.cfg (filtered) ======================
Ubuntu debbb09f-4b76-47c6-a6e5-96bebd24b66e
### END /etc/grub.d/30_os-prober ###
### END /etc/grub.d/30_uefi-firmware ###
Windows 10
========================== sda6/etc/fstab (filtered) ===========================
# <file system> <mount point> <type> <options> <dump> <pass>
UUID=debbb09f-4b76-47c6-a6e5-96bebd24b66e / ext4 defaults 0 1
/swapfile swap swap defaults 0 0
======================= sda6/etc/default/grub (filtered) =======================
GRUB_DEFAULT=0
GRUB_TIMEOUT_STYLE=hidden
GRUB_TIMEOUT=0
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX=""
GRUB_DISABLE_OS_PROBER=false
==================== sda6: Location of files loaded by Grub ====================
GiB - GB File Fragment(s)
250.150127411 = 268.596654080 boot/grub/grub.cfg 1
360.036392212 = 386.586132480 boot/grub/i386-pc/core.img 1
342.277896881 = 367.518093312 boot/vmlinuz 2
288.152496338 = 309.401387008 boot/vmlinuz-6.2.0-39-generic 1
342.277896881 = 367.518093312 boot/vmlinuz-6.5.0-14-generic 2
288.152496338 = 309.401387008 boot/vmlinuz.old 1
359.592769623 = 386.109796352 boot/initrd.img 6
340.035842896 = 365.110706176 boot/initrd.img-6.2.0-39-generic 2
359.592769623 = 386.109796352 boot/initrd.img-6.5.0-14-generic 6
340.035842896 = 365.110706176 boot/initrd.img.old 2
===================== sda6: ls -l /etc/grub.d/ (filtered) ======================
-rwxr-xr-x 1 root root 18683 Dis 19 2022 10_linux
-rwxr-xr-x 1 root root 43031 Dis 19 2022 10_linux_zfs
-rwxr-xr-x 1 root root 14387 Dis 19 2022 20_linux_xen
-rwxr-xr-x 1 root root 13369 Dis 19 2022 30_os-prober
-rwxr-xr-x 1 root root 1372 Dis 19 2022 30_uefi-firmware
-rwxr-xr-x 1 root root 700 May 17 2023 35_fwupd
-rwxr-xr-x 1 root root 374 Ene 5 12:57 40_custom
-rwxr-xr-x 1 root root 215 Dis 19 2022 41_custom
===================== sda6/etc/grub.d/40_custom (filtered) =====================
#!/bin/sh
exec 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 10" {
insmod part_msdos
insmod ntfs
set root=(hd0,msdos1) # Modify this to match your Windows partition
chainloader +1
}
Suggested repair: ______________________________________________________________
The default repair of the Boot-Repair utility would reinstall the grub2 of
sda6 into the MBR of sda.
Grub-efi would not be selected by default because no ESP detected.
Additional repair would be performed: unhide-bootmenu-10s
Blockers in case of suggested repair: __________________________________________
WindowsEFI detected. Please disable BIOS-compatibility/CSM/Legacy mode in your UEFI firmware, and use this software from a live-CD (or live-USB) that is compatible with UEFI booting mode. For example, use a live-USB of Boot-Repair-Disk-64bit (www.sourceforge.net/p/boot-repair-cd), after making sure your BIOS is set up to boot USB in EFI mode.
有些人建议我重新安装 ubuntu 或 windows。
我不明白其中的一些内容,因此将其交给专业人士,这就是我现在基本上可以提供的。我希望有人可以帮助我解决这个问题......
答案1
您的 sda1 是您的 Windows 启动分区。
“Grub2 (v2.00) 安装在 sda1 的引导扇区中”
BIOS 模式下的 Windows 需要 NTFS 分区中有 Windows 信息。您必须使用 Windows 修复命令来恢复 sda1 中的 Windows 启动扇区。
但是如果是 UEFI 系统,为什么 Windows 处于 BIOS 模式?自 2012 年以来,微软就要求供应商以 UEFI 启动模式安装到 gpt 分区驱动器。当您转换为 UEFI 时,请确保有良好的备份,因为 MBR(msdos) 到 gpt 会完全擦除驱动器。
Testdisk 也可以工作:
答案2
您是否尝试grub
在驱动器上重新安装:
sudo grub-install /dev/sda
sudo update-grub
运行,也许这样可以解决问题。另外,你能说一下如何/dev/sda1
在 grub 中手动添加驱动器吗?