error 5 after installing Ubuntu 9.04 next to XP

Asked by alienG

Hi. I decided to switch to Ubuntu to make my life easier, but.. After installing I can't run neither XP nor Ubuntu. I get Error 5 message after restart. I reinstalled Ubuntu three times and it's all the same. Now I am running from CD. Please help me somebody! I was trying to find answers in forums but it seems there are none. Here is what I have for the starters:

ubuntu@ubuntu:~$ sudo fdisk -ul

Disk /dev/sda: 320.0 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders, total 625142448 sectors
Units = sectors of 1 * 512 = 512 bytes
Disk identifier: 0x00000001

   Device Boot Start End Blocks Id System
/dev/sda1 * 63 268912034 134455986 7 HPFS/NTFS
/dev/sda2 268912035 625137344 178112655 5 Extended
/dev/sda5 268912098 619900154 175494028+ 83 Linux
/dev/sda6 619900218 624783914 2441848+ 83 Linux
/dev/sda7 624783978 625137344 176683+ 82 Linux swap / Solaris

before last reinstall I formated the non XP portion to ext3. probably that's why I have sda5 and sda6. All I want is to turn on my PC and have two boot choices - between WindowsXP(home) and Ubuntu 9.04.

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu grub Edit question
Assignee:
No assignee Edit question
Solved by:
Tom
Solved:
Last query:
Last reply:
Revision history for this message
actionparsnip (andrew-woodhead666) said :
#1

I recommend you reinstall grub using the live cd. Did you MD5 check the ISO file before burning? Did you verify the CD once initially booted to?

https://help.ubuntu.com/community/GrubHowto

reinstall grub and see how you go.

Error 5 : "Disk geometry error"

This error is returned when a read is attempted at a linear block address beyond the end of the BIOS translated area. This generally happens if your disk is larger than the BIOS can handle (512MB for (E)IDE disks on older machines or larger than 8GB in general).

Revision history for this message
Tom (tom6) said :
#2

Hi

I noticed from "fdisk" that your drive seems to start at cylinder 63 - "/dev/sda1 * 63", apart from that it's looking good. With linux it's easier to keep your data&settings separate from the main part of the OS & all the programs so having the 2 separate partitions is an advantage. We keep all the data&settings in one main folder called "/home", with sub-folders such as "/home/username/Pictures". Typically these folders get used even by Kodak cameras rather than setting up some obscure folder hidden away somewhere as happens in Windows. We can help you take advantage of having /home on a separate partition with almost no extra fuss :)

When you are running Ubuntu from the Cd having chosen the option "Try Ubuntu without changes to this machine" we call that a "LiveCd session".

It would be a good plan to use the "Places" menu on the top taskbar to backup your data from your Windows partitions (Windows calls partitions "drives" even though they are just parts of the 1 physical drive in your system). To backup the data simply copy it all to an external drive or burn onto cd/dvds. Then open a terminal console to type in more commands, just as you did with the "fdsik -l" command but this time type

free -m

this should show how large your ram is. It will also show how large the "Linux swap / Solaris" partition is and it would be helpful if you could let us know those values. Then go up to the top taskbar and click on

System - Administration - Partition Editor

Please let us know if there is another partition in front of sda1 and how large it is, also let us know how large sdasda6 & sda7 are. Also let us know if sda1 is completely full, if it is then don't follow any more advice in this post until after we can clear some space on that Windows "C: "drive"". Assuming there's enough free-space right-click on sda1 and resize it so that the start of the partition leaves 100Mb + (2 x Ram) of empty space at the 'beginning' of the physical drive. If you took the space off the end of the partition and then moved the partition along then click the "Undo" arrow button and make sure the whole operation is going to get done in just 1 step, otherwise it can take ages especially on such a large hard-drive :) Now click on "Apply", this really will take quite a long time, plenty of time to make a cup of coffee, or possibly even have lunch!

The next steps are much faster :) Right-click at the beginning of the grey space and create a new 100Mb partition at the very start of the hard-drive, this needs to be a Primary, ext3 partition (this will be the "/boot" partition). After it make another partition, this one filling the rest of the empty space - it needs to be larger than the size of your ram, about twice ram (on such a large disk) is about perfect. this new partition should also be a Primary Partition but should be a "file-system" we call "linux-swap" rather than another "ext3". At this point when you click on the "Apply" button it should complete both operations quite quickly.

At this point it would be good if you could do the "sudo fdisk -l" command again and let us see the results of that this time :) Just to check that it's all going ok.

Now assuming that sda6 is over 5Gb you can do a really good install, roughly along the lines of
https://help.ubuntu.com/community/WindowsDualBoot
but crucially when you get to the partitioning section about halfway through choose the bottom option of the 3 to do "Manual Partitioning". It will re-scan the drive and then show exactly how you have already laid out the drive but it has different colour-coding to gparted. Right click and "Edit" the tiny 100Mb partition at the beginning of the hard-drive to set it's "Mount Point" to "/boot", it's ok to reformat this partiton. Next "Edit" sda5 (the larger of the 2 pre-existing partitions) to set it's "Mount Point" to "/home" and finally edit sda6 to set it's "Mount Point" to "/" (also called "Root" as it is the start of the linux file-structure), again it's ok to reformat both of these 2 partitions. The crucial one to make sure is UNticked in the "Format?" column is sda1, probably the 3rd partition along by now - because that is the one that Windows calls your "C: drive" so reformatting it would be really bad.

After this install completes you should be able to happily reboot into eithe Windows or Ubuntu. The menu will hopefully have a few more options such as one for Ubunu called "recovery mode" which has some handy menu items in a disturbingly blue screen - typically it's worth running through most of these tasks about once a month before choosing "Resume normal boot" which is the default option on that menu. There are a couple of things to do to tidy that menu but we can help with that later.

Good luck with all this!
Feel free to ask for more (or less) detail about any of this!
Good luck and regards from
Tom :)

Revision history for this message
alienG (gedira) said :
#3

Hi. Thank you for your translations from Linux to Windows language. It is quite a job to switch to another system. I have to learn a lot, and from the very start. I didn't even see yet a selection menu for different OS boot. From last post I have some changes. I tried to fix booting with Super Grub Disk from CD. Tried auto fix of both, linux and windows, and it didn't fix anything, then I started trying other options and probably messed up more. Then deleted linux partitions and started reinstalling Ubuntu again, then it said there is an error on CD. Reburned it at the lowest speed. Installed. I did some readings on google. Tried to go to Grub from Live CD and fix it. Cant find anything in Grub. root (h0,0) disk not found. Boot/grub not there. From Super Grub Disk I get error 15. Finaly I got boot_info_script032.sh and here it is what I have now. Going to sleep now. Tomorrow is day 4 :}. I am going to print and read your post several times, Tom. I have to change my faith from Win to Lin. It is pretty hard. Here is what the boot_info gave me:

============================= Boot Info Summary: ==============================

 => Grub0.97 is installed in the MBR of /dev/sda and looks on the same drive
    in partition #5 for /boot/grub/stage2 and /boot/grub/menu.lst.

sda1: _________________________________________________________________________

    File system: ntfs
    Boot sector type: Windows XP
    Boot sector info: No errors found in the Boot Parameter Block.
    Operating System: Windows XP
    Boot files/dirs: /boot.ini /ntldr /NTDETECT.COM

sda2: _________________________________________________________________________

    File system: Extended Partition
    Boot sector type: -
    Boot sector info:

sda5: _________________________________________________________________________

    File system: ext3
    Boot sector type: -
    Boot sector info:
    Operating System: Ubuntu 9.04
    Boot files/dirs: /boot/grub/menu.lst /etc/fstab

sda6: _________________________________________________________________________

    File system: swap
    Boot sector type: -
    Boot sector info:

=========================== Drive/Partition Info: =============================

Drive: sda ___________________ _____________________________________________________

Disk /dev/sda: 320.0 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders, total 625142448 sectors
Units = sectors of 1 * 512 = 512 bytes
Disk identifier: 0x00000001

Partition Boot Start End Size Id System

/dev/sda1 * 63 267,032,429 267,032,367 7 HPFS/NTFS
/dev/sda2 267,032,430 625,137,344 358,104,915 5 Extended
/dev/sda5 267,032,493 619,129,034 352,096,542 83 Linux
/dev/sda6 619,129,098 625,137,344 6,008,247 82 Linux swap / Solaris

blkid -c /dev/null: ____________________________________________________________

/dev/loop0: TYPE="squashfs"
/dev/sda1: UUID="207812D07812A516" TYPE="ntfs"
/dev/sda5: UUID="9e9cd019-3501-449f-9cc6-01865e03e731" SEC_TYPE="ext2" TYPE="ext3"
/dev/sda6: UUID="e687ce20-0cd5-4f6f-90c4-247d1ad6a01f" TYPE="swap"

=============================== "mount" output: ===============================

proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
tmpfs on /lib/modules/2.6.28-11-generic/volatile type tmpfs (rw,mode=0755)
tmpfs on /lib/modules/2.6.28-11-generic/volatile type tmpfs (rw,mode=0755)
tmpfs on /lib/init/rw type tmpfs (rw,nosuid,mode=0755)
varrun on /var/run type tmpfs (rw,nosuid,mode=0755)
varlock on /var/lock type tmpfs (rw,noexec,nosuid,nodev,mode=1777)
udev on /dev type tmpfs (rw,mode=0755)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
devpts on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=620)
rootfs on / type rootfs (rw)
/dev/sr0 on /cdrom type iso9660 (ro,noatime)
/dev/loop0 on /rofs type squashfs (ro,noatime)
fusectl on /sys/fs/fuse/connections type fusectl (rw)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev)
gvfs-fuse-daemon on /home/ubuntu/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=ubuntu)

================================ sda1/boot.ini: ================================

[boot loader]

timeout=3

default=multi(0)disk(0)rdisk(0)partition(1)\WINDOWS

[operating systems]

C:\CMDCONS\BOOTSECT.DAT="Microsoft Windows Recovery Console" /cmdcons

multi(0)disk(0)rdisk(0)partition(1)\WINDOWS="Microsoft Windows XP Home Edition" /fastdetect /NoExecute=OptIn /noguiboot

=========================== sda5/boot/grub/menu.lst: ===========================

# menu.lst - See: grub(8), info grub, update-grub(8)
# grub-install(8), grub-floppy(8),
# grub-md5-crypt, /usr/share/doc/grub
# and /usr/share/doc/grub-doc/.

## default num
# Set the default entry to the entry number NUM. Numbering starts from 0, and
# the entry number 0 is the default if the command is not used.
#
# You can specify 'saved' instead of a number. In this case, the default entry
# is the entry saved with the command 'savedefault'.
# WARNING: If you are using dmraid do not use 'savedefault' or your
# array will desync and will not let you boot your system.
default 0

## timeout sec
# Set a timeout, in SEC seconds, before automatically booting the default entry
# (normally the first entry defined).
timeout 10

## hiddenmenu
# Hides the menu by default (press ESC to see the menu)
#hiddenmenu

