LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Laptop and Netbook
User Name
Password
Linux - Laptop and Netbook Having a problem installing or configuring Linux on your laptop? Need help running Linux on your netbook? This forum is for you. This forum is for any topics relating to Linux and either traditional laptops or netbooks (such as the Asus EEE PC, Everex CloudBook or MSI Wind).

Notices


Reply
  Search this Thread
Old 02-25-2011, 03:00 AM   #1
__spc__
Member
 
Registered: Feb 2006
Location: Bridgend, Wales
Distribution: Kubuntu 10.04.25 (Feb 2011)
Posts: 172

Rep: Reputation: 30
Problem with GRUB/WIn7/SRS4 Recovery partition Samsung N110 netbook


I have a Samsung N110 which came with Windows 7 Starter and which I upgraded to Windows 7 Home Premium using the 'anytime upgrade' path. On first switching the netbook on, I partitioned the HDD as 40 GB C: 'Windows' and 200 GB D: 'Data'. There is also a Samsung Recovery Solution 4 (SRS4) hidden partition of ~10 GB ('RECOVERY') and a further 104 MB hidden partition. (This allows you to 'hit' F4 at boot and go straight into the Windows Recovery process and restore a backup image of a functioning system.)

I recently installed Kubuntu 10.04.25 LTS. The installation process shrunk my D: drive (the fourth/last primary partition) by 20 GB and turned it into an extended partition, creating two new partitions - 'Linux' and 'swap'. The partitioner element of the install process gave me three options as part of doing this - manually create partitions, format the entire drive and create partitions, or create partitions automatically alongside existing O/S (which I selected).

The install proceeded flawlessly, Kubuntu is awesome, and the GRUB boot-loader gave the following boot options:
- Linux
- Linux (Recovery)
- Memtest
- Memtest (I forget the version)
- Windows Vista boot-loader on /dev/sda1
- Windows 7 boot-loader on /dev/sda3

I could boot perfectly into Linux and Windows 7 with ease, and did so many times.

Now, the PROBLEM! I was interested by the Windows Vista option at boot, so I selected it - this then ran the SRS4 recovery program, which I exited properly and had the machine restart. So, fine, happy with all that (as this is the same as pressing F4 at boot - which also worked).

HOWEVER, on restart, the netbook would enter an infinite loop of
- Power on, then
- Splash screen (showing F2 for BIOS, F4 for recovery), then
- BIOS password entry, then
- Blank screen and reboot.

F2 allows me into the BIOS, but F4 does nothing.

So somehow, running the SRS4 from the GRUB boot-loader and then exiting, managed to mess up GRUB...?

I then spent hours (!) trying to recover my system using the USB stick 'live CD' I used for the installation. I could run the 'live' system, then mount all my partitions on the netbook, but I just could not get GRUB to return to its original state again. I'm not saying GRUB wouldn't do it, my grasp of GRUB is just not sufficient to make it do it...

Ultimately, I ended up reinstalling Kubuntu so I could get GRUB to function properly. Now this time, I could not use the 'install alongside other O/S' option or else the installer would ignore the existing Linux partitions and create more, further shrinking my D: drive! So, I used the manually mount partitions option.

I now have GRUB working fine, but it refuses to see the Windows 7 partition and I only have the Vista boot-loader option. (Which selecting then kills my system again!)

From within my working Kubuntu, here are some outputs:

'fdisk -l'

*****
Disk /dev/sda: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x0e2792a7

Device Boot Start End Blocks Id System
/dev/sda1 * 1 1403 11268573+ 27 Unknown
/dev/sda2 1404 1416 104422+ 7 HPFS/NTFS
/dev/sda3 1417 6638 41945715 7 HPFS/NTFS
/dev/sda4 6639 30402 190878634+ f W95 Ext'd (LBA)
/dev/sda5 6639 27978 171408382+ 7 HPFS/NTFS
/dev/sda6 27978 30295 18611200 83 Linux
/dev/sda7 30295 30402 857088 82 Linux swap / Solaris
*****

