unknown error, grub rescue

Asked by paul parker on 2010-04-17

Hi everyone

I'm not a computer expert so please be kind and rescue me. I installed ubuntu 9.10 last night but when I turned on my laptop today this message came up " unknown error - grub rescue " and I'm completely lost, so please let me know how to resolve the problem (step by step in a plain language please) and run the computer.

best
paul 20

Question information

Language:
English Edit question
Status:
Answered
For:
Ubuntu grub Edit question
Assignee:
No assignee Edit question
Last query:
2010-04-19
Last reply:
2010-04-21
subliminalfix (subliminalfix) said : #1

not for nothing why not just try and re-install?

can you put the disk in and select ck 4 defect? may have copied badly...

if the grub or loader wont work i dont know if theres much else you can do.

sorry hope that helps

p.s. not "a computer expert "either

Tom (tom6) said : #2

Hi :)

When you make a Cd or dvd the first thing you should do is to do an md5sum check. I usually forget these too so my first check of the Cd is to try booting up from the Cd "without making changes to this machine"
https://help.ubuntu.com/community/LiveCD

That should get you to a working desktop that you can then use to check the md5sum from, it should also pick-up you internet connection so hopefully firefox will get you into here safely
https://help.ubuntu.com/community/HowToMD5SUM#Check%20the%20CD

I usually avoid the "Check disk for defects" because it takes so long but i guess it should be done after the other 2 checks or sometime when you can leave the machine to get on with it for a few hours.

Really for this problem i would start up the LiveCd sesion and then try to reinstall grub as described in this guide
https://help.ubuntu.com/community/WindowsDualBoot#1.%20Recovering%20GRUB%20after%20reinstalling%20Windows
Note that with 9.10 you can use grub or grub2. I would try either one and if it didnt work then try the other.

Please let us know the cpu speed, ram size and amount of hard-drive space given to Ubuntu but if you are unsure then just let us know if any are easy to remember or work out. Also i guess that booting into Windows is still fine?

Please let us know how this goes!
Good luck and regards from
Tom :)

paul parker (paul4park) said : #3

Hi Tom

very many thanks for your mail and I would like to tell you exactly where I'm and hope to be helped by you and friends.

laptop description:

dell vostro
core 2 duo 1.6ghz
ram 2X512- 667mhz ddr2 sdram
hard 80gb ata 5400 rpm-  50gb of which given to Windows XP prof. /12gb to ubuntu and rest is a little data such as photos and paper works.

I already had windows and was interested in ubuntu so installed it BUT the next day when I turned the computer on this message poped on a black screen:

Grub loading
error: no such partition
grub rescue>

I panicked as I'm not a computer expert and started to search for a solution on ubuntu forum. I red some advise saying that reinstalling ubuntu from a CD will resolve the problem so I did reinstall the program as instructed and used the windows to back up my data before any disaster. then I wanted to check C drive (50 GB primary/ Windows) and P drive (partitioned in C Drive,12GB logical/ ubuntu) but P Drive had disappeared and was not on "My Computer" list.

I then restart the computer to choose ubuntu But this time the following message poped up:

unknown error
grub rescue>

I went back to forum but couldn't understand a single word of technical language also found the same recommendation (above) to solve the matter which already proved to be unhelpful.

So now I'm stuck and would be extremely grateful if you could help me by answering the following questions:

1- is there any command to type in order to solve the matter and start running the computer? if so what is it and how it should be done.

2- if I reinstall the ubuntu again and started running the Windows, can I just delete the Ubuntu partition from main drive and extend the C Drive only for windows as it originally was before? How?

3- Can I restore the computer to a previous date (4 days ago) and solve the matter? if yes HOW?

4- Finally How could I possibly get in touch with OFFICIAL UBUNTU GUYS to get some help, if none of the above worked?

Kindest regards
paul

--- On Sun, 18/4/10, Tom <email address hidden> wrote:

From: Tom <email address hidden>
Subject: Re: [Question #107704]: unknown error, grub rescue
To: <email address hidden>
Date: Sunday, 18 April, 2010, 22:14

Your question #107704 on Ubuntu changed:
https://answers.launchpad.net/ubuntu/+question/107704

Tom proposed the following answer:
Hi :)