# Pretty colours
#color cyan/blue white/blue

## password ['--md5'] passwd
# If used in the first section of a menu file, disable all interactive editing
# control (menu entry editor and command-line) and entries protected by the
# command 'lock'
# e.g. password topsecret
# password --md5 $1$gLhU0/$aW78kHK1QfV3P2b2znUoe/
# password topsecret

#
# examples
#
# title Windows 95/98/NT/2000
# root (hd0,0)
# makeactive
# chainloader +1
#
# title Linux
# root (hd0,1)
# kernel /vmlinuz root=/dev/hda2 ro
#

#
# Put static boot stanzas before and/or after AUTOMAGIC KERNEL LIST

### BEGIN AUTOMAGIC KERNELS LIST
## lines between the AUTOMAGIC KERNELS LIST markers will be modified
## by the debian update-grub script except for the default options below

## DO NOT UNCOMMENT THEM, Just edit them to your needs

## ## Start Default Options ##
## default kernel options
## default kernel options for automagic boot options
## If you want special options for specific kernels use kopt_x_y_z
## where x.y.z is kernel version. Minor versions can be omitted.
## e.g. kopt=root=/dev/hda1 ro
## kopt_2_6_8=root=/dev/hdc1 ro
## kopt_2_6_8_2_686=root=/dev/hdc2 ro
# kopt=root=UUID=9e9cd019-3501-449f-9cc6-01865e03e731 ro

## default grub root device
## e.g. groot=(hd0,0)
# groot=9e9cd019-3501-449f-9cc6-01865e03e731

## should update-grub create alternative automagic boot options
## e.g. alternative=true
## alternative=false
# alternative=true

## should update-grub lock alternative automagic boot options
## e.g. lockalternative=true
## lockalternative=false
# lockalternative=false

## additional options to use with the default boot option, but not with the
## alternatives
## e.g. defoptions=vga=791 resume=/dev/hda5
# defoptions=quiet splash

## should update-grub lock old automagic boot options
## e.g. lockold=false
## lockold=true
# lockold=false

## Xen hypervisor options to use with the default Xen boot option
# xenhopt=

## Xen Linux kernel options to use with the default Xen boot option
# xenkopt=console=tty0

## altoption boot targets option
## multiple altoptions lines are allowed
## e.g. altoptions=(extra menu suffix) extra boot options
## altoptions=(recovery) single
# altoptions=(recovery mode) single

## controls how many kernels should be put into the menu.lst
## only counts the first occurence of a kernel, not the
## alternative kernel options
## e.g. howmany=all
## howmany=7
# howmany=all

## specify if running in Xen domU or have grub detect automatically
## update-grub will ignore non-xen kernels when running in domU and vice versa
## e.g. indomU=detect
## indomU=true
## indomU=false
# indomU=detect

## should update-grub create memtest86 boot option
## e.g. memtest86=true
## memtest86=false
# memtest86=true

## should update-grub adjust the value of the default booted system
## can be true or false
# updatedefaultentry=false

## should update-grub add savedefault to the default options
## can be true or false
# savedefault=false

## ## End Default Options ##

title Ubuntu 9.04, kernel 2.6.28-11-generic
uuid 9e9cd019-3501-449f-9cc6-01865e03e731
kernel /boot/vmlinuz-2.6.28-11-generic root=UUID=9e9cd019-3501-449f-9cc6-01865e03e731 ro quiet splash
initrd /boot/initrd.img-2.6.28-11-generic
quiet

title Ubuntu 9.04, kernel 2.6.28-11-generic (recovery mode)
uuid 9e9cd019-3501-449f-9cc6-01865e03e731
kernel /boot/vmlinuz-2.6.28-11-generic root=UUID=9e9cd019-3501-449f-9cc6-01865e03e731 ro single
initrd /boot/initrd.img-2.6.28-11-generic

title Ubuntu 9.04, memtest86+
uuid 9e9cd019-3501-449f-9cc6-01865e03e731
kernel /boot/memtest86+.bin
quiet

### END DEBIAN AUTOMAGIC KERNELS LIST

# This is a divider, added to separate the menu items below from the Debian
# ones.
title Other operating systems:
root

# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/sda1
title Microsoft Windows XP Home Edition
rootnoverify (hd0,0)
savedefault
makeactive
chainloader +1

=============================== sda5/etc/fstab: ===============================

# /etc/fstab: static file system information.
#
# Use 'vol_id --uuid' 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>
proc /proc proc defaults 0 0
# / was on /dev/sda5 during installation
UUID=9e9cd019-3501-449f-9cc6-01865e03e731 / ext3 relatime,errors=remount-ro 0 1
# swap was on /dev/sda6 during installation
UUID=e687ce20-0cd5-4f6f-90c4-247d1ad6a01f none swap sw 0 0
/dev/scd0 /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0

=================== sda5: Location of files loaded by Grub: ===================

 307.7GB: boot/grub/menu.lst
 307.7GB: boot/grub/stage2
 307.7GB: boot/initrd.img-2.6.28-11-generic
 307.8GB: boot/vmlinuz-2.6.28-11-generic
 307.7GB: initrd.img
 307.8GB: vmlinuz

Thank you

Revision history for this message
Tom (tom6) said :
#4

It is very tough with a very steep learning curve at the very beginning. Once you have overcome the initial hurdles and installed it as a dual-boot it settles down a lot. Most of us didn't have any experience installing any OS before starting with linux as Windows is pre-installed by teams of experts doing batch runs on one type of hardware setup. In linux we have to work out the foibles of our own hardware and do the work of a team of experts, and that's just for 1 machine! So the fact you've got this far is pretty awesome and you deserve congrats for that! Here's a general guide worth dipping into from time to time to help with translations
https://help.ubuntu.com/community/SwitchingToUbuntu/FromWindows

Something for morale
https://help.ubuntu.com/community/Antivirus

and something for general help to get access to proper community documentation aimed at Ubuntu specifically
https://help.ubuntu.com/community/Signpost?action=show&redirect=HowToGetHelp
https://help.ubuntu.com/community/SwitchingToUbuntu

I'll have to get back to you about your main question a little later
Good luck and regards from
Tom :)

Revision history for this message
alienG (gedira) said :
#5

Hi Again. Didn't do any changes from last post. Now going step by step.
1.
ubuntu@ubuntu:~$ sudo free -m
             total used free shared buffers cached
Mem: 1002 558 444 0 72 292
-/+ buffers/cache: 193 808
Swap: 2933 0 2933

2. Partitions. There are three.

/dev/sda1, ntfs, size 127.33GiB , used 56.09GiB, unused 71.24 GiB, boot. (In graphic bar the yellow from the left to right almost to the middle). That's where my WinXP is.

/dev/sda2(has a key icon next to it), extended, size 170.76GiB

      /dev/sda5, ext3, size 167.89GiB, used 4.75GiB, unused 163.14GiB (on the bar just a little bit yellow on the lefts side(4.75GiB)).

     /dev/sda6(has a key icon next to it), linux-swap, used 2.86GiB

Before going to the next step I have some questions.
My Ram is 1002. Right? Then 100+2*1002=2104Mb. I need to make this partition on sda1, which is ntfs with my WinXP. Is that correct? The Resize will move(visually) the yellow part on the partition bar to the right and then it will be a little white, then yellow and then white again on the ntfs? I just want to make sure before resizing/moving, that that's correct. And because of resizing I can loose some data and that's why I need a backup? (I am too lazy to make backups of 56 GiB, so I am going to take a risk and skip that step. Tell me if I am being too stupid here :)). I am going to wait for confirmations before I try to resize sda1.
Tank you

Revision history for this message
Tom (tom6) said :
#6

Things are only likely to go wrong if you don't backup.

It's only stuff that you would find impossible to re-build from source or that doesn't exist elsewhere already that is vital to backup. Also if you haven't got an external drive then you could at least copy all "Documents&Settings" from sda1 onto sda5. Ubuntu is quite quick at file transfer - even using a LiveCd session. Since sda5 isn't being resized or moved at this stage it's a lot safer than sda1. Although it is on the same drive so really collect your old love-letters and stuff onto cd/dvd additionally if you can ;)

The yellow part always starts from the beginning of the partition, it just represents how much data is on the partition rather than exactly where it is placed. Sometimes you find you can't resize an ntfs or fat partition because the data on it is too fragmented and needs to be defragmented first from inside a Windows session. The best way to find out is to see if it doesn't allow the shrinking to start. As you are effectively pushing all the data that is at the start of the partition to much later on along the physical drive, well this is something that takes time and is why the resizing is likely to take a long time.

Revision history for this message
Tom (tom6) said :
#7

Your ram is quoted as 1002 but it's not a proper computer number. The nearest computer number is 1024. So the space at the beginning of the drive is better as 2148 but an exact figure isn't really what's required. If there's a tick box saying "Round to cylinders" then it's worth ticking it. Also the minimum size that your linux-swap could usefully be is 1002, rounded to 1024 for safety and add the 100Mb on so that's about 1124. So anywhere between 1124 and 2148 (or a little over) is about perfect. If you give it 2148 then you're more prepared for perhaps adding more ram to your machine sometime in the future. There's 2 main reasons that quoted ram is slightly less than a full computery type number and the most likely reason is probably that some parts of the ram have become corrupted and have been carefully marked as areas that can't be used. So i would guess that your ram sticks are one of the newer kinds such as DDR or DDR2

Revision history for this message
Tom (tom6) said :
#8

Ok, so you are probably (hopefully) resizing about now :)
Shaving 2148Mb off the front of sda1 to leave a grey "unallocated" space at the front of the drive :)
Good luck with this!
Regards from
Tom :)

Revision history for this message
alienG (gedira) said :
#9

Thank you for a quick response, Tom. And thank you for explaining the little things. I hope more newbies will read this and it's better to be clear about everything. Like a number rounding or a strange size Ram. I think mine is DDR2. I have three of them(only 3 slots available). But anyways. Thank you for stopping me with no backup. I will go through my stuff and see what's worth backing up. And the partition slider for sda1 is working, so I am almost ready for the big changes.
I will most likely have more questions later. Thank you so much Tom.

Revision history for this message
Tom (tom6) said :
#10

The main thing is to copy the whole "Documents&Settings" folder to sda5. It probably doesn't get all your camera pictures and odd stuff like that which Windows likes to scatter all over everywhere but it does get pretty much everything. If yu are hunting through folder-by-folder then make sure that the file-browsers "View" menu gives you a side pane and shows hidden files. Then at the top of the side-pane it should say "Places" by default but has a drop-down arrow - so you can change this to "Tree" which is really cool man lol. It looks a lot like the Windows Explorer type thing and lets you use the arrow keys to swiftly race through 1 folder after another very quickly :)

Revision history for this message
alienG (gedira) said :
#11

Ok. Backed up WinXP files, then Resized sda1. It took about two hours. And here is what I have :
sudo fdisk -l

Disk /dev/sda: 320.0 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000001

   Device Boot Start End Blocks Id System