/dev/sda1 is the RECOVERY partition
/dev/sda3 is the C: WIn7 partition
/dev/sda4 is the extended partitoin, on which sit
/dev/sda5 D: Data
/dev/sda6 Linux
/dev/sda7 swap

So, please, if anyone can help me get access back to Windows 7 and my dual boot arrangement that would be fantastic. Also, if someone could give me a hint as to why this all happened in the first place, that would be great, too!

(I have cross-posted this also in Sammy Netbook Forums...)

Thanks in advance for ANY help with this - I spent 7hrs of unsuccessful self-help yesterday!
 
Old 02-25-2011, 07:41 AM   #2
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,103

Rep: Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117
Generally the recovery systems I've used try to set the machine back to the way it was - partition-wise.
Hard to know in your case as you've subsequently re-run the kubuntu install. What does the /boot/grub/grub.cfg look like (post it here).
 
Old 02-25-2011, 08:05 AM   #3
__spc__
Member
 
Registered: Feb 2006
Location: Bridgend, Wales
Distribution: Kubuntu 10.04.25 (Feb 2011)
Posts: 172

Original Poster
Rep: Reputation: 30
Hi,

Thanks for the quick reply.

My cfg file is below.

I'm guessing there's something about "set root='(hd0,1)'", where this should be something like set root='(hd0,3)'?? The '*' has me a little confused in the fdisk output...


#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by /usr/sbin/grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s $prefix/grubenv ]; then
load_env
fi
set default="0"
if [ ${prev_saved_entry} ]; then
set saved_entry=${prev_saved_entry}
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi

function savedefault {
if [ -z ${boot_once} ]; then
saved_entry=${chosen}
save_env saved_entry
fi
}

function recordfail {
set recordfail=1
if [ -n ${have_grubenv} ]; then if [ -z ${boot_once} ]; then save_env recordfail; fi; fi
}
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set f95a2e38-855d-4efc-a025-ab5d9dfb0b60
if loadfont /usr/share/grub/unicode.pf2 ; then
set gfxmode=640x480
insmod gfxterm
insmod vbe
if terminal_output gfxterm ; then true ; else
# For backward compatibility with versions of terminal.mod that don't
# understand terminal_output
terminal gfxterm
fi
fi
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set f95a2e38-855d-4efc-a025-ab5d9dfb0b60
set locale_dir=($root)/boot/grub/locale
set lang=en
insmod gettext
if [ ${recordfail} = 1 ]; then
set timeout=-1
else
set timeout=10
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
set menu_color_normal=white/black
set menu_color_highlight=black/light-gray
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
menuentry 'Ubuntu, with Linux 2.6.32-28-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set f95a2e38-855d-4efc-a025-ab5d9dfb0b60
linux /boot/vmlinuz-2.6.32-28-generic root=UUID=f95a2e38-855d-4efc-a025-ab5d9dfb0b60 ro splash quiet splash
initrd /boot/initrd.img-2.6.32-28-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-28-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set f95a2e38-855d-4efc-a025-ab5d9dfb0b60
echo 'Loading Linux 2.6.32-28-generic ...'
linux /boot/vmlinuz-2.6.32-28-generic root=UUID=f95a2e38-855d-4efc-a025-ab5d9dfb0b60 ro single splash
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-28-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set f95a2e38-855d-4efc-a025-ab5d9dfb0b60
linux16 /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set f95a2e38-855d-4efc-a025-ab5d9dfb0b60
linux16 /boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Windows Vista (loader) (on /dev/sda1)" {
insmod ntfs
set root='(hd0,1)'
search --no-floppy --fs-uuid --set 26de284dde281797
chainloader +1
}
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/40_custom ###
# 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.
### END /etc/grub.d/40_custom ###
 
Old 02-25-2011, 08:41 AM   #4
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,103

Rep: Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117
The asterisk in the fdisk listing is just an indicator for the boot flag - not used by grub: don't worry about it.

From a terminal, run "sudo update-grub", and see if the grub.cfg changes. Else you may need to set up a custom entry.
 
Old 02-25-2011, 08:54 AM   #5
__spc__
Member
 
Registered: Feb 2006
Location: Bridgend, Wales
Distribution: Kubuntu 10.04.25 (Feb 2011)
Posts: 172

Original Poster
Rep: Reputation: 30
'sudo update-grub' no change - still only sees the /dev/sda1

I'm firstly puzzled how running the 'O/S' on /dev/sda1 resulted in the mbr (?) changing to create all this aggravation in the first place

Secondly, I'm puzzled why NOW the Kubuntu installation process does not see the O/S on /dev/sda3. (It did on the very first install..)
 
Old 02-25-2011, 11:07 AM   #6
EDDY1
LQ Addict
 
Registered: Mar 2010
Location: Oakland,Ca
Distribution: wins7, Debian wheezy
Posts: 6,841

Rep: Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649
Before you update-grub, open disk manager and mount sda2

"os-prober"
then
"update-grub"

use "su" or "sudo" depending on your setup.
 
Old 02-25-2011, 11:07 AM   #7
EDDY1
LQ Addict
 
Registered: Mar 2010
Location: Oakland,Ca
Distribution: wins7, Debian wheezy
Posts: 6,841

Rep: Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649
Before you update-grub, open disk manager and mount sda2

"os-prober"
then
"update-grub"

use "su" or "sudo" depending on your setup.
 
Old 02-25-2011, 11:25 AM   #8
__spc__
Member
 
Registered: Feb 2006
Location: Bridgend, Wales
Distribution: Kubuntu 10.04.25 (Feb 2011)
Posts: 172

Original Poster
Rep: Reputation: 30
Disk Manager..?

I can mount with sudo mount -t ntfs /dev/sda2 /mnt/temp

Something like that? Will it matter where I mount it for now?

Thanks for your attention on this!

---------- Post added 25-02-11 at 05:26 PM ----------

Disk Manager..?

I can mount with sudo mount -t ntfs /dev/sda2 /mnt/temp

Something like that? Will it matter where I mount it for now?

Thanks for your attention on this!
 
Old 02-25-2011, 11:49 AM   #9
EDDY1
LQ Addict
 
Registered: Mar 2010
Location: Oakland,Ca
Distribution: wins7, Debian wheezy
Posts: 6,841

Rep: Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649
It doesn't matter How you do it. I just offer the easiest way to mount.
On some of my installations os wasn't detected until I mount and run commands.
 
Old 02-25-2011, 12:14 PM   #10
__spc__
Member
 
Registered: Feb 2006
Location: Bridgend, Wales
Distribution: Kubuntu 10.04.25 (Feb 2011)
Posts: 172

Original Poster
Rep: Reputation: 30
OK, I'm just new to Ubunutu (I did use Slackware many years ago).

/dev/sda2 fails to mount...

$ sudo mount -t ntfs /dev/sda2 /mnt/tmp
Unexpected clusters per mft record (-1).
Failed to mount 'dev/sda2': Invalid argument
The device '/dev/sda2' doesn't seem to have a valid NTFS.
Maybe the wrong device is used? Or the whole disk instead of a partition (e.g. /dev/sda, not /dev/sda1)? Or the other way around?
$

HPFS fails too.

Any ideas?
 
Old 02-25-2011, 01:13 PM   #11
EDDY1
LQ Addict
 
Registered: Mar 2010
Location: Oakland,Ca
Distribution: wins7, Debian wheezy
Posts: 6,841

Rep: Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649
Use the disk manager and mount them as there's no command it only asks for password.
Or you can open Computer and just click on each disk to mount them. They'll appear on desktop when they're mounted.
 
Old 02-25-2011, 01:33 PM   #12
__spc__
Member
 
Registered: Feb 2006
Location: Bridgend, Wales
Distribution: Kubuntu 10.04.25 (Feb 2011)
Posts: 172

Original Poster
Rep: Reputation: 30
I don't know what you mean by 'disk manager' (in the context of Kubuntu). Which application should I be running.

Windows C:, Data D: and the RECOVERY partitions are all set to mount in the root directory (as per the Kubuntu installation program - it asked for mount points during install. I did not set the 'mystery' partition /dev/sda2 to mount.

In fact, I cannot see /dev/sda2 anywhere using any application.

I'm sorry for being dim here - very dim. I'm perfectly savvy with Windows and Slackware, and with this my first foray into netbook/linux and Ubuntu, I've never come across this problem before.
 
Old 02-25-2011, 04:06 PM   #13
EDDY1
LQ Addict
 
Registered: Mar 2010
Location: Oakland,Ca
Distribution: wins7, Debian wheezy
Posts: 6,841

Rep: Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649Reputation: 649
The disk manager on my ubuntu installation is under
Sorry it's called Didk Utility in Ubuntu.
System>>Administration>>Disk Utility.
 
Old 02-25-2011, 11:40 PM   #14
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,103

Rep: Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117Reputation: 4117
update-grub runs os-prober - no need (or benefit) from running it separately. The fact that it doesn't find the the sda2 system is a worry - as is the messages in post #10. Try "sudo parted -l /dev/sda" - it tries to determine the f/s rather than just listing the partition table.

Last edited by syg00; 02-25-2011 at 11:41 PM. Reason: added sudo
 
1 members found this post helpful.
Old 02-26-2011, 03:59 AM   #15
__spc__
Member
 
Registered: Feb 2006
Location: Bridgend, Wales
Distribution: Kubuntu 10.04.25 (Feb 2011)
Posts: 172

Original Poster
Rep: Reputation: 30
SOLVED:

Thanks for all your input - here's how I fixed this problem.

1. Indications were that /dev/sda2 was corrupt
2. I used my Win7 recovery disk (my own, created from my system, not a downloaded one) to repair the system (and at least get Win7 working again). Win7 was detected, but the first repair failed and left things unchanged. A second attempt, using the DOS/CMD.EXE console faield as 'bootrec /fixmbr' worked, but 'bootrec /fixboot' returned a corruption error. A 3rd attempt, again using the 'auto' repair route worked and got me Win7 back.
3. Back in Windows 7, I saw that the troublesome 104MB (/dev/sda2) partition was now mountes as RAW at E:. I then removed its disk label to hide it from Windows using one of the All Programs > Administration, tools (I forget the name). I then rebooted, using the Kubuntu Live USB.
4. I reinstalled Grub2 from the Kubuntu Live/Installation USB as per:http://ubuntuguide.net/how-to-restor...ws-xpvistawin7, specifically, from an xterm:

sudo -i
mount /dev/sda6 /mnt (my Linux partition, which has on it the /boot location)
mount --bind /proc /mnt/proc
mount --bind /dev /mnt/dev
mount --bind /sys /mnt/sys
chroot /mnt update-grub (I saw that this found Win7 on /dev/sda1 and NOT Vista boot-loader)
grub-install --root-directory=/mnt/ /dev/sda
exit (I forgot to unmount the 3 mounts above)

Rebooted and voila, a GRUB menu, with Linux, Memtest and Windows 7 available.

Actually, it's better than 'back to normal' as the original Kubuntu installation recognised the Samsung Recovery Solution 4 RECOVERY partition as an operating system and presented that in the GRUB2 boot menu. So, all solved... apart from why selecting the Windows Vista boot-loader option killed the system! (Now, that option doesn't exist.)
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Samsung N145 netbook with Fedora14 scrolling problem rkski Linux - Laptop and Netbook 7 10-09-2011 12:52 AM
Distro options for my Samsung N110 charlZA Linux - Laptop and Netbook 5 05-03-2010 12:15 AM
Grub 1.5 Error 22 - Partition Deleted on Netbook. lszanto Linux - General 1 04-30-2010 02:44 AM
GRUB boots XP RECOVERY partition instead of XP. Miah Linux - Newbie 3 06-06-2006 11:00 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Laptop and Netbook

All times are GMT -5. The time now is 08:59 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration