/boot partition, broken directory link to what? and 2 broken links in root

Asked by dave.com

Hello.
My first Ubuntu install ever the file in / 'initrd.img' has a broken link with 'unknown' and so does the file 'vmlinuz'. I do not have permissions to modify these as root@ubuntu from LiveCD and I don't know how to chroot to my login /home user's profile.

Those 2 files should link to what file, their /boot counterparts?

How did this occur? Don't know. I still think the Ubuntu 8.04.1 LiveCD install went fine to this day. The IDE drive is selectable at the grub splash, Grub loads the other OS and that works. The Linux selection options do not load Ubuntu so that does not work. Here is a brief look at the drive table:
root@ubuntu:/media/disk/grub# fdisk -l

Disk /dev/sda: 60.0 GB, 60022480896 bytes
255 heads, 63 sectors/track, 7297 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x4c264c25

   Device Boot Start End Blocks Id System
/dev/sda1 * 1 7297 58613121 7 HPFS/NTFS

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

   Device Boot Start End Blocks Id System
/dev/sdb1 1 25493 204772491 7 HPFS/NTFS
/dev/sdb2 25494 38913 107796150 b W95 FAT32

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

   Device Boot Start End Blocks Id System
/dev/sdc1 * 1 37608 302078227+ 83 Linux
/dev/sdc2 38157 38913 6080602+ 5 Extended
/dev/sdc3 37609 38156 4401810 83 Linux
/dev/sdc5 38157 38913 6080571 82 Linux swap / Solaris

Partition table entries are not in disk order
root@ubuntu:/media/disk/grub#

 /usr/src/linux-headers-2.6.24-19-generic is linked with /usr/src/linux-headers-2.6.24-19 so Ubuntu is lying around somewhere, I just don't know where else to look (too new for me) LiveCD in root@ubuntu:/media/disk/root with /dev/sdc1 mounted on / the root directory folder appears empty. so does the boot directory.

menu.lst is almost stock standard Ubuntu repository grub issue apart from my editing the device/partition mappings. LiveCD PartMan method used was the manual partitioning scheme. I am pulling up a complete mystery on the error 15 and error 22's

There is a gzipped initrd.img-2.6.24-19-generic file in the /boot partition. All the other stuff there is there, I think: abi-2.6.24-19-generic, config-2.6.24-19-generic, System.map-2.6.24-19-generic, vmlinuz-2.6.24-19-generic and memtest86+.bin it all looks regulation. Grub's folder and the stage1_5 stuff looks okay too unless the grub exe is supposed to be there as well, I don't see that inside.

Can anyone enlighten me? Pehaps the Synaptic pkg Manager broke my file links? (I still need to fix them though)

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
dave.com
Solved:
Last query:
Last reply:
Revision history for this message
A. Denton (aquina) said :
#1

Were you ever able to boot the system after install to runlevel 5 and loading the GUI? If not you maybe have entered some wrong settings for the mount point. In fact the broken link with "unknown" doesn't make sense to me either. Unfortunaltely I don't have enough time to have a look at the source code.

For chrooting try the "chroot /mnt/sysimage" command. I'm from Red Hat centric distros and switched all my organizations clients to Debian based ones. Maybe that rescue mode uses an equialent storage procedure.

Finally I'd double check the grub boot options. If you installed the distro a few days ago and really performed a full sysem update using apt-get chances are good you still have the old kernel as an available grub option for booting. I'd also check for some grub mans to have a look at switches. Maybe it helps you with booting a minimalistic environment.

Good Luck!

PS: I'm quite sure synaptic is not responsible for that but I suggest you for furter instalations to perform your initial update (will be hundrets of packages) in run 3 (no X11!). Besides I hope you were using ext 3 as your file system. I had a lot of trouble in the past years with ext 2 and ReiserFS. Also stay away from XFS or such. The only alternative is JFS which I'd recommend for servers.

Revision history for this message
dave.com (dwmac) said :
#2

While I didn't resolve the direct problem, I did get root permissions after chroot by a simple su root which would let me save edited files. It took less than 10 minutes to completely re-install Linux including fresh partitions. While reaching Repair Console in XP takes maybe 15, if that says anything.

So, rather than give the world a brilliant Path tree algorithm or something the 2nd Sata hdd table (Linux span) is now sdc1 = / (reiserfs, primary), sdc2 = /boot (ext3, primary), sdc3 = /home (reiserfs, primary) and good ol' sdc5 = swap (swap, Extended)
I noticed a comment output by grub about GParted is deprecated io_seg something something ..had to do with handling the partiton table for scsi/sata I think.

Revision history for this message
A. Denton (aquina) said :
#3

Sounds good!

I hope your device controler can effectively handle 3 physical HDD's without a break down on transfer rates.

Revision history for this message
dave.com (dwmac) said :
#4

So far, I got Ubuntu up, Wine configured, XP drive seen by Ubuntu and
all its data intact (according to the XP installation CD Repair
Console). It however has a boot corruption with the message 'NTLDR' is
missing. I have tried the BOOTCFG /ADD command but I don't know what its
response queries require there's no documentation in Help there.

Here's my /etc/fstab and the relevant menu.lst and an fdisk -l It's all
been quite a rush getting something up:
___________________________________________________________________________________
# /etc/fstab: static file system information.
#
# -- This file has been automaticly generated by ntfs-config --
#
# <file system> <mount point> <type> <options>
<dump> <pass>

      proc /proc proc defaults
0 0
      none /dev/shm tmpfs defaults
0 0

# Entry for /dev/sda1 !! UNKNOW DEVICE !! :
UUID="3C0C12DA0C128F50" LABEL="Dead" ntfs-3g
nls=utf8,umask=0222,locale=en_AU.UTF-8,quiet 0 0

# Entry for /dev/sdb1 !! UNKNOW DEVICE !! :
UUID="CC98FCF798FCE13E" /windows/SATA-1A ntfs-3g
nls=utf8,umask=0222,locale=en_AU.UTF-8 0 0

# Entry for /dev/sdb2 !! UNKNOW DEVICE !! :
UUID="E55F-722F" /windows/SATA-1B vfat
iocharset=iso8859-1,shortname=mixed,utf8,umask=000,relatime,rw,uid=1000,locale=en_AU.UTF-8 0 1

# Entry for /dev/sdc1 !! UNKNOW DEVICE !! :
UUID="3f037536-598f-40a3-9f67-afe784d3219e" / ext3
rw,relatime,errors=remount-ro,data=ordered,locale=en_AU.UTF-8 0 1

# Entry for /dev/sdc2 !! UNKNOW DEVICE !! :
UUID="e66630b4-6497-4cbf-bce3-f14c0cc83fb8" /boot ext3 defaults
0 2

# Entry for /dev/sdc3 !! UNKNOW DEVICE !! :
UUID="94be235c-3ff3-4c48-a322-e5fb00865966" /home reiserfs noatime 0 1

# Entry for /dev/sdc5 !! UNKNOW DEVICE !! :
UUID="d0918aa7-0d83-4eb5-89e0-8049f854fccc" swap swap defaults 0 0

/dev/sr0 LABEL="Ubuntu 8.04.1 i386" 0 0

/dev/sda1 /media/WinXP ntfs-3g
defaults,locale=en_AU.UTF-8 0 0

___________________________________________________________________________________
## ## End Default Options ##

title Ubuntu 8.04.1, kernel 2.6.24-19-generic
root=(hd0,0)
kernel=(hd0,1)/vmlinuz-2.6.24-19-generic
root=UUID=3f037536-598f-40a3-9f67-afe7$
initrd=(hd0,1)/initrd.img-2.6.24-19-generic
#map (hd0) (hd2)
#map (hd0) (hd2)
#map (hd2) (hd1)
#map (hd1) (hd0)
chainload +1
quiet

title Ubuntu 8.04.1, kernel 2.6.24-19-generic (recovery mode)
root=(hd0,0)
kernel(hd0,1)/vmlinuz-2.6.24-19-generic
root=UUID=3f037536-598f-40a3-9f67-afe78$
initrd=(hd0,1)/initrd.img-2.6.24-19-generic

title Ubuntu 8.04.1, memtest86+
root=(hd0,0)
kernel=(hd0,1)/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=(hd2,0)
LABEL=Dead
savedefault
map (hd0) (hd2)
map (hd2) (hd0)
#map (hd2) (hd1)
#map (hd1) (hd0)
makeactive
chainloader +1
boot
____________________________________________________________________________________

root@dave:~# fdisk -l

Disk /dev/sda: 60.0 GB, 60022480896 bytes
255 heads, 63 sectors/track, 7297 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x4c264c25

   Device Boot Start End Blocks Id System
/dev/sda1 * 1 7297 58613121 7 HPFS/NTFS

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

   Device Boot Start End Blocks Id System
/dev/sdb1 * 1 25493 204772491 7 HPFS/NTFS
/dev/sdb2 25494 38913 107796150 b W95 FAT32

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

   Device Boot Start End Blocks Id System
/dev/sdc1 * 1 26165 210170331 83 Linux
/dev/sdc2 26166 26434 2160742+ 83 Linux
/dev/sdc3 26435 38021 93072577+ 83 Linux
/dev/sdc4 38022 38913 7164990 5 Extended
/dev/sdc5 38022 38913 7164958+ 82 Linux swap /
Solaris
root@dave:~# mount
/dev/sdc1 on / type ext3 (rw,relatime,errors=remount-ro,data=ordered)
proc on /proc type proc (rw,noexec,nosuid,nodev)
/sys on /sys type sysfs (rw,noexec,nosuid,nodev)
varrun on /var/run type tmpfs (rw,noexec,nosuid,nodev,mode=0755)
varlock on /var/lock type tmpfs (rw,noexec,nosuid,nodev,mode=1777)
udev on /dev type tmpfs (rw,mode=0755)
devshm on /dev/shm type tmpfs (rw)
devpts on /dev/pts type devpts (rw,gid=5,mode=620)
lrm on /lib/modules/2.6.24-19-generic/volatile type tmpfs (rw)
none on /dev/shm type tmpfs (rw)
/dev/sdb1 on /windows/SATA-1A type fuseblk
(rw,nosuid,nodev,noatime,allow_other,default_permissions,blksize=4096)
/dev/sdb2 on /windows/SATA-1B type vfat
(rw,relatime,iocharset=iso8859-1,shortname=mixed,utf8,umask=000,uid=1000)
/dev/sdc2 on /boot type ext3 (rw)
/dev/sdc3 on /home type reiserfs (rw,noatime)
/dev/sda1 on /media/Dead type fuseblk
(rw,nosuid,nodev,noatime,allow_other,blksize=4096)
securityfs on /sys/kernel/security type securityfs (rw)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc
(rw,noexec,nosuid,nodev)
gvfs-fuse-daemon on /home/david/.gvfs type fuse.gvfs-fuse-daemon
(rw,nosuid,nodev,user=david)
root@dave:~#
____________________________________________________________________________________
 Cheers :)

On Fri, 2008-07-18 at 02:03 +0000, Aquina wrote:
> Your question #39501 on Ubuntu changed:
> https://answers.launchpad.net/ubuntu/+question/39501
>
> Status: Open => Answered
>
> Aquina proposed the following answer:
> Were you ever able to boot the system after install to runlevel 5 and
> loading the GUI? If not you maybe have entered some wrong settings for
> the mount point. In fact the broken link with "unknown" doesn't make
> sense to me either. Unfortunaltely I don't have enough time to have a
> look at the source code.
>
> For chrooting try the "chroot /mnt/sysimage" command. I'm from Red Hat
> centric distros and switched all my organizations clients to Debian
> based ones. Maybe that rescue mode uses an equialent storage procedure.
>
> Finally I'd double check the grub boot options. If you installed the
> distro a few days ago and really performed a full sysem update using
> apt-get chances are good you still have the old kernel as an available
> grub option for booting. I'd also check for some grub mans to have a
> look at switches. Maybe it helps you with booting a minimalistic
> environment.
>
> Good Luck!
>
> PS: I'm quite sure synaptic is not responsible for that but I suggest
> you for furter instalations to perform your initial update (will be
> hundrets of packages) in run 3 (no X11!). Besides I hope you were using
> ext 3 as your file system. I had a lot of trouble in the past years with
> ext 2 and ReiserFS. Also stay away from XFS or such. The only
> alternative is JFS which I'd recommend for servers.
>

Revision history for this message
A. Denton (aquina) said :
#5

Hm...

think it's not a Linux bootloader problem. Try the following...

Hallo,

1] Boot from your WindowsXP home CD

2] Choose OPTION "R" as soon as possible on startup. Your recovery console should start now!
2a] Enter your password / Press enter ONCE
2b] Coose "Windows Installation" or something. Should be No. 1 or so.
(Whatever you do -- you need a shell!)

3] Enter the following at the command prompt.

"fixmbr c: <RETURN>"
"fixboot c: <RETURN>"
"copy d:\i386\ntldr c:\ <RETURN>"
"copy d:\i386\ntdetect.com c:\ <RETURN>"
(I assume d: is your CD-ROM drive letter)
"exit <RETURN>"

Now leave the console and restart...

Revision history for this message
dave.com (dwmac) said :
#6

I fixed it, had a * (boot flag) in the free space ntfs partition on my
empty sata drive, Windows can see it and set a boot sector record, to
get grub loading Ubuntu I had to open a partition manager and set the *
(boot flag) to my Linux /boot partition. Also needed to unplug the
separate OS drives individually to do all that. I set the WinXP mbr with
only the WinXP drive plugged in, then set the /boot partition flag in
Linux disk drive with the WinXP unplugged, and unset the free space
drive flag (the other sata disk, I have 3 drives). Thanks for your
advice :)
On Sun, 2008-07-20 at 20:54 +0000, Aquina wrote:
> Your question #39501 on Ubuntu changed:
> https://answers.launchpad.net/ubuntu/+question/39501
>
> Aquina posted a new comment:
> Hm...
>
> think it's not a Linux bootloader problem. Try the following...
>
> Hallo,
>
> 1] Boot from your WindowsXP home CD
>
> 2] Choose OPTION "R" as soon as possible on startup. Your recovery console should start now!
> 2a] Enter your password / Press enter ONCE
> 2b] Coose "Windows Installation" or something. Should be No. 1 or so.
> (Whatever you do -- you need a shell!)
>
> 3] Enter the following at the command prompt.
>
> "fixmbr c: <RETURN>"
> "fixboot c: <RETURN>"
> "copy d:\i386\ntldr c:\ <RETURN>"
> "copy d:\i386\ntdetect.com c:\ <RETURN>"
> (I assume d: is your CD-ROM drive letter)
> "exit <RETURN>"
>
> Now leave the console and restart...
>
> You received this question notification because you are a direct
> subscriber of the question.