Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: hosed hd with mbr...how do I install an mbr on good drive

  1. #1
    Member registered user
    Join Date
    Sep 2004
    Location
    Austin
    Posts
    70

    hosed hd with mbr...how do I install an mbr on good drive

    hda cratered but not a big deal, main distro is knoppix 3.6 on hdb. took hda out of the loop, changed jumpers and now computer is reading hard drive but on boot, I am getting loading grub error 22. booted to live cd (3.6) and went to lilo confige under system-admin, but when I choose "y" when it asks me if I want to save current config, the shell closes with an error. How do I go about making an mbr for this single hd now. Its probably easy, but I am a bit paniced right now and cant think of how I should do it.

    thanx

    helios

  2. #2
    Senior Member registered user
    Join Date
    Feb 2004
    Posts
    235
    If I'm reading this right, wouldn't hdb now be /dev/hda? Second, you would have to modify both /etc/fstab and /etc/lilo.conf to reflect the hard drive change. Then re-run lilo to install it to the mbr of /dev/hda.

    HTH,

    Durand

  3. #3
    Member registered user
    Join Date
    Sep 2004
    Location
    Austin
    Posts
    70

    thank you...

    yes, there is only one hd in the machine right now, the former hdb is now hda. I am completely clueless on how to edit the two things you mentioned. I am taking for granted that I must do it thru the live cd since that is the only way the computer will boot. I have looked around a bit and have not found instructions simple enough for my noobie mind. would you instruct? or point me in the right direction.

    edit - I went to hda and looked into the files you told me to edit, but lilo.conf is locked and etc/fstab is only showing hda with the swap...Im guessing anyway.

    thanx

    helios

  4. #4
    Senior Member registered user
    Join Date
    Feb 2004
    Posts
    235
    Here's what I would do:

    Boot knoppix cd to the desktop or just boot with knoppix init 3 and hit enter.
    At the prompt, type mount /dev/hda1 /mnt/hda1 -o rw.
    3) Type chroot /mnt/hda1
    4) Type mcedit /etc/fstab and change all references to /dev/hdb to /dev/hda then when done press f10 followed by yes to save it on the way out.
    5) Type mcedit /etc/lilo.conf and change any references to /dev/hdb to /dev/hda when done press f10 and yes to save it.
    6) Type lilo and press y to have it insert lilo to the mbr of the disk.
    7) Type exit
    8) Type umount /mnt/hda1
    9) Type reboot and you should boot into your hd install.

    HTH,

    Durand

  5. #5
    Member registered user
    Join Date
    Sep 2004
    Location
    Austin
    Posts
    70

    ok...hit a snag

    I followed your directions and got into mc to make the changes. seems that my hda is mounted as hda2, so I tried several times with hda or hda2...regardless of which one I did, when I ran lilo, I got the same error output. What am I doing wrong?

    root@Knoppix:/# lilo
    /dev/mapper/control: open failed: No such device
    Is device-mapper driver missing from kernel?
    /dev/mapper/control: open failed: No such device
    Is device-mapper driver missing from kernel?
    Incompatible libdevmapper 1.00.19-ioctl (2004-07-03)(compat) and kernel driver
    Warning: '/proc/partitions' does not exist, disk scan bypassed
    Warning: Unable to determine video adapter in use in the present system.
    Added Linux *
    Added Linux(2.4)-1
    Added Linux(2.6)-2
    Device 0x0300: Inconsistent partition table, 1st entry
    CHS address in PT: 0:0:0 --> LBA (-1)
    LBA address in PT: 0 --> CHS (0:0:1)
    Fatal: Either FIX-TABLE or IGNORE-TABLE must be specified
    If not sure, first try IGNORE-TABLE (-P ignore)
    root@Knoppix:/#

  6. #6
    Senior Member registered user
    Join Date
    Feb 2004
    Posts
    235
    Hmm,

    Seems like it wants you to mount /proc before running lilo. (I've never had to do that in my chroot environment)
    What is on the first partition? If knoppix is on /dev/hda2, something has to reside in /dev/hda1.
    Second, what partition is the swap in?
    Can you post the results of fdisk -l and the contents of /etc/fstab and /etc/lilo.conf? These need to be done as root from the cd.
    Something sounds fishy about the partition table according to lilo and this needs to be fixed first before we can proceed any further, otherwise you'll end up with a corrupted installation.

  7. #7
    Member registered user
    Join Date
    Sep 2004
    Location
    Austin
    Posts
    70
    Device Boot Start End Blocks Id System
    /dev/hda2 * 14 14471 116133885 83 Linux
    /dev/hda3 14472 14593 979965 82 Linux swap
    root@ttyp0[knoppix]#

    I believe hda1 might be a persistant partition that I created earlier. I cannot think of what else it might be. qt parted shows it at 1001 meg and I think that is what I set it at.

    lilo.conf

    Device Boot Start End Blocks Id System
    /dev/hda2 * 14 14471 116133885 83 Linux
    /dev/hda3 14472 14593 979965 82 Linux swap
    root@ttyp0[knoppix]#

    /etc/fstab [BM--] 4 L:[ 1+10 11/ 11] *(474 / 474b)= <EOF>
    /proc /proc proc defaults 0 0
    /sys /sys sysfs noauto 0 0
    /dev/pts /dev/pts devpts mode=0622 0 0
    /dev/fd0 /mnt/auto/floppy auto user,noauto,exec,umask=000 0 0
    /dev/cdrom /mnt/auto/cdrom auto user,noauto,exec,ro 0 0
    /dev/cdrom1 /mnt/auto/cdrom1 auto users,noauto,exec,ro 0 0
    # Added by KNOPPIX
    /dev/hda2 /mnt/hda2 ext3 noauto,users,exec 0 0
    # Added by KNOPPIX
    /dev/hda3 none swap defaults 0 0

    fstab

    /etc/fstab [BM--] 4 L:[ 1+10 11/ 11] *(474 / 474b)= <EOF>
    /proc /proc proc defaults 0 0
    /sys /sys sysfs noauto 0 0
    /dev/pts /dev/pts devpts mode=0622 0 0
    /dev/fd0 /mnt/auto/floppy auto user,noauto,exec,umask=000 0 0
    /dev/cdrom /mnt/auto/cdrom auto user,noauto,exec,ro 0 0
    /dev/cdrom1 /mnt/auto/cdrom1 auto users,noauto,exec,ro 0 0
    # Added by KNOPPIX
    /dev/hda2 /mnt/hda2 ext3 noauto,users,exec 0 0
    # Added by KNOPPIX
    /dev/hda3 none swap defaults 0 0

    lilo.conf

    # Support LBA for large hard disks.
    #
    lba32

    # Overrides the default mapping between harddisk names and the BIOS'
    # harddisk order. Use with caution.
    #disk=/dev/hda
    # bios=0x81

    #disk=/dev/sda
    # bios=0x80

    # Specifies the boot device. This is where Lilo installs its boot
    # block. It can be either a partition, or the raw device, in which
    # case it installs in the MBR, and will overwrite the current MBR.
    #
    boot=/dev/hda

    1Help 2Save 3Mark 4Replac 5Copy 6Move 7Search 8Delete 9PullDn

  8. #8
    Senior Member registered user
    Join Date
    Feb 2004
    Posts
    235
    This is clearly an odd partitioning scheme. I'm not sure if you're willing to do a full re-install, and I'm not suggesting that you do......yet.
    Fdisk clearly was not able to see the first partition, which can confuse lilo. It may be possible to install lilo to the hda2 partition where knoppix resides. But the BIOS would be looking for the mbr table in hda1 and if it's not there, you won't be able to boot your installation from the hard drive.
    Just one more question, what format is hda1-- vfat, ntfs, ext2, or ext3 and is it encrypted since you said it was a persistant partition which you used your knoppix cd or hd installation as a poor man's install?

    On the off chance you still want to keep this partitioning scheme,
    Open a console and su to root
    Mount /dev/hda2 /mnt/hda2
    Chroot /mnt/hda2
    Mcedit /etc/lilo.conf -- change boot=/dev/hda to read: boot=/dev/hda2 and save
    Mount -t proc proc /proc
    lilo -P ignore
    umount /proc
    exit
    exit

    After doing this, does lilo still report an error?

  9. #9
    Senior Member registered user
    Join Date
    Mar 2004
    Posts
    1,516
    giving the comand mount -a when chrooted should mount everything ok. btw did you edit /etc/fstab?

  10. #10
    Member registered user
    Join Date
    Sep 2004
    Location
    Austin
    Posts
    70

    good morning

    I did not choose to encrypt the persistant partition when I made it. I will try the solutions you so kindly provided. I thank you for your time and effort. Its not often people will help to this extent. I did a backup early this morning and have all vital data on cd's and am resigned to reinstall...wouldnt be the first time lol

    btw, what would be wrong in going into qparted and deleting the hda1 since hda2 is an ext3 partition and a swap partition is already established?

    thanks again

    helios

Page 1 of 2 12 LastLast

Similar Threads

  1. system hosed?
    By hardware_bum in forum General Support
    Replies: 6
    Last Post: 06-09-2004, 05:11 AM
  2. The wiki is hosed
    By mzilikazi in forum General Support
    Replies: 3
    Last Post: 05-07-2004, 04:51 AM
  3. PII 300 Good enough for HD install?
    By Eradicator in forum General Support
    Replies: 12
    Last Post: 09-09-2003, 05:21 AM
  4. Network now hosed on HDD partition
    By dsleeb in forum General Support
    Replies: 2
    Last Post: 04-04-2003, 11:27 PM
  5. Good install, no network
    By jmneely in forum Hdd Install / Debian / Apt
    Replies: 3
    Last Post: 01-30-2003, 07:45 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Kingston 32GB 64GB 128GB 256GB USB 3.0 Flash Drive Thumb Memory Stick Pen lot picture

Kingston 32GB 64GB 128GB 256GB USB 3.0 Flash Drive Thumb Memory Stick Pen lot

$285.90



Microsoft Windows 11 Pro 64bit - New Sealed – Flash USB 1 PC picture

Microsoft Windows 11 Pro 64bit - New Sealed – Flash USB 1 PC

$49.99



2021 Full Version Office Professional Plus for 1 PC Flash USB Drive picture

2021 Full Version Office Professional Plus for 1 PC Flash USB Drive

$59.99



128GB USB 14-in-1 MacOS bootable Installer repair recovery tech support service picture

128GB USB 14-in-1 MacOS bootable Installer repair recovery tech support service

$39.99



USB 3.0 Flash Drive 32GB 64GB 128GB Memory Stick Thumb Stick Lot Pack picture

USB 3.0 Flash Drive 32GB 64GB 128GB Memory Stick Thumb Stick Lot Pack

$826.09



USB Type-A Flash Drive Metal Memory Stick High Speed USB Drive 128GB 256GB 512GB picture

USB Type-A Flash Drive Metal Memory Stick High Speed USB Drive 128GB 256GB 512GB

$8.47



Lot 5/10pcs USB Flash Drive Memory Stick 1MB-64GB Pendrive Thumb Drive 8GB 32GB picture

Lot 5/10pcs USB Flash Drive Memory Stick 1MB-64GB Pendrive Thumb Drive 8GB 32GB

$246.00



Wholesale 5/10/100PCS 1MB- 64GB USB 2.0 Flash Drive Memory Stick Jump Drive Lot picture

Wholesale 5/10/100PCS 1MB- 64GB USB 2.0 Flash Drive Memory Stick Jump Drive Lot

$280.00



Windows 11 Pro Install/Recovery/Repair USB Flash Drive picture

Windows 11 Pro Install/Recovery/Repair USB Flash Drive

$35.00



SAMSUNG FIT PLUS 128GB USB 3.1 Flash Drive - fully working & authentic picture

SAMSUNG FIT PLUS 128GB USB 3.1 Flash Drive - fully working & authentic

$24.95