/dev/sda1 * 275 16622 131315310 7 HPFS/NTFS
/dev/sda2 16623 38913 179052457+ 5 Extended
/dev/sda3 1 13 104391 83 Linux
/dev/sda4 14 274 2096482+ 82 Linux swap / Solaris
/dev/sda5 16623 38539 176048271 83 Linux
/dev/sda6 38540 38913 3004123+ 82 Linux swap / Solaris

Partition table entries are not in disk order

Question. Do I delete sda5 and sda6? Make them unalocated?

Revision history for this message
alienG (gedira) said :
#12

I think I got it. There will be 4 parts of Linux? 1. /boot 2. /home 3. sda5 mounted to /home 4. sda6 mounted to / (root)? And then WinXP part left how it is and not formated. All others I can format in this section. Is that right? I think I got it. And this one "Partition table entries are not in disk order" probably can be fixed later, or maybe it doesn't matter the order? OK. Going to install again, I hope it will be the final, and working product. (5th installation)

Revision history for this message
alienG (gedira) said :
#13

Hey!!! It worked!!! Here is the final look:

Disk /dev/sda: 320.0 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000001

   Device Boot Start End Blocks Id System
/dev/sda1 * 275 16622 131315310 7 HPFS/NTFS
/dev/sda2 16623 38913 179052457+ 5 Extended
/dev/sda3 1 13 104391 83 Linux
/dev/sda4 14 274 2096482+ 82 Linux swap / Solaris
/dev/sda5 16623 38539 176048271 83 Linux
/dev/sda6 38540 38913 3004123+ 83 Linux

Partition table entries are not in disk order

Finally I got to see the table to boot to different OS! Do I have to worry about disk order?

In installation partition section I did (as Tom directed) the manual partitioning. Then for sda3 selected ext3, /boot and format options. sda5 - ext3, /home, format. and sda6 - ext3, /, format. I wasn't sure what to do with sda4, but as it was not mentioned in directions, i didn't do anything with it.

Thank you again, Tom. I was lost reading forums. There are so many of them but I couldn't figure too much. Would have taken me a month. Now I am going to work on software little by little.
Thank you once again :))))

Revision history for this message
Tom (tom6) said :
#14

Brilliant, nicely done!! :))))
So now you can boot into Windows or Ubuntu and the boot menu has a few different options for Ubuntu?

The fdisk note "Partition table entries are not in disk order" is just to remind people that are more used to looking at gui representations - it's not a problem at all. Even if your partitions do happen to be numbered from the start of the drive it still prints that message lol. Writing the partitions in order they appear on the disk you hopefully now have

sda3 /boot
sda4 linux-swap - this doesn't have a "mount point" that you need to define
sda1 Xp
sda2 Extended (bucket)
 . sda5 /home
 . sda6 /

I usually find that after playing around installing tons of stuff and tweaking everything in sight i tend to break the system somehow and eventually need to reinstall the OS. When you get to that point it would be worth deleting sda6, then move sda5 to the end of the drive and resize it. The create a new sda6 in front of sda5 but this time sda6 will only need to be about 5Gb.

When you install Ubuntu at that point make sure you don't format sda5 and then you'll find that a lot of things remain personalised your way and your data should also have remained safe.

Data&Settings are much easier to schedule read/writes to/from but in normal desktop usage the OS has many unpredictable read/writes, so while data can be cached into swap & ram to appear like it's all being accessed extremely fast the basic operations of the OS will appear slower the further "/" is from the start of the drive. Apparently read/write speeds near the end of the drive can be down to as little as half the read/write speed that you get at the beginning of the drive! Given that data partitions are almost always going to be much marger than OS space it's worth moving the data partition to the end of the drive. Of course in Windows it's extremely difficult to separate the data from the OS - it takes some major hacking of the infamous registry.

Windows really needs to be near the start of the drive as it suffers very badly from speed issues. However, your hardware is unusual in needing the boot sector to be within the first 1024Mb of space on your hard-drive. Given that linux-swap is so small and yet has such a huge effect on performance (unless your ram is over 2Gb & over 4Gb swap becomes mostly irrelevant) i thought it was well worth pushing Windows back a little more in order to get a significant performance boost for linux while hardly affecting Windows at all :) If you have to wait 2hrs for something you want to enjoy more benefit than just fixing a problem so fine tuning the performance of the system seemed like a good plan :) Putting sda6 in front of sda5 wont have a huge effect because it wont have moved sda6 all that much closer to the front of the drive but you might notice some slight performance increase under certain conditions such as when you open and close a whole batch of different apps randomly all at the same time.

Windows also uses swap but it eschews the linux-swap partition approach and instead keeps a file called "pagefile.sys" which defaults to being able to change size and so it gets heavily fragmented and Windows Defragmenters can't defragment system files like that! Also if you have 3 different Windows apps open that all need the same library then each app will open a separate version of that library and shove the all into swap. In linux that library would have been separated out of the apps and the 3 apps can happily share it so it only needs to be opened once. This also has advantages if that library needs updating - only the 1 version of the library needs to be updated and then all 3 apps benefit. Anyway, that's one reason that Window's uses so much more ram than linux and that's one reason why Windows is so much slower - ram gets too full faster in Windows.

Ooops, lol - this was meant to be a short post!
Please let me know if you can boot into both Ubuntu & Windows :)
Good luck and regards from
Tom :)

Revision history for this message
Tom (tom6) said :
#15

marger = larger

One typo amongst many, sorry about that

Revision history for this message
alienG (gedira) said :
#16

Hi. I have to run now, but I just tried WinXP and it doesn't work. It says - Starting up.... I waited for some three minutes, but didn't hear any hard drive activity. Maybe you have some thoughts how to fix it? Or why it doesn't start?
Have to run

Revision history for this message
Tom (tom6) said :
#17

Ubuntu is booting fine?

Revision history for this message
alienG (gedira) said :
#18

Yes Ubuntu Is perfect. I am updating and installing all the plugins and addons, that I need.

Revision history for this message
Tom (tom6) said :
#19

Ok, that's a Windows problem then lol, Sorry i'm unlikely to be able to help there. For Ubuntu tho it's worth working all the way through this guide
https://help.ubuntu.com/community/Medibuntu
I go with almost entirely non-free components, i guess one day someone might ask me to pay licence fees for some codecs but i might go completely OpenSource and really free myself before then ;)

You might find this handy for dipping into occasionally
https://help.ubuntu.com/community/SwitchingToUbuntu/FromWindows

Just to make sure about Windows please type this into a terminal console

cd /boot/grub
ls
sudo cp menu.lst menu.220709
ls
gedit menu.lst

note the "ls" is lower-case "LS" and gives a LiSt of what's in the folder. "dir" also works but it's not colour-coded. The "cp" command doesn't normally needed to be sudoed but in this instance the grub folder is a system folder so it's protected from accidental dumb mistakes. Sudo will ask for your normal user password, not your SuperUser/Root one. Anyway, after all that i was only interested in what gedit shows menu.lst as having in the Windows section at the very end of that file.

Also i was wondering how far through the bootup Windows gets before it falls over. Does it get to the blue bar going across the screen?

Also i was wondering if you have a Windows Cd that we might be able to use to repair your Windows with?

Umm, and have you checked that all your data appears to be ok?
Thanks, good luck and regards from
Tom :)

Revision history for this message
alienG (gedira) said :
#20

Windows don't get anywhere. Only Starting up... in the left corner on black screen. Files seem to be ok. Grub is not ok.

grub> root (hd0,0)

Error 21: Selected disk does not exist

grub>

Should I try Super Grub Disk now?

Revision history for this message
alienG (gedira) said :
#21

desktop:/boot/grub$ ls
default fat_stage1_5 menu.220709 minix_stage1_5 stage2
device.map installed-version menu.lst reiserfs_stage1_5 xfs_stage1_5
e2fs_stage1_5 jfs_stage1_5 menu.lst~ stage1

Revision history for this message
alienG (gedira) said :
#22

desktop:~$ sudo cp menu.lst menu.220709
[sudo] password for gedas:
cp: cannot stat `menu.lst': No such file or directory

it seems there is no grub?

Revision history for this message
Tom (tom6) said :
#23

Ooops, no - it's all ok

Revision history for this message
Tom (tom6) said :
#24

When you did "ls" it gave

default fat_stage1_5 menu.220709 minix_stage1_5 stage2
device.map installed-version menu.lst reiserfs_stage1_5 xfs_stage1_5
e2fs_stage1_5 jfs_stage1_5 menu.lst~ stage1

and you can see "menu.lst" in the middle there. note that "lst" is lower-case "LST" short for "List". Maybe you thought "1st" like i did first time?

Also we don't need the grub command-line - that's just confusing the issue. We just want the regular linux command-line which has something like "desktop:~$" before the cursor, not "grub>" they are very different command-lines. Note that when you are on the grub command-line you can find where it thinks all it's files are by typing commands such as

find /boot/grub/menu.lst

find /boot/grub/stage1

both of these commands should show only 1 result on your system at the moment. It should be showing "(hd0,2)" because the boot partition is sda3 and grub translates that into computer type numbering which starts from 0 rather than human 'counting' which starts at 'a' or '1' - so a gets converted to 0 and 3 gets converted to 2 - hence (hd0,2).

Revision history for this message
Tom (tom6) said :
#25

The 'a' of sda3 gets converted to 0 and the '3' gets converted to 2 - hence (hd0,2).

Revision history for this message
Tom (tom6) said :
#26

Err the point being that "grub> root (hd0,0)" was looking for the grub boot files in your Xp partition and gave you an error message because it couldn't find them there ;) heheheheh. Lucky really because we really do not want to reinstall grub at this point. What we want to do is have a look at what it's trying to do and then see if we can edit it to give it a helping hand later ;)

Revision history for this message
Tom (tom6) said :
#27

What i'm hoping not to find in menu.lst is a section something very much like this at the very end

# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/sda1
title Microsoft Windows
root (hd0,0)
savedefault
makeactive
chainloader +1

What i'm really hoping for is that in your menu.lst the "root (hd??)" is pointing to a wrong partition and then we can just edit it to point at (hd0,0) and then everything will magically be fixed :)
Good luck and regards from
Tom :)

Revision history for this message
alienG (gedira) said :
#28

AAA!! New problem! I was installing players and some software and it said the disk is out of space! I tried to open hard drive. It says it can't mount it. Then I restarted and I got the blue screen with wit table and the message:

GDM could not write a new authorization entry dsk. Possibly out of dskspace. Error: No space left on device.

Help! Tom!!!

Revision history for this message
Tom (tom6) said :
#29

You already have stacks of software already included in a standard Ubuntu install. Totem is a great multimedia player. <sighs> (lol)

During bootup you should have lots of different options for booting into Ubuntu. The 2nd option should have "recovery mode" at the end of it's line. This takes you to a menu on a disturbingly blue screen. Try using "Clear some space" and then "Fix broken packages".

Have you been installing Windows stuff inside Ubuntu?

Revision history for this message
alienG (gedira) said :
#30

Update. Restarted with recovery console and used Clean-> try to make some free space, then Normal boot. It loaded, but obviously I have to change something somewhere or soon it will be the same again. It seems that it might updatng and installing everyting on the small partition.
I wasn't ableto boot Win XP.

Revision history for this message
alienG (gedira) said :
#31

Why dos it say -no space left on disk? There is 170GiB (around)

Revision history for this message
alienG (gedira) said :
#32

Sorry for typos too. This is a computer with old keyboard :)

Revision history for this message
Tom (tom6) said :
#33

Ok, boot into a LiveCd session and with gparted resize the /home partition down by a bit and resize the / partition up by a bit. How much free space have you got on the /home partition? You are going to need to leave quite a bit of space in there but you can resize it down a bit :)

I would guess that you had a huge amount of updates and hopefully now you'll have cleared off the downloads that Ubuntu tends to save against a rainy day. So really as long as you are reasonably careful you shouldn't have too much problem from now on. Are you installing stuff through the package managers? It's safer to stick with the package managers. If you don't want Office packages then uninstalling OpenOffice would give you quite a bit more room ;) AbiWord is good if you only need a word-processor occasionally. There are some other fairly large apps you could try uninstalling to make a bit more space.

Good luck and regards from
Tom :)

Revision history for this message
Tom (tom6) said :
#34

Almost all your drive is being used by Windows. We have crammed Ubuntu into a very small space and it's only certain parts of this small space that's full. You could use a LiveCd session to resize Windows down by quite a lot from the end - and then expand the extended partition and then expand the linux partitions that are at the end of the drive. This is likely to be a whole lot faster than the 2hours it took to take a bit of space off the front of Windows.

The main problem we have now is that we haven't sorted out the 1 problem but are introducing others so the whole situation is getting over complex. It would be better to just explore Ubuntu as it is and attempt to fix the problem of booting into Windows. Although i would recommend getting Wesnoth if you have enough room for it - unless you prefer fps'

Anyway
Good luck and regards again from
Tom :)

Revision history for this message
Tom (tom6) said :
#35

Please copy the Windows part of menu.lst into here so we can try to fix this problem first? lol hehehehe. It's good to see the excitement tho :))) I'm glad you're enjoying the look of Ubuntu and messing around with it like a kid with a new toy :))) lol

Revision history for this message
alienG (gedira) said :
#36

Booting with live CD now. I was installing ATI drivers and that's when I got the message that there is no where to install. Are you saying that 170Gb is only for storage, and all the programs are installed on this 1Gb strip with / ?

Revision history for this message
Tom (tom6) said :
#37

I thought that / was 4 or 5Gb? Please copy the info that's in the bottom pane of gparted and lets sort this out then

Revision history for this message
Tom (tom6) said :
#38

Ok i guess the first thing to do is to resize sda1 down by quite a healthy amount. I seem to remember sda1 has 70Gb free so resizing it down by 20 or 30Gb should be fine?

Revision history for this message
alienG (gedira) said :
#39

hehe :)) I like the toy. But still don't kow how to play with it :))). Anyways. Now I am looking at partitions. sda6 / size is 2.86Gb and 2.59Gb used. So I will make it bigger. sda5 /home is 167Gb with 3Gb used. Should I make sda6 / some 20Gb? I don't mind. When my HDD broke, I bought this one and windows had trouble to partition and I didn't have time so I was using 128Gb of 320. Linux was able to find all the rest of the space so I can leave it to fnders :)).

so, sda6 /home 20Gb is ok?

Revision history for this message
alienG (gedira) said :
#40

1 I don't know how to copy Windows part of menu.lst :(. I am not that fast .
2 The gparted in Terminal gave me a line "libparted: 1.8.8" and opened the Partition Editor. So I don't know how to copy info from left pane.

Revision history for this message
Tom (tom6) said :
#41

Nearly. The /home does need to be really large. Additional programs that your install to / wont usually take up much space, especially compared against Windows programs. So taking 20Gb off /home should more than do the trick - drop it down to 150Gb and give just the small extra space to /

Revision history for this message
Tom (tom6) said :
#42

Don't install the ati driver tho!!

Revision history for this message
Tom (tom6) said :
#43

See you tomorrow!

Revision history for this message
alienG (gedira) said :
#44

So guess what.. I was looking at my new Ubuntu and tried menu.lst. It says it's not installed. So I install it (from terminal). I am still not sure what I was looking for, but I thought I '' take a look at my partitions. Type sudo gparted. Says not installed. I am like, Hmm, strange, but ok. Install that. I don't know when and why it took off. Anyways, installed and then just staring at partitions and the NTFS partition is empty and there is an exclamation point. And it says that there is no space used, all partition is free. I try to open my drive from Places. Nothing. So then I opened a beer and sipping it and saying good bye to all my files(nothing important, but.... I backed up all nonrelpacable stuff). So. After I calmed down and started thinking what to do with that NTFS partition. Should I install Windows again or try some other OS.. I click once more on my drive and it got mounted. I look at the partition window - it's all back again! And Gparted looks better now. All the partitions have a key icon next to it and there is Mount point column, that was not there before. It shows which partiotion is /, which /home and /boot. There was non of that before.
So that was strange.

Revision history for this message
alienG (gedira) said :
#45

I deleted almost all lines that started with #. Those lines are explanations, like help lines. Right?
I thought I'll save some space here. :))

# menu.lst - See: grub(8), info grub, update-grub(8)
# grub-install(8), grub-floppy(8),
# grub-md5-crypt, /usr/share/doc/grub
# and /usr/share/doc/grub-doc/.

default 0

timeout 10

title Ubuntu 9.04, kernel 2.6.28-13-generic
uuid f111c9ed-e47c-4615-b4df-db1b0091815b
kernel /vmlinuz-2.6.28-13-generic root=UUID=7e2c7234-1bc8-48f9-b776-4c5b0f590559 ro quiet splash
initrd /initrd.img-2.6.28-13-generic
quiet

title Ubuntu 9.04, kernel 2.6.28-13-generic (recovery mode)
uuid f111c9ed-e47c-4615-b4df-db1b0091815b
kernel /vmlinuz-2.6.28-13-generic root=UUID=7e2c7234-1bc8-48f9-b776-4c5b0f590559 ro single
initrd /initrd.img-2.6.28-13-generic

title Ubuntu 9.04, kernel 2.6.28-11-generic
uuid f111c9ed-e47c-4615-b4df-db1b0091815b
kernel /vmlinuz-2.6.28-11-generic root=UUID=7e2c7234-1bc8-48f9-b776-4c5b0f590559 ro quiet splash
initrd /initrd.img-2.6.28-11-generic
quiet

title Ubuntu 9.04, kernel 2.6.28-11-generic (recovery mode)
uuid f111c9ed-e47c-4615-b4df-db1b0091815b
kernel /vmlinuz-2.6.28-11-generic root=UUID=7e2c7234-1bc8-48f9-b776-4c5b0f590559 ro single
initrd /initrd.img-2.6.28-11-generic

title Ubuntu 9.04, memtest86+
uuid f111c9ed-e47c-4615-b4df-db1b0091815b
kernel /memtest86+.bin
quiet

### END DEBIAN AUTOMAGIC KERNELS LIST

# This is a divider, added to separate the menu items below from the Debian
# ones.
title Other operating systems:
root

# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/sda1
title Microsoft Windows XP Home Edition
rootnoverify (hd0,0)
savedefault
makeactive
chainloader +1

Thank you

Revision history for this message
Tom (tom6) said :
#46

Yes, the LiveCd has gparted but the hard-drive install doesn't. I guess that when you're running Ubuntu from the hard-drive then most of the partitions will be locked or difficult to alter. I think the "Mount Point" column has only just appeared because until you installed Ubuntu none of those partitions had a "Mount Point" ;)

I'm sorry to hear about the Windows partition going strange like that. Even with data-recovery techniques and tools it's going to be quite challenging to get that back :(
https://help.ubuntu.com/community/DataRecovery
It's quite likely that a local company could do the job but it's usually fairly expensive to recover Windows stuff :( Have you got a proper Windows Cd? Sometimes there's a recovery mode on there although i'm not sure how useful something like that would be. I think it would be great if you could post a bug-report about what's happened to your Windows partition because it really shouldn't do that. In most programs just click on the "Help" menu and select "Report a bug/problem" and the program will collect useful stats, like what libraries and other dependencies it has available, what version numbers and then it should let you look through that before sending the report off to bug-squad. Bug-squad also need a brief summary of what the problem is and the report needs a title. Just like in Answers it's best to keep all that as short as possible. I couldn't find the "Report a problem" in Gparted's "Help" menu so it would just need a regular brief report like this
https://bugs.launchpad.net/ubuntu/+source/grub/+filebug
It's a pretty serious bug and now that you've said it i think this has occured to me before too so doubtless it needs to be reported. Doing so tends to be one of the key ways we get improvements in linux, it's seen as being helpful rather than seen as complaining :)

Good luck with this!
Regards from
Tom :)

Revision history for this message
Best Tom (tom6) said :
#47

Yes the menu.lst does look right :( It was really just the Windows stanza at the end that i was looking for but the rest of what you gave might be useful later maybe.

# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/sda1
title Microsoft Windows XP Home Edition
rootnoverify (hd0,0)
savedefault
makeactive
chainloader +1

The line "rootnoverify (hd0,0)" was pointing at the right place :( The lines starting with # are the same in almost every install and are 'only' explanatory notes but they can be handy to have on your own machine. I find that by scrolling past things like that i gradually learn stuff because every so often something catches my eye. A good line to add in is

howmany=2

as this should keep the menu a bit shorter after a few updates. It should be before the line "## ## End Default Options ##" (I'm not sure if positioning does make any difference but it might). Anyway to edit menu.lst you have to give the action "SuperUser" priveleges so on a normal command-line try

sudo gedit /boot/grub/menu.lst

it will ask for your normal user password, not your SuperUser or Root one. It will open gedit as normal but this time you can save changes. It's best not to delete the # lines from here! Thanks for saving the space in the thread tho :)

Can you copy the last couple of lines of gparted into here? It might be good to see how much space sda5 & sda6 have. I'm not sure what to do about sda1. Leaving it alone might mean the data is still there and maybe one day you'll be able to recover some of it. I think i have an old drive somewhere with a partition like that and a couple more drives that Windows managed to lose the partition tables for too. One day i hope to recover some of the stuff on those.

Apols, good luck and regards from
Tom

Revision history for this message
alienG (gedira) said :
#48

Thanks Tom, that solved my question.

Revision history for this message
Tom (tom6) said :
#49

Hi chap :)

Thanks for getting back to us.

Good luck and regards from
Tom :)

Revision history for this message
Tom (tom6) said :
#50

Hi :)

Have you been able to try the new Ubuntu 10.04 before it gets officially released?
http://www.ubuntulinux.org/testing/lucid/beta2
Trying it as a LiveCd or as an extra dual/multi-boot would be ideal. Developers and everyone are keen to try to iron out any problems before 10.04 gets officially released so you might find faster & more effective answers to your bug reports which would make 10.04 work better on your system for you

Thanks and regards from
Tom :)