Jump to content


 


Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.


Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.

Photo

REMOVE GRUB FROM SDA1 TO STOP SKIP & MANUAL OPTIONS


  • Please log in to reply
20 replies to this topic

#1 lacey16

lacey16

  • Members
  • 62 posts
  • OFFLINE
  •  
  • Local time:04:35 AM

Posted 14 May 2016 - 04:49 PM

Hi,

Im going back to this problem now but I have started a new thread as the position has changed. Hope thats ok.   

 

Original problem and previous post.    problem getting windows to mount in rw with ubuntu

 

 

 I did a clean install of windows 10 followed by Ubuntu. All fine. Dual Boot ok. ubuntu partitions on SSD drive & windows on SATA drive. A few days later intermittent power surges and cuts trashed win 10. It could not be fixed by recovery or repair so I had to reinstall windows to a system with Ubuntu already installed. It dual boots fine except that ubuntu will only mount windows as read only.

 

The problem is a 500mb unallocated partition at the beginning of the NTFS /C partition. because of this Ubuntu thinks that the windows partition is not ready and will therefore mount it in read only. I created this partition because of a windows error claiming no space for system reserved. Then they failed to use if for their bootloader UGH

Spent a long time researching to resolve this. First Windows is definitely not in hibernation:  Secure Boot, Fast Boot hibernation have all been disabled in the bios and on windows OS and its booting in legacy mode.

 

RESOLUTION:

I used an excellent partition manager Aomei to merge the 500mb free space with the windows partition. It then mounted the partition as rw.  The grub menu is:  Ubuntu : SDA1 and SDB1

SDA1 boots into a windows repair screen : SDB1 boots into windows OS

Is it possible to configure grub 2 to remove SDA1 from the system please.   This would stop boot up going into the Skip to continue Manual to repair screen.  If I fail to press Skip grub tries and fails to do a repair. Not a big problem just annoying.  Thanks

 

Having had a couple of weeks away from the original problem where the responses were focused on mounting SDB2 I came across this and wondered if the focus was too much on the partition as opposed to the disk but I may well be misunderstanding this: Perhaps the 500mb partition could have been set as primary with a windows letter say G and grub configured to boot from there:

 

Reinstalling GRUB 2 from a Working System

If Ubuntu is operating normally, boot into the working installation and run the following command from a terminal.

  • X is the drive (letter) on which you want GRUB to write the boot information. Normally users should not include a partition number, which would produce an error message as the command would attempt to write the information to a partition.

    sudo grub-install /dev/sdX  # Example: sudo grub-install /dev/sda

 

This will rewrite the MBR information to point to the current installation and rewrite some GRUB 2 files (which are already working). Since it isn't done during execution of the previous command, running sudo update-grub after the install will ensure GRUB 2's menu is up-to-date.

 

Or something like this:

 

mount -n -o remount,rw / dpkg --configure -a

One can change the type of mount containing the directory dir:

mount --make-shared dir

Anyway if this is rubbish just ignore it please    Just wondered if i was focusing in the wrong direction when trying to resolve the problem  Thanks

 

 

 

 

 



BC AdBot (Login to Remove)

 


#2 NickAu

NickAu

    Bleepin' Fish Doctor


  • Moderator
  • 12,416 posts
  • ONLINE
  •  
  • Gender:Male
  • Location:127.0.0.1 Australia
  • Local time:02:35 PM

Posted 14 May 2016 - 05:54 PM

Did you install both with secure boot ON? After installing Windows you boot from Ubuntu disk or USB but you select boot from UEFI option then install Ubuntu along side Windows?



#3 lacey16

lacey16
  • Topic Starter

  • Members
  • 62 posts
  • OFFLINE
  •  
  • Local time:04:35 AM

Posted 14 May 2016 - 07:27 PM

Thanks for such a fast reply

 

SSD & SATA both new drives.  Prior to installing anything I disabled secure boot/fast boot in the bios.  I did NOT enable CSM.  I installed windows and immediately disabled fast boot, secure boot and hibernation in the OS

Then installed Ubuntu.  No problems

 

   Then windows got trashed.     I left the ubuntu system intact  and reinstalled windows. The settings in the bios remained exactly the same and again immediately after installing windows I disabled all the fast boot/hibernation stuff. I also deleted windows hibernation file.

 

On the grub menu:  Ubuntu   sda    windows sdb1 & sdb2  windows booted up fine from both sdb1 & sdb2  but would only mount as read only.  Now that I have merged the 500mb unallocated partition onto the windows ntfs partition it boots fine on sdb1.      Thanks

 

 

After installing Windows you boot from Ubuntu disk or USB but you select boot from UEFI option then install Ubuntu along side Windows?

 

 

Ubuntu was already installed.

 

 

cheers



#4 lacey16

lacey16
  • Topic Starter

  • Members
  • 62 posts
  • OFFLINE
  •  
  • Local time:04:35 AM

Posted 15 May 2016 - 06:45 AM

Hoped this might make things clearer:   fdisk -l

 

 

   Device Boot      Start         End      Blocks   Id  System

/dev/sda1   *        2048     1026047      512000    7  HPFS/NTFS/exFAT

/dev/sda2         1026048   176807935    87890944   83  Linux

/dev/sda3       176809982   231495679    27342849    5  Extended

/dev/sda5       176809984   196339711     9764864   82  Linux swap / Solaris

/dev/sda6       196341760   231495679    17576960   83  Linux

 

Disk /dev/sdb: 500.1 GB, 500107862016 bytes

255 heads, 63 sectors/track, 60801 cylinders, total 976773168 sectors

Units = sectors of 1 * 512 = 512 bytes

Sector size (logical/physical): 512 bytes / 4096 bytes

I/O size (minimum/optimal): 4096 bytes / 4096 bytes

Disk identifier: 0x3767dd0a

 

   Device Boot      Start         End      Blocks   Id  System

/dev/sdb1   *          63   308239154   154119546    7  HPFS/NTFS/exFAT

Partition 1 does not start on physical sector boundary.

 
 
 sda1 boots into a windows repair screen.  Error  Files Missing     win/sys/32/winload-exe  obviously the MBR/Grub
 
sdb1 boots windows fine in full rw mode although it knows that it does not start on the physical boundary because of the 500mb unallocated space that I merged with this partition.
 
Sorry I have not made the situation clear. Hope this helps.  Thanks


#5 Al1000

Al1000

  • Global Moderator
  • 7,212 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Scotland
  • Local time:05:35 AM

Posted 15 May 2016 - 08:30 AM

The grub menu is: Ubuntu : SDA1 and SDB1

SDA1 boots into a windows repair screen : SDB1 boots into windows OS


Could you provide more details regarding what the Grub menu says?

Please also clarify what you mean here:
 

SSD & SATA both new drives


SATA is a means of connection; not a drive.

https://en.wikipedia.org/wiki/Serial_ATA

sdb1 boots windows fine in full rw mode although it knows that it does not start on the physical boundary because of the 500mb unallocated space that I merged with this partition.


What makes you think this has anything to do with the partition not starting on the physical sector boundary? This is a notorious issue with partitions that were created using Windows XP, but despite the error message they usually work ok.

Edited by Al1000, 15 May 2016 - 08:33 AM.


#6 lacey16

lacey16
  • Topic Starter

  • Members
  • 62 posts
  • OFFLINE
  •  
  • Local time:04:35 AM

Posted 15 May 2016 - 12:16 PM

Hi BC

 

Ok  sata and ssd are simply my way of identifying  which drive is which. Ubuntu always on ssd drive windows always on the toshiba (sata) HDD

 

Unallocated space as part of a single partition is ok.  unallocated space as a partition in front of the windows OS and boot files is not, and was the reason that windows would only mount in ro.  It considered that partition to be "busy/hibernated" because of the partitioned unallocated space.

 

After I merged the two partitions there was only unallocated space and not a partition in front of windows so it booted up fine in rw mode.  So Ubuntu and Windows both boot up fine, no problem.

 

The grub menu shows     Ubuntu : sda1 : sdb1      (sda1 boots into a windows repair screen which would indicate that the Ubuntu grub files still tries to boot it)

 

The problem is grub looking for bootup files on sda1. They are not there ie    Windows shows - Files Missing     win/sys/32/winload-exe so grub creates another screen showing Skip or Manual. To continue to boot I have to click on S for skip.

 

I was trying to find a way if possible to stop grub looking for these files and bringing up this screen. If not I can live with it.  

I was pretty sure that the unallocated space was in front of the Windows os on sdb1 and this was confirmed by:

Partition 1 does not start on physical sector boundary. but as you said it does not cause a problem now that it has been merged onto the same partition as windows.

Before deleting the "unallocated space" partition and merging the space into the windows partition the grub menu showed

Ubuntu : sda1 : sdb2   I could boot into windows on both sda1 and sdb2 but only in ro mode.  

 

Now I would like it to show Ubuntu and  sdb1 as it should do.

Thanks for your help.  I understand how confusing it must be.  If I can offer any more information please let me know.

If you could tell me how to attach a photo to this post I could send before merging and after merging screen shots that would make it much simpler to understand



#7 Al1000

Al1000

  • Global Moderator
  • 7,212 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Scotland
  • Local time:05:35 AM

Posted 15 May 2016 - 01:40 PM

Unallocated space as part of a single partition is ok. unallocated space as a partition in front of the windows OS and boot files is not, and was the reason that windows would only mount in ro.


An area on a SSD or HDD (or any storage media for that matter) can be unallocated space, or it can be part of a partition. Once you have allocated space to a partition, the space is no longer unallocated (because you have allocated it to a partition).
 

I was pretty sure that the unallocated space was in front of the Windows os on sdb1 and this was confirmed by:

Partition 1 does not start on physical sector boundary.


The partition not starting on physical sector boundary has nothing to do with the unallocated space. Partitions are supposed to start on sectors that are divisible by 64. You will find that you can divide the numbers listed under "Start" for all the partitions on /dev/sda in your output of fdisk -l by 64, but note that /dev/sdb1 starts at sector 63 (it should be 64). This is why you are getting the message "Partition 1 does not start on physical sector boundary."

If you haven't done so already, try updating grub by running the following command, just in case that fixes the problem (whatever it is):
sudo update-grub
If not, here's Nick's excellent tutorial on how to post a screenshot (you can skip the bit about installing shutter if you can already take screen shots)

http://www.bleepingcomputer.com/forums/t/558714/how-to-post-a-screen-shot-linux-style/

Edited by Al1000, 15 May 2016 - 01:53 PM.


#8 cat1092

cat1092

    Bleeping Cat


  • BC Advisor
  • 6,988 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:North Carolina, USA
  • Local time:12:35 AM

Posted 17 May 2016 - 05:09 AM

 

 

Spent a long time researching to resolve this. First Windows is definitely not in hibernation:  Secure Boot, Fast Boot hibernation have all been disabled in the bios and on windows OS and its booting in legacy mode.

 

Are you saying that Windows is running in Legacy Mode? If so, the Ubuntu install is also, the BIOS can't be set to run one OS one way & the other in full UEFI. 

 

Legacy Mode is also not recommended for SSD's (no AHCI), it's basically an easy way to install older OS's on newer computers, such as those that has no native AHCI support like XP/2000 (& maybe Vista). Though drivers for components may still be a huge issue to overcome. 

 

 

 

Partition 1 does not start on physical sector boundary.

 

You can correct this simply with any partition tool that features alignment of partitions, a bootable version is best, like a downloadable ISO, or some has an option to create a bootable CD or ISO image for USB stick. I use & recommend Mini Tool Partition Wizard for this, they have a bootable CD. Just make sure to select the right bit version (I presume to be 64 bit) for your computer. One thing to keep in mind, when aligning partitions, always start from the left side & after successful alignment of one, be sure to check the rest, all of the Windows ones on the SSD. Because unaligned partitions accelerates wear on the SSD by each write action taking place twice rather than once, thus loss of performance also. Linux partitions cannot be aligned with this tool, yet typically does a good job of it's own of this. 

 

https://www.partitionwizard.com/partition-wizard-bootable-cd.html

 

With Linux, you can verify alignment with GParted, right click onto the Linux partition & select Properties. You'll see a First Sector value, using an online calculator, divide by 2048, the outcome has to be a whole number, not any with a decimal. If this shows, retry it, I've made mistakes in entry & after doing it again it came out to be a whole number. You can also check your Windows partitions like this, am sure the first is off, should begin at 2048, with any modern OS. Even Advanced Format Drives requires this for best performance, and I even used to align my XP drives on IDE years ago for better performance by avoiding two writes to the drive. 

 

For example, my Swap partition at the end of my HDD (both /home & Swap are on HDD, root is on SSD) has a First Sector of 1945071616, divided by 2048 = 949742. It can be any number, as long as there's no decimal. 

 

OlQtwI3.png

 

It's as simple as that. :)

 

Cat


Performing full disc images weekly and keeping important data off of the 'C' drive as generated can be the best defence against Malware/Ransomware attacks, as well as a wide range of other issues. 


#9 lacey16

lacey16
  • Topic Starter

  • Members
  • 62 posts
  • OFFLINE
  •  
  • Local time:04:35 AM

Posted 17 May 2016 - 05:04 PM

Hi Thanks for everything.   I have uploaded pictures of the bios to tinypic.  Uploaded ok clicked on the 2nd box and it copied to the the 4th box direct links for layouts.  Dont know if this is correct. Hope you receive them ok.  Forgot to put tags on them.

 

This was the position before merging the 500mb with the windows os

 

Fstab -l sk /dev/sda: 120.0 GB, 120034123776 bytes

255 heads, 63 sectors/track, 14593 cylinders, total 234441648 sectors

Units = sectors of 1 * 512 = 512 bytes

Sector size (logical/physical): 512 bytes / 512 bytes

I/O size (minimum/optimal): 512 bytes / 512 bytes

Disk identifier: 0x6a39b47c

 

Device Boot Start End Blocks Id System

/dev/sda1 * 2048 1026047 512000 7 HPFS/NTFS/exFAT

/dev/sda2 1026048 176807935 87890944 83 Linux

/dev/sda3 176809982 231495679 27342849 5 Extended

/dev/sda5 176809984 196339711 9764864 82 Linux swap / Solaris

/dev/sda6 196341760 231495679 17576960 83 Linux

 

Disk /dev/sdb: 500.1 GB, 500107862016 bytes

255 heads, 63 sectors/track, 60801 cylinders, total 976773168 sectors

Units = sectors of 1 * 512 = 512 bytes

Sector size (logical/physical): 512 bytes / 4096 bytes

I/O size (minimum/optimal): 4096 bytes / 4096 bytes

Disk identifier: 0x3767dd0a

 

Device Boot Start End Blocks Id System

/dev/sdb2 * 1026048 308226047 153600000 7 HPFS/NTFS/exFAT

 

fdisk -l /dev/sdb2 before merging

 

Disk /dev/sdb2: 157.3 GB, 157286400000 bytes

255 heads, 63 sectors/track, 19122 cylinders, total 307200000 sectors

Units = sectors of 1 * 512 = 512 bytes

Sector size (logical/physical): 512 bytes / 4096 bytes

I/O size (minimum/optimal): 4096 bytes / 4096 bytes

Disk identifier: 0x73736572

 

This doesn't look like a partition table

Probably you selected the wrong device.

 

Device Boot Start End Blocks Id System

/dev/sdb2p1 1920221984 3736432267 908105142 72 Unknown

/dev/sdb2p2 ? 1936028192 3889681299 976826554 6c Unknown

/dev/sdb2p3 ? 0 0 0 0 Empty

/dev/sdb2p4 27722122 27722568 223+ 0 Empty

Partition 4 does not start on physical sector boundary.

 

 

Sorry very late now so must go.  I will try to get back tomorrow with more details.  Thanks again.

 

 



#10 Al1000

Al1000

  • Global Moderator
  • 7,212 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Scotland
  • Local time:05:35 AM

Posted 18 May 2016 - 04:51 AM

Uploaded ok clicked on the 2nd box and it copied to the the 4th box direct links for layouts. Dont know if this is correct. Hope you receive them ok.


You would need to post links to the images for us to be able to see them.

#11 NickAu

NickAu

    Bleepin' Fish Doctor


  • Moderator
  • 12,416 posts
  • ONLINE
  •  
  • Gender:Male
  • Location:127.0.0.1 Australia
  • Local time:02:35 PM

Posted 18 May 2016 - 05:00 AM

 

Partition 1 does not start on physical sector boundary

Did you align your partition?

 

Partition alignment - Wikipedia, the free encyclopedia

#12 lacey16

lacey16
  • Topic Starter

  • Members
  • 62 posts
  • OFFLINE
  •  
  • Local time:04:35 AM

Posted 18 May 2016 - 04:22 PM

sorry Nick  not yet.  Took a while for me to work out tinypic and with only 3mb BB a long time to upload.  Just taking one step at a time please look at the bios images thanks. Sorry for the trouble.

With reference to alignment and partitions, my knowledge stops at the old fat 16 & fat 32

 

 

http://i64.tinypic.com/16jpyde.jpg 1   I deleted the secure boot keys therefore option to install

 

http://i65.tinypic.com/dzuz6d.jpg 2    fast boot disabled. I did not disable CSM  but  image 5 shows in CSM mode

 

http://i63.tinypic.com/2natqgx.jpg 3 shows AHCI

 

http://i63.tinypic.com/nvs5z8.jpg 4 shows Asus EZ mode

 

http://i64.tinypic.com/34e95as.jpg 5 CSM enabled so thought this automatic legacy mode.  Boot device control is in UEFI and Legacy mode

 

http://i64.tinypic.com/315ltv7.jpg 6 Shows windows Uefi mode

 

http://i63.tinypic.com/107jqxx.jpg 7 Shows:   No Toshiba HDD ?   Still boots up ok

 

I saw another item but could not find it again to get screenshot.

 

FSO File path: System Reserved   Folders:   ext

FS1                                                   "             recycle bin

                                                        "              boot

                                                        "            new folder

​                                                        "            system volume info.

 

 

Before merging the 500mb space windows would only boot in ro>  After merging the 500mb space with the ntfs os it booted in rw and it changed from sdb2 to sdb1   This is the reason that I thought it was this tiny partition causing the problems.

 

 

 

Did this sudo update-grub. Result cannot open windows from ubuntu. Click on disk icon in launcher wont open, also a second S and M Options page now opens prior to booting into Ubuntu

Grub menu

Ubuntu

advances options for ubuntu

mem test

memtest

sda1 windows 10 bootloader

sdb1 windows 10 bootloader

 

Click Ubuntu and screen appears: S to skip and M to repair An error occurred when mounting /mnt/105EDF9E5EDFB44

Click S another screen appears   : S to skip and M to repair; The disk drive for /media/system_reserved is not ready yet or not present

Click S goes into Ubuntu with no further problems  Click sda1 windows recover screen quoting the boot files win/sys/32 winload-exe 

Have to reboot. After reboot click sdb1 opens windows

 

 

Did you align your partition?

 

 

Going to look at alignment now. Study your link (thanks) but would it be possible to do it in windows using aomei partitioner.  Im a little bit familiar with this and find it easy to use.

 

Many thanks everyone.


Edited by lacey16, 18 May 2016 - 04:28 PM.


#13 NickAu

NickAu

    Bleepin' Fish Doctor


  • Moderator
  • 12,416 posts
  • ONLINE
  •  
  • Gender:Male
  • Location:127.0.0.1 Australia
  • Local time:02:35 PM

Posted 18 May 2016 - 05:11 PM

Wow this is getting complicated.

 

I deleted the secure boot keys therefore option to install

Why?

 

 

Going to look at alignment now.

Its too late once the OS is installed.

 

Installing Linux next to Windows 10 is easy, There is no need for all this messing around,

First you install Windows if its not already installed and update it.

Next

 

You boot your PC from a live Linux USB or CD/DVD and you boot it in secure boot mode, NO deleting of anything no turning secure boot OFF. Then you install it alongside Windows 10, When done all you do is change the boot order in EFI boot manager with a simple terminal command And you are done.

 

 

Follow this tutorial

http://www.everydaylinuxuser.com/2015/11/how-to-install-ubuntu-linux-alongside.html



#14 lacey16

lacey16
  • Topic Starter

  • Members
  • 62 posts
  • OFFLINE
  •  
  • Local time:04:35 AM

Posted 18 May 2016 - 05:49 PM

Secure boot keys deleted.  Because everything I read on the Linux forums repeatedly advised. Disable secure boot : disable fast boot in bios  then disable them all in the windows OS  it only takes one click to reinstate the secure boot keys.

 

Even on this forum I have been asked/advised to ensure that Secure boot, fast boot, hibernation etc were disabled.Ubuntu alignment fine.

 

 First sector on sdb1 is 63   none of the sectors divide by 2048 without producing a decimal.

Its too late once the OS is installed.

 

Sorry I dont understand why you thought the both OS had not been already installed.  Does that mean that the partitions cannot be aligned.  Only the toshiba HDD with windows is affected.

Also I was installing windows 10 after Ubuntu was already installed so could not install Ubuntu alongside windows.

 

It was only a very minor problem.  Everything was fine except after clicking Ubuntu on the grub menu I had to click S to skip the repair option screen.  After doing this it booted straight into Ubuntu. Clicking sdb1 booted straight into windows. It was mounted in rw mode and I could access it from the disk icon on the launcher in Ubuntu.  I thought there may be a simple solution/code to fix grub to prevent the Skip and Manual option screen from appearing.

 

As I said at the beginning of my post if there is not a solution, no problem, I can live with it.

 

Thanks for your help.



#15 NickAu

NickAu

    Bleepin' Fish Doctor


  • Moderator
  • 12,416 posts
  • ONLINE
  •  
  • Gender:Male
  • Location:127.0.0.1 Australia
  • Local time:02:35 PM

Posted 18 May 2016 - 07:12 PM

 

Secure boot keys deleted.  Because everything I read on the Linux forums repeatedly advised. Disable secure boot : disable fast boot in bios  then disable them all in the windows OS  it only takes one click to reinstate the secure boot keys.

That is no longer the case, You just install along side.






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users