1

I have a Sony Vaio and dual boot windows 10 and Ubuntu 16.04. All of the sudden, the main windows partition stopped working. It would just load infinitely. I tried to use boot repair to fix it. I don’t know if that could have even fixed it. Anyways, it did not work. So I am using Ubuntu. Then, I restarted my computer and now all of the sudden before I even get the option to choose an OS to boot, I get this error. It just brings me to vaio care. If I select start troubleshooting, I get the same error. I now have practically no use out of my computer and have no idea why it stopped working suddenly. Please help me at least be able to use one of my operating systems again. I do not want to lose data on either partition. Update: When I used boot-repair it told me to turn off secure boot in BIOS setup. Now, I discovered that the Ubuntu partition still works when Secure Boot is disabled, but not when it is enabled. When Secure Boot is enabled, I get the error stated above and can only access BIOS setup. If I try to access my Windows memory in Ubuntu, I get this error:

"Unable to Access 932 GB Volume" Error mounting /dev/sda5 at /media/millar/4484E74A84E73D54: Command-line `mount -t "ntfs" -o "uhelper=udisks2,nodev,nosuid,uid=1000,gid=1000" "/dev/sda5" "/media/millar/4484E74A84E73D54"' exited with non-zero exit status 14: The disk contains an unclean file system (0, 1).
Metadata kept in Windows cache, refused to mount.
Failed to mount '/dev/sda5': Operation not permitted
The NTFS partition is in an unsafe state. Please resume and shutdown
Windows fully (no hibernation or fast restarting), or mount the volume
read-only with the 'ro' mount option.

Contents of fstab file:

# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
# / was on /dev/sda10 during installation
UUID=3c429404-bec5-4f99-8d13-6f01585040cb /               ext4    errors=remount-ro 0       1
# /boot/efi was on /dev/sda3 during installation
#UUID=12E6-1CD7  /boot/efi       vfat    umask=0077      0       1
# swap was on /dev/sda9 during installation
UUID=7e7a010e-81fc-4de0-93c9-14cd77f4260f none            swap    sw              0       0
UUID=12E6-1CD7  /boot/efi   vfat    defaults    0   1

1 Answers1

0

The other question you refer to has a different disk, so I'll ignore it for this answer.

You a gpt partitioned disk with no MBR (so no legacy boot, good), with 10 partitions, two of which (sda1 and sda3, bad) appear to be (incomplete) EFI partitions. I looks like sda3 is the most complete, and is the one used, so you may treat sda1 as a backup.

To fix sda3, copy /EFI/ubuntu/grubx64.efi to /EFI/Boot/grubx64.efi.
When fstab is fixed (see below), sda3 will be mounted at /boot/efi.
You may also mount sda3 anywhere like /mnt on the live media if you like. Once mounted (below assumes /boot/efi), copy the files with the cp command.

cp /boot/efi/EFI/ubuntu/grubx64.efi  /boot/efi/EFI/Boot/grubx64.efi 

cp Then check that the size of /boot/efi/EFI/Boot/bootx64.efi is the same as /boot/efi/EFI/ubuntu/shimx64.efi -- if different, copy /boot/efi/EFI/ubuntu/shimx64.efi to /boot/efi/EFI/Boot/bootx64.efi (note the name change). That probably fixes the error message about missing /EFI/Boot/grubx64.efi. The /EFI/Boot files are a fallback bootloader, and this setup will boot with either secure boot enabled or disabled.

Fix the /etc/fstab file -- uncomment (remove the #) on the mount at /boot/efi of the EFI partition.

#UUID=12E6-1CD7  /boot/efi       vfat    umask=0077      0       1  

should be

UUID=12E6-1CD7  /boot/efi       vfat    umask=0077      0       1  

Windows seems to have been hibernated instead of shutdown. Also the filessystem is marked "dirty" (from your other question), so go into the Windows power options and make sure the "shutdown" is not set to "hibernate". You should be able to boot Windows directly from the EFI menu (some function key at power-up to select boot device/OS) -- just choose Windows. Run chkdsk on sda5 (probably Windows C:, check the size, or just chkdsk all the Windows "disks").

With Windows disks cleaned up and Windows shutdown properly, run

 sudo update-grub  

from Ubuntu, and that should update the grub menu to include Windows. Some machines may not boot Windows from Grub with secure boot enabled, so if you don't want to use the EFI menu to boot Windows, disable secure boot.

See oldfred's links for Sony tweaks.

At some point, you might backup the sda3 to sda1. It's good to have a copy of the EFI boot files in case something happens to the working set.

At some later date, you might clean up the old kernels in /boot by purging their packages.

ubfan1
  • 19,049