Dual install problem

Ubuntu Version:

Ubuntu Studio 24.04
Desktop Environment (if applicable):

KDE plasma 5.27.11

Problem Description:

Installed Ubuntu on legacy bios and initially the dual boot screen did not appear but could be seen by pressing shift key during boot. While trying to fix this, with fixes found on this site I appear to have done something bad as windows no longer appears as on option when I get the dual boot screen and when I look at the KDE partition manager windows no longer appears although the partition is still there it is simply listed as OS and does not give any information on amount of space used.
any help would be much appreciated!
Relevant System Information:

System is a dell inspiron 3847 desktop with an old i5. Windows 10 was the version and bios was legacy.

Screenshots or Error Messages:

What I’ve Tried:

I am trying to find how to get history from Bash but shift page up is not showing my anything.
I used History to get the following from Bash it goes back to when windows was avaliable in Dual boot window. I’m including it all as I’m not sure what is relevent.

1 df -h
2 sudo gedit
3 sudo gedit /etc/default/grub
4 sudo gedit/etc/default/grub
5 sudo geedit /etc/default/grub
6 sudo gedit
7 sudo cp /usr/share/grub/default/grub /etc/default/
8 sudo gedit /etc/default/grub
9 reboot
10 sudo
11 sudo gedit
12 sudo gedit /etc/default/grub
13 gedit
14 snap info gedit
15 sudo snap install gedit # version 46.1
16 sudo gedit /etc/default/grub
17 xhost si:localuser:root
18 sudo gedit /etc/default/grub
19 gedit
20 sudo gedit /etc/default/grub
21 sudo mkdir /run/user/0
22 sudo gedit /etc/default/grub
23 1s -1 .Xauthority
24 1s -1
25 1s -1 ~/.Xauthority
26 is -1 .Xauthority
27 sudo apt install ironseed
28 is -1 .Xauthority
29 sudo apt uninstall ironseed
30 1s -d */
31 1s
32 ls -d
33 ls
34 sudo gedit /etc/default/grub
35 ls -1 .Xauthority
36 ls -1 ~/.Xauthority
37 sudo update-grub
38 reboot
39 lsblk
40 sudo blkid /dev/sda2
41 fdisk -1
42 fdisl -l
43 fdisk -l
44 lsbk
45 Lsblk
46 lsblk
47 sudo update-grub
48 lsblk
49 sudo blkind /dev/sda2
50 sudo blkid /dev/sda2
51 blkid
52 lsblk
53 blkid /dev/sda1
54 blkid /dev/sda2
55 blkid /dev/sda3
56 blkid /dev/sda4
57 dpkg --get-selections | grep ^grub
58 scrolling
59 history

I should also add that I tried to reload from thumb drive hoping to fix dual boot, I asked it to add a copy of studio in addition to previous copy and OS
since it did not offer a option of replacing current version. That attempt failed and offered to send error report. I accepted that option but by the time I went through the sign up to get an account I think the error report was lost.


We would like to help you, but this doesn’t tell us what you did. Can you be more specific?

If you entered terminal commands, they are in your history. Show them to us.

Please show us. You can take screenshots. You can insert images. You can copy/paste terminal text output.

Ubuntu Studio doesn’t come with gedit. Replace gedit with kate, no sudo required as kate doesn’t need root access to edit a file, and it will prompt you for your password when you save.

It’s literally in the “Used” column in your screenshot.

As Ian said, this doesn’t tell us what you need. Please be more specific. I’m assuming GRUB doesn’t show (the boot menu).

That’s exactly why it cannot dual-boot. Windows needs UEFI to boot. Switching to legacy BIOS was unnecessary, Ubuntu Studio is fully capable of installing in a UEFI environment.

Since you switched to legacy BIOS, GRUB is unable to dual boot because os-prober, the mechanism that looks for other operating systems when configuring GRUB, could not find Windows since it’s not bootable in legacy BIOS.

Best thing you can do is switch back to UEFI boot and reinstall Ubuntu Studio. Only then will it be able to see the Windows installation.

The system was originally Legacy, I did not change that when I did the install. (system was originally Windows 7 and was apparently updated without changing the bios from Legacy (it is possible I am wrong about the windows version and I cant check now but Ubuntu was installed without changing the bios from Legacy.

The point I was making was that in the partition manager where the column used appears for the label OS (where Windows is loaded) it gives … as the amount of space used in contrast to the other entries where it gives a number in GB as the amount of space used.


GRUB is in the boot menu. here are the contemnts of the Grub menu

You can go back and edit posts, so no need for three separate posts. I fixed it for you.

Windows can switch back to legacy BIOS mode if it was installed in UEFI. I see a ~40MB FAT16 partition which might hold the Windows EFI data. This is why I’m fairly certain it was originally on UEFI.

KDE Partition Manager (or even GPartEd) cannot see the space available in the NTFS partition without the correct drivers. Installing ntfs-3g might help with this. The other thing that might be causing this is the “dirty” bit is set, meaning Windows needs to run a scan and fix stuff. This cannot be done from Linux in my experience.

This is irrellevant.

And you still haven’t made it clear what you’re asking. Please go back and edit your original post with a question.

Sorry I was wrong about the windows version, it is not 1, it may be 7 still.

I am asking for help to get back to being able to run windows.

Give the information on Windows version should I try to I change to UEFI and try to reboot?

This is exactly what I’ve been telling you.

Switched to UEFI more and system would not boot; tried to install from USB thumb drive and installer asked if I wanted to install next to old version of Ubuntu (did not mention OS) I said yes and installer encountered an error and would not continue. I switched back to Legacy so I could boot to previously installed Ubuntu but still can’t get back to Windows.
Once more I note that I did not change it to Legacy before install, It stared out on Legacy. After install I could initially get to windows by pressing shift key during boot sequence.

May be best to see details:

Please copy & paste the pastebin link to the BootInfo summary report ( do not post report), do not run the auto fix till reviewed. Use often updated ppa version with your USB installer or any working install over somewhat older ISO.

Boot-Repair - Community Help Wiki &
https://sourceforge.net/p/boot-repair/home/Home/

Posting the link from boot repair should give enough information for you to get help. If you originally had windows 7, it is likely to be a Legacy install. Microsoft requires an EFI install on a GPT disk and you can easily determine if it is GPT from Ubuntu by running the command: sudo parted -l That will Partition table which will likely be either GPT or dos/msdos. Another simple thing you can do from a terminal is log in as root (sudo) and run: ls /boot and see if there is an efi directory. If not, then it is a legacy install.

here is the result of parted -l and ls /boot

$ sudo parted -l
[sudo] password for ross-h-hill:
Model: ATA ST1000DM003-1CH1 (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: msdos
Disk Flags:

Number Start End Size Type File system Flags
1 32.3kB 41.1MB 41.1MB primary fat16 diag
2 41.9MB 23.3GB 23.3GB primary ntfs boot
3 23.3GB 478GB 454GB primary ntfs
4 478GB 1000GB 523GB primary ext4

ross-h-hill@ross-h-hill-Inspiron-3847:~$ ^C
ross-h-hill@ross-h-hill-Inspiron-3847:~$ ls /boot
config-6.8.0-52-lowlatency initrd.img-6.8.0-52-lowlatency memtest86+ia32.efi System.map-6.8.0-52-lowlatency vmlinuz.old
grub initrd.img.old memtest86+x64.bin vmlinuz
initrd.img memtest86+ia32.bin memtest86+x64.efi vmlinuz-6.8.0-52-lowlatency
ross-h-hill@ross-h-hill-Inspiron-3847:~$

Here is the link from boot-repair

https:paste.ubuntu.com/p/b8d3MQZdZZ/

I will reboot system and see if boot-repair fixed anything.

So now you know you have an msdos partition table and no efi partition containing a directory named Microsoft or ubuntu which would be there if it was EFI. So you have a Legacy install of both. The problem is from your earlier post where you indicated “While trying to fix this, with fixes found on this site”. I take that to mean you didn’t make notes of whatever steps you took which apparently failed so we have nothing to work with until you post the link after running boot repair with the Create BootInfo Summary option.

Looks like an old BIOS/MBR dual boot, except for this on line 21.
Could not detect USEDPERCENT of /dev/sda3 ().

That is your Windows install. Grub only boots working Windows or Windows that is not hibernated, fast startup is off, or no chkdsk required.
That it cannot read sda3 may indicate one of those issues.

Most Windows issues cannot be fixed from Linux. You need your Widnows repair/recovery drive or a Windows installer with repair console.

One disadvantage of old BIOS/MBR, is only one boot loader in MBR. And grub will multiple boot, but Windows will not. You may be able to temporaily install a Windows boot loader to MBR and see if it boots and lets you resolve issue. Then use Boot-Repair to restore grub.
Only with old BIOS/MBR, can Boot-Repair in its advanced mode let you choose a Windows type boot loader (syslinux) which will boot Windows. Grub does not use boot flag, but Windows & syslinux do use boot flag. Often best to use Windows tools to fix Windows.

Thanks to all who helped the issue is solved, dual boot now offers the choice to boot from windows. (Windows still doesn’t work properly and there appears to be a corrupted windows file but that’s an issue for elsewhere.)

Hmmmm windows 10 to uefi had to do that several months ago (come to think of it might have been a year ago) Which this actually only useful if you have Ubuntu on 1 drive and windows on another… some still refer to this as a dual boot even it really isn’t

here is the link to MS windows guide

You appear to have windows 10 so if you do not have a windows repair disk, you can download the iso and copy it to a USB to boot from and select the repair option and hope for the best. I’d read any instructions carefully if you have not done this before.

https://www.microsoft.com/en-us/software-download/windows10iso

1 Like

on my system the link I referenced worked
ONLY because Ubuntu was on one drive and Windows on it’s own separate drive
but @yancek have sage advice on when that is not the case and advise others to heed it

Thank you, this worked and Windows 10 is now working but the system boots directly to Windows now. Rather than trying to fix the dual boot again I think I should remove Ubuntu and change my boot to uefi from legacy then reinstall Ubuntu studio. (this would allow me to more easily update to Windows 11 at a latter point and since I haven’t done anything yet in Ubuntu Studio would cost little at this point.) My question is should I simply remove the ext4 sector via windows to remove Ubuntu or is there a better way?

If you want windows in uefi mode, you will need a GPT partition table and I don’t use windows so don’t know if that can be done without loss of data so do some research. If you installed windows and still have Ubuntu on the drive, windows default systems don’t boot Linux systems but you can use third party software such as EasyBCD from neosmart to do it. Remember that if you are installing both Windows and Linux on the same drive, they both need to be UEFI or they both need to be legacy installs.