When you make a Cd or dvd the first thing you should do is to do an md5sum check. I usually forget these too so my first check of the Cd is to try booting up from the Cd "without making changes to this machine"
https://help.ubuntu.com/community/LiveCD

That should get you to a working desktop that you can then use to check the md5sum from, it should also pick-up you internet connection so hopefully firefox will get you into here safely
https://help.ubuntu.com/community/HowToMD5SUM#Check%20the%20CD

I usually avoid the "Check disk for defects" because it takes so long
but i guess it should be done after the other 2 checks or sometime when
you can leave the machine to get on with it for a few hours.

Really for this problem i would start up the LiveCd sesion and then try to reinstall grub as described in this guide
https://help.ubuntu.com/community/WindowsDualBoot#1.%20Recovering%20GRUB%20after%20reinstalling%20Windows
Note that with 9.10 you can use grub or grub2. I would try either one and if it didnt work then try the other.

Please let us know the cpu speed, ram size and amount of hard-drive
space given to Ubuntu but if you are unsure then just let us know if any
are easy to remember or work out. Also i guess that booting into Windows
is still fine?

Please let us know how this goes!
Good luck and regards from
Tom :)

--
If this answers your question, please go to the following page to let us
know that it is solved:
https://answers.launchpad.net/ubuntu/+question/107704/+confirm?answer_id=1

If you still need help, you can reply to this email or go to the
following page to enter your feedback:
https://answers.launchpad.net/ubuntu/+question/107704

You received this question notification because you are a direct
subscriber of the question.

subliminalfix (subliminalfix) said : #4

 3.if you can run windows you can go to your last restore point which may overide the system . im unsure because of the partition at the time it may not format properly or even cause you more problems

for further support there is also an irc channel for chatting

dont give up you were ment to learn something !!!
4.
http://www.ubuntu.com/support/community/chatirc
http://www.ubuntu.com/support/services
http://www.ubuntu.com/support/communitysupport

Tom (tom6) said : #5

Hi :)

Thanks for the back-ground information there. To quickly answer your questions

1. Probably not a 1 single command but the situation can highly probably be resolved fairly easily. 1st thing is to find out if you can boot up from an Ubuntu Cd in your Cd/dvd-drive?
https://help.ubuntu.com/community/LiveCD

2. Don't reinstall Ubuntu until after we have seen the LiveCd working properly. It is just adding further confusions to an already confusing system. 1st thing is to stabilise the patient (by not installing things) and then diagnose to asses which treatment is likely to work best. We can do that most easily from a LiveCd session.

3. That will depend on what information we can get from the LiveCd session.

4. Linux is not made by a company for the primary purpose of making profits for their shareholders. Our aim is to get the system working unlike corporate technical help which would try to blame for bad usage (even though you haven't done anything badly wrong) and then get you to buy new equipment or software.

I am still curious to know whether you can still boot into Windows? or has this become impossible too at the moment?

Also please put the Ubuntu Cd in the cd/dvd-drive and try switching on the machine. Does it boot up to a menu with the top option being "Try Ubuntu without changes to this machine"? Selecting that option should get you to a working desktop. Firefox should work for surfing the internet into this thread in Launchpad. If it doesn't boot up to that menu when the Ubuntu Cd is in the cd/dvd-drive then please let us know as we can guide you through to that if needed.

Good luck and regards from
Tom :)

Tom (tom6) said : #6

Hi again :

Please put the Ubuntu Cd in the Cd/dvd-drive and switch on the machine as described in this guide
https://help.ubuntu.com/community/LiveCD
to get to a working desktop.

Go up to the top taskbar and click on

Applications - Accessories - Terminal

to get to a command-line and in there copy&paste (with the mouse) or type in this command

sudo fdisk -l

where "-l" is a lower-case "-L". Then click on the Firefox icon beside the question mark on the top taskbar. That should help you navigate into this thread here
https://answers.launchpad.net/ubuntu/+source/grub/+question/107704
Please copy&paste into this thread the output that the "sudo fdisk -l" command gave you.

Telling us that you didn't follow the advice i gave you last time but did follow some other advice from somewhere else without even giving us a link to that advice is not particularly helpful. Getting annoyed that advice for a different situation didn't solve your current problem seems a bit strange.

During the troubleshooting process it is usually good to try a simple fix as a first response, as subliminalfix did. Occasionally the simple fix doesn't work and we have to look deeper at the current state of play before making our next move.

Since all this is clearly baffling at the moment i would really prefer to lead you gently through this 1 step at a time. The first step is simply to ensure that you can get to a LiveCd session. Hopefully that should be really really easy but there is a chance that we might have to lead you through that stage first. The LiveCd does not retain information if you save anything to it's desktop but it does give us access to the data stored on your hard-drive.
https://help.ubuntu.com/community/LiveCD

Please let us know how it goes!
Good luck and regards from
Tom :)

paul parker (paul4park) said : #7

hi tom

many thanks for your help and kindness, here is what you were looking for:ubuntu@ubuntu:~$ sudo fdisk -l

Disk /dev/sda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000080

   Device Boot Start End Blocks Id System
/dev/sda1 1 6 48163+ de Dell Utility
/dev/sda2 * 7 7830 62846280 7 HPFS/NTFS
/dev/sda3 7831 9568 13960485 f W95 Ext'd (LBA)
/dev/sda5 7831 9267 11542671 83 Linux
/dev/sda6 9268 9337 562243+ 82 Linux swap / Solaris
/dev/sda7 9338 9568 1855476 b W95 FAT32
ubuntu@ubuntu:~$

thanks again and looking forward to hear you asap.

best /paul

Tom (tom6) said : #8

Hi :)

Brilliant, thanks :)

From my spreadsheet calculations i see that sda7 is a tiny 1.9Gb Fat32 partition. Can you find that partition in the "Places" menu on the top taskbar? it's probably labelled as something really unhelpful like "1.81 GB Media"

If you can see any useful data in there please can you copy it to the Windows partition which is probably labelled something equally helpful like "63.8 GB Media"

The main linux partition is looking good and it's a relief to see the Windows Ntfs partition there. So we know it's still all there :) Now just to access it at boot-up! I will try to copy the first part of the guide in a way that makes sense to your particular set-up in a minute.

Good luck and regards from
Tom :)

Tom (tom6) said : #9

Hi again :)

This is the guide i shall try to work from
https://help.ubuntu.com/community/Grub2#Reinstalling%20from%20LiveCD

The first step is to "Copy Grub2 files from the LiveCd" & we are already at step 4. So, on a command-line try this

sudo mount /dev/sda5 /mnt

If it works there will be no fan-fare, no error messages. Nothing. It will just give you the next prompt. Now enter

sudo grub-install --root-directory=/mnt/ /dev/sda

Again we are hoping for no error messages. If it has been successful then now you can reboot, remove the Cd when prompted and it should boot into the installed Ubuntu. Now, to get Windows into the boot menu get to a command-line in the installed Ubuntu and try

sudo update-grub

This time it will ask for your normal user password, not your SuperUser or Root one. The LiveCd doesn't worry too much about passwords because the Cd is not writeable so the system can't be compromised (well, not easily). As you type the password you get no stars or anything but it does accept what you type in quietly. This is to prevent anyone from even finding out how long your password is by nefarious means.

Ok, so hopefully now you should be able to reboot into Windows?
Please let me know how this goes as we are not completely sure about Grub2 yet and might have to revert back to the original grub if this doesn't work.

Good luck and regards from
Tom :)

paul parker (paul4park) said : #10

hi tom

thanks for prompt reply.

apart from normal folders on top such as Documents, Music, videos and etc the only things in places are:
Computer
64GB file system
12GB file system
Media Direct

--- On Mon, 19/4/10, Tom <email address hidden> wrote:

From: Tom <email address hidden>
Subject: Re: [Question #107704]: unknown error, grub rescue
To: <email address hidden>
Date: Monday, 19 April, 2010, 19:03

Your question #107704 on grub in ubuntu changed:
https://answers.launchpad.net/ubuntu/+source/grub/+question/107704

Tom posted a new comment:
Hi :)

Brilliant, thanks :)

>From my spreadsheet calculations i see that sda7 is a tiny 1.9Gb Fat32
partition. Can you find that partition in the "Places" menu on the top
taskbar? it's probably labelled as something really unhelpful like "1.81
GB Media"

If you can see any useful data in there please can you copy it to the
Windows partition which is probably labelled something equally helpful
like "63.8 GB Media"

The main linux partition is looking good and it's a relief to see the
Windows Ntfs partition there. So we know it's still all there :) Now
just to access it at boot-up! I will try to copy the first part of the
guide in a way that makes sense to your particular set-up in a minute.

Good luck and regards from
Tom :)

--
You received this question notification because you are a direct
subscriber of the question.

paul parker (paul4park) said : #11

hi tom

I've checked that MEDIADIRECT's property and the size is 1.8Gb which I think is the one you are looking for. please let me know whether I should copy the whole file or internal files in to the 64GB file system? if so where and how?

I also typed the following command :sudo mount /dev/sda5 /mnt as instructed but the message was: command not found

regards paul

Tom (tom6) said : #12

Hji :)

Sorry i dropped out for a bit again there. Ahhh i think Media Direct might be the tiny 1.9Gb partition. Since it is named it might be best to leave it alone as it might be fulfilling some function but it sound unusual. When you click on it is there anything in there that you recognise?

If you are still in a LiveCd session please could you go up to the top taskbar and click on

System - Administration - Gparted

and see if sda7 has a little key symbol beside it? If not then right-click and choose "Mount" from near the bottom of that menu. Then look back in the "Places" menu to see if it has appeared now.

Good luck and regards from
Tom :)

paul parker (paul4park) said : #13

hi Tom
I'm there and it has the key symbol, could you tell me what are the rest, like: sda2 59.9GB or sda3 extended 13.31GB or sda and sda5 11GB as well as sda6 linux swap 550MB and Unlocated 1.23GB

Tom (tom6) said : #14

Hi :)

having a look at the drive is now a side-issue. The main thing is to race on with doing these commands from a LiveCd session

sudo mount /dev/sda5 /mnt

sudo grub-install --root-directory=/mnt/ /dev/sda

Then a reboot, hopefully into the Ubuntu that is installed already in order to run this command to get Windows into the "GRand Unified Boot-loader's" (=grub's) menu

sudo update-grub

This should (re)install grub2 into your linux partition sda5 and "fix" (as in horse racing not as in broken) the MBR (=Master Boot Record) of the physical hard-drive which linux calls sda

Please let me know how this goes!
Good luck and regards from
Tom :)

paul parker (paul4park) said : #15

Hi Tom

I've checked the content of Media Direct 1.8GB although it is Dell and windows component but it dosen't seem to be in windows partiotion (C: Drive) !! any idea why is it like that or do you think your first idea of copying it to windows 64GB was a correct way of putting things on the right path.

regards paul

paul parker (paul4park) said : #16

Hi Tom
I typed the following command "sudo grub-install --root-directory=/mnt/ /dev/sda" and this poped up

ubuntu@ubuntu:~$ sudo grub-install--root-directory=/mnt//dev/sda
usage: sudo [-n] -h | -K | -k | -L | -V | -v
usage: sudo -l[l] [-AnS] [-g groupname|#gid] [-U username] [-u username|#uid]
            [-g groupname|#gid] [command]
usage: sudo [-AbEHnPS] [-C fd] [-g groupname|#gid] [-p prompt] [-u
            username|#uid] [-g groupname|#gid] [VAR=value] [-i|-s] [<command>]
usage: sudo -e [-AnS] [-C fd] [-g groupname|#gid] [-p prompt] [-u
            username|#uid] file ...
ubuntu@ubuntu:~$

what shall I do now.
Tom, I know, I'm headache but I sincerely appreciate your help and hope to be able to do something in return.

regards

Tom (tom6) said : #17

Hi again :)

Ok, so to interpret what the partitions are

sda1 is a "recovery" or "rescue" partition placed there by the manufacturer for them to use if you have a technical support question for them. Generally it is a good idea to avoid touching these at all, especially if the machine is still under guarantee. Hopefully this is effectively "hidden" and shouldn't show up in the "Places" menu. Windows should be completely unaware of it too, it probably doesn't even show up in Windows partitioners.

sda2 is your Windows "C: 'drive'". They call partitions drives because they don't think their users are smart enough to cope with the idea of partitions. trying to reduce the confusion has the added benefit to them of making linux look too complicated and out-of-reach. The "Places" menu sees this as "59.9 GB Media". If you click into this & navigate through

"User&Documents" - Paul (perhaps, but depending on the user-name you have in Windows) - "Paul's Documents"

then you end up in your Windows "My Documents" folder. Again the name change is meant to simplify things. In a multi-user machine in Windows each user sees their own folders as being called "My ..." (somewhat childishly imo). However look at it from outside of Windows and you have extra complexity because "My Documents" is called something else. Again the complexity is introduced by MicroSquish but they easily make it look like linux is creating the problem. You can verify this from inside Windows by clicking on

"My Computer" - "C: 'drive'" - "Users & Documents" - .....

I would tend to use "Make link" from the right-click menu & then drag the link onto your installed Ubuntu's desktop or into your installed Ubuntu's "Documents" folder (look, no stamping feet). Then i would keep most of the data on Windows but access it from Ubuntu. Just avoid saving web-pages or anything with ridiculously long file-names because Windows can't handle long names

sda3 ahhh, this is where it really does get complicated. When MicroSquish were starting out they didn't want to use any existing formats so they created a new "partition table" type that could only have 4 partitions. Most versions of unix (or anything else at the time) functioned better with at least 3 partitions so MicroSquish was effectively blocking any chance of using a Windows machine for anything except Windows. Also Windows couldn't be installed on a hard-drive with any other partition table type (still true today i think). Windows can still only really cope with 1 partition. However, some very clever people developed a way of making 1 of those partitions act like a bucket that could then contain a LOT of partitions that were not quite like the proper partitions. These new partitions were called "Logical" partitions and the normal ones were named "Primary". The bucket partition was called an "Extended Partition" (i guess they were having a bad hair day when they named it). MicroSquish were kinda forced to adopt it but when they relented they claimed the glory for having developed it

Now, the numbers sda1 - sda4 are reserved for Primary Partitions (including the Extended Partition). So the 1st "Logical" partition created on a drive is called sda5.

sda5 is your main install of Ubuntu & is mounted as / when you boot into the installed Ubuntu. Linux uses / to mean roughly the same thing as Windows "C: 'drive'" means. It's the "root of the file-system". Folders such as your "Documents" folder are sub-sub-folders to some degree, such as

/home/paul/Documents

All you data & settings are stored in "/home/paul" if there is another user on your system they have their data & settings stored in "/home/sandra" (for example). Everything about the different users is kept distinctly separate but each may set certain folders to be accessible by certain other users or over a network.

sda6 this is the 2nd logical partition on the drive. Swap should be at least as large as Ram because when your machine hibernates or goes into sleep mode the contents of Ram are copied into swap. Ram cannot hold any data unless the machine is switched on. Since sleep or hibernate mode is meant to spring into instant action eactly as it was when it went into this sleep state the contents of ram need to be stored on a hard-drive. During normal operations Ram uses Swap to contain data that it knows is likely to be needed fairly soon, we call this "caching". The Cpu can work through data far faster then hard-drive read/writes can supply it so there are a series of areas (including Ram) where data gets queued up (cached) ready in advance of the cpus calling for more data. Windows calls it's swap space "virtual memory" and uses a file instead of using a separate partition. Just like every other Windows file it can get very fragmented very quickly so people who know about it stop it from being able to keep changing size and set it to some fixed size. Since their "pagefile.sys" is a system file it can't get defragmented by most Windows Defragmenters. When it can get defragmented, perhaps by the 1 month trial version of "Perfect Disk", then suddenly the system starts working nearly as fast as the day the machine came from the shop. Linux doesn't suffer from fragmentation because it writes files more intelligently rather than just cramming them into the smallest spaces at the beginning of the drive. "Total memory" = Ram + Swap but having swap too large can also cause problems. The ideal size is larger than ram but smaller than 3 x Ram. Usually about 1.5 x ram is about what people often settle for. I try to set-up machines to have just a tiny bit more than 2 x Ram because often people will upgrade the Ram to boost performance and usually they double whatever they have.

sda7 fat32 makes this something that Windows can use. Usually Windows doesn't like having extra partitions as it gets a bit confused and tries to avoid letting you access it too easily. Quite what this partition is for i have no idea which bothers me. Is it crucial or should it be deleted? Still ,it's only small and unlikely to affect linux whatever it is.

Sorry this has taken me ages to write!
Good luck and regards from
Tom :)

Tom (tom6) said : #18

Hi :)

That "Media Direct 1.8GB" sda7 is likely to be seen in Windows as your "D: 'drive'" or maybe E: or F:

Regards from
Tom :)

paul parker (paul4park) said : #19

Hi Tom

Thank you very much indeed for detailed explanation and I'd be grateful if you could tell me where am I with commands and what to do next.

warm regards
paul

paul parker (paul4park) said : #20

Hi Tom

Thank you very much indeed for detailed explanation and I'd be grateful if you could tell me where am I with commands and what to do next.

warm regards
paul

Tom (tom6) said : #21

Hi :)

You are not a pain. I got annoyed earlier but i can see that you have been working hard at understanding stuff which is all-new. It's not easy to do that so i appreciate the work you are putting into this.

Ignore all of that long post i just made. It's just background stuff and you don't really need to know it.

Note that on the command-line the keyboard paste doesn;t work. I don't know why CtrlV doesn't work but it seems to be the same in all distros, not just Ubuntu. Mouse paste is always great tho, from the right-click menu.

sudo mount /dev/sda5 /mnt

sudo grub-install --root-directory=/mnt/ /dev/sda

When you tried the 2nd command there were spaces missing
ubuntu@ubuntu:~$ sudo grub-install--root-directory=/mnt//dev/sda
see? Between "grub-install" and the next bit which is "--root-directory=/mnt/" and again with the bit after that "/dev/sda".

If you are still in the same LiveCd session then just press up arrow a couple of times to get the commands back so you can edit them. Otherwise i would copy&paste using the mouse. If you do have to type it all in then try pressing the tab key occasionally as you type. Linux command-line's have a slightly more intelligent version of the "predictive txtin" found in mobile phones.

Good luck this time!
Regards from
Tom :)

paul parker (paul4park) said : #22

Hi Tom

 to be honest with you finding people like you is almost impossible and I really feel that it is my duty now to do something in return just to express my appreciation for your kindness and I will.

I did copy the command and here is the popup.
ubuntu@ubuntu:~$ sudo grub-install --root-directory=/mnt/ /dev/sda
grub-probe: error: cannot find a device for /mnt//boot/grub.

No path or device is specified.
Try ``grub-probe --help'' for more information.
Auto-detection of a filesystem module failed.
Please specify the module with the option `--modules' explicitly.
ubuntu@ubuntu:~$

please let me know what to do next

best paul

Tom (tom6) said : #23

Hi :)

Ok, press up arrow twice so that it repeats the

sudo mount /dev/sda5 /mnt

and then up twice again to repeat the

sudo grub-install --root-directory=/mnt/ /dev/sda

Now you mention it i seem to remember it taking a couple of goes before it worked on my machine. Have you ever seen "Pay it Forwards"? The best way to re-pay is by helping someone else sometime. I got a lot of help from someone when i first started. I guess i still do get quite a lot of help from people. Usually people seem to have a couple areas they begin to know really well.

Good luck and regards from
Tom :)

paul parker (paul4park) said : #24

Hi tom

question: where are you? am i bothering you, I don't want to disturb you in case you want to sleep or take a rest. I can wait until you are free.

here is the popup after performing the command

ubuntu@ubuntu:~$ sudo mount/dev/sda5 mnt
sudo: mount/dev/sda5: command not found
ubuntu@ubuntu:~$ sudo mount/dev/sda5/mnt
sudo: mount/dev/sda5/mnt: command not found
ubuntu@ubuntu:~$

thanks/ paul

Tom (tom6) said : #25

Hi :)

I am in England so i am about to vanish suddenly. Pizza & wine are calling :) Again the problem is a missing space

sudo mount/dev/sda5 mnt

should be

sudo mount /dev/sda5 mnt

Regards from
Tom :)

Tom (tom6) said : #26

Hi again :)

I just noticed that my Ubuntu 10.04 is also on sda5 so i was able to copy & paste exactly the same commands straight onto my command-line so this might have sorted my grub2 problem too.

Fingers are crossed that this works for you because we are either very very close to having fixed this or else try another way another day.

Regards from
Tom :)

paul parker (paul4park) said : #27

shall I press the up arrow twice then push Ent and then press the up arrow again the Ent OR press the up arrow four times and then Ent? I'm confused.

regards/paul

Tom (tom6) said : #28

Hi again again :)

When you get advice in forums and want to check that the command looks about right, or when you forget exactly how to use a command you can always type a "-h" or a "--help" tag after the command to get a quick guide cheat-sheet on how to use the command. There are detailed "man" (=manual) pages too but i usually find the "-h" is a lot less trouble and gives just enough of a hint to know if it's something i can do or something i should leave. Try

sudo -h
mount -h
grub-install -h

and you should see some of the output that you got earlier when spaces were missing and the linux command-line got all confused.

Regards from
Tom :)

Tom (tom6) said : #29

Hi :)

Just press the up arrow until you see something close to

sudo mount /dev/sda5 mnt

and then use the left button to move the cursor so you can correct the tiny error
Regards from
Tom :)

Tom (tom6) said : #30

Hi ooops

It should be

sudo mount /dev/sda5 /mnt

without that / before the mnt it will get confused again, sorry
Regards from
Tom :)

paul parker (paul4park) said : #31

Hi again

Fantastic because I'm in London , England too so I would prefer to let you go now as you should be exhausted. I'll try it again, if not successful I'll get back to you tomorrow evening if you don't mind.

many, many thanks and have a good night

best regards
paul

Tom (tom6) said : #32

Hi :)

Yup, that's all good. See you tomorrow, perhaps.

Regards from
Tom :)

paul parker (paul4park) said : #33

Hi Tom

hope you are well, I did the last things you said but the problem is still there so I'm ready to listen to your advise.

regards/ paul

Tom (tom6) said : #34

Hi :)

Sorry i think i'll have to leave this until tomorrow. Just curious to know that you tried

sudo mount /dev/sda5 /mnt

sudo grub-install --root-directory=/mnt/ /dev/sda

Regards from
Tom :)

paul parker (paul4park) said : #35

Hi Tom

this is the message on terminal have a look and see if we should leave it until tomorrow, it's fine with me.

regards/paul

  -h, --help print this message and exit
  -v, --version print the version information and exit
  --modules=MODULES pre-load specified modules MODULES
  --root-directory=DIR install GRUB images under the directory DIR
                          instead of the root directory
  --grub-setup=FILE use FILE as grub-setup
  --grub-mkimage=FILE use FILE as grub-mkimage
  --grub-mkdevicemap=FILE use FILE as grub-mkdevicemap
  --grub-probe=FILE use FILE as grub-probe
  --no-floppy do not probe any floppy drive
  --recheck probe a device map even if it already exists
  --force install even if problems are detected
  --disk-module=MODULE disk module to use

INSTALL_DEVICE can be a GRUB device name or a system device filename.

grub-install copies GRUB images into the DIR/boot directory specified by
--root-directory, and uses grub-setup to install grub into the boot
sector.

Report bugs to <email address hidden>.
ubuntu@ubuntu:~$
ubuntu@ubuntu:~$

Tom (tom6) said : #36

Hi,

Yeh, you are getting the help-fie again si guess there's a space missing. Lets try to sort this tomorrow

Sorry chap
Good luck & regards from
Tom :}

paul parker (paul4park) said : #37

Hi Tom

 I have 2 news,

first, the machine is up and running, and I have no idea why or how but I think using the commands last night had some positive effects so I should thank you.

second is that when I turned the machine on (just minutes ago) a full page of choice containing number of linux, ubuntu, kubuntu and Microsoft XP poped up so I choose XP as main operating program to be able to have access to everything, the question is,

How could I possibly delete all those stuff and choices from C: drive and go back where I was (before installing ubuntu) and get rid of all partitions and all the rest until I can learn more and improve my knowledge about computer before starting to use ubuntu as main operating program.

hope to hear you soon

regards/ paul

Tom (tom6) said : #38

Hi :)

You have got through the hardest part about using an operating system & straight-away want to do the 2nd hardest thing?

The easiest thing for now is just to keep Ubuntu on the system but keep booting into Windows for almost everything. To set the default for booting into Windows rather than Ubuntu this guide should help
https://help.ubuntu.com/community/Grub2#Configuring%20GRUB%202

Basically count which number Windows is on the menu. Count from 0 at the top. Lets say that Windows was the 5 (so 6th on the list), just enter

sudo grub-set-default 5

Now when you reboot it should highlight Windows by default and automatically boot straight into Windows. You don't need to learn anything more about Ubuntu. Just click on

Applications - Office - Word Processor

or

Applications - Sound & Video - Movie Player

or better still just double click on any Windows file and see which program in Ubuntu opens it. I realise that it has been extremely tough trying to get the thing working but now that you have got past that stage you will find that Ubuntu is really quite easy to use.
Good luck and regards from
Tom :)

paul parker (paul4park) said : #39

Hi

very many thanks for your kindness and help. I wish you all the best and hope to get in touch for more help.

warmest regards
paul

Tom (tom6) said : #40

hi :)

Sorry about my last reply. This stupid grub2 didn't change my default in the way the guide suggested it would grrr.

To get back to only using Windows 'just'

1. boot into Windows

2. get to a command-line. Usually
"All Programs" - Accessories - "System Tools"
or somewhere. Look for an icon with a square made of MS DOS in colourful lettering. Usually its called "Cmdprmt" or something similar.

With Xp or later you might need to use their installer Cd or "Recovery Media" or whatever (they try to avoid letting people have copies of these & keep producing poor partial substitutes with different names to avoid legal actions) to install the functionality! In which case get to the "Control Panel" which it tries to hide from you. Add/remove programs. The 2nd tab lists extras you can install from the Cd. Assuming it decides that it's the Cd it was expecting and that you are allowed to use it. After installing you will probably need to reboot, update & reboot again at least 1 time.

3. On the command-line type
fixmbr

4. Reboot. This should get you straight into Windows assuming their ancient flaky boot-loader is not broken already.

5. If this works then reboot to an Ubuntu LiveCd (any release, or even a different distro) and get to GParted, in Ubuntu its
System - Administration - Partition Editor (or in 10.04 they call it Gparted again now)

6. Right-click on and "umount" or "Swap Off" sda6 & then sda5 unless they already don't have a key symbol beside them in which case the option wont be there in the right-click menu.

7. Right-click and delete sda6 first then sda5

8. Right-click on sda3 and see if you can resize it smaller. It might need to be unmounted but it might just refuse because of the unknown partition sda7 which we still don't really know what is in it or what it does.

9. Click on the "Apply" button

10. For any Windows except Vista you can now resize the Windows partition but i would be tempted to reboot into Windows to do it from "Management Services" as even Vista can cope better with that. Oddly when you tell some Vista's to increase partition size they create a new partition instead. All the other Windows are fine about resizing though.

11. From
"My Computer" - right-click on "C: 'drive'" - then 2nd tab i think
Defragment & "Scan drive"
Since the Windows partition/drive is now at it's most efficient it might be a good time to do a virus scan.

12. I would definitely consider optimising the swap file in Windows to try to stop slow-downs. Right-click on "My Computer" - Properties - Memory (i think). Near the bottom it has settings for "Virtual Memory" set this to 0. Reboot a couple of times & do a defrag (should be faster this time as 2nd time usually is). Then re-set Virtual Memory to about 2xRam and make sure it stays at a fixed sized. Windows uses the swap file quite a lot and tries to let it keep changing size which sounds great but ends up with this crucial system file getting very badly fragmented. Since the Windows defrag can't cope with system files the machine will gradually grind to an almost complete halt which kinda forces you to take it to a shop or buy a new machine. Optimising the swap file "pagefile.sys" gets it right back to about the speed of the machine when you first bought it.

Good luck and regards from
Tom :)

Tom (tom6) said : #41

Hi again :)

If you do stick with Ubuntu these guides might help you migrate
https://help.ubuntu.com/community/SwitchingToUbuntu/FromWindows

Also it is worth running through the Medibuntu page to get all your multi-media sorted in 1 easy session
https://help.ubuntu.com/community/Medibuntu
Sorry, that really is the last thing for getting Ubuntu fully usable!

Good luck and regards again from
Tom :)

Can you help with this problem?

Provide an answer of your own, or ask paul parker for more information if necessary.

To post a message you must log in.