On Sat, 04 Aug 2007 11:52:34 +1000
Registration Account <[EMAIL PROTECTED]> wrote:

> What I need are 2 things.
> 
> 1. How do I dismount all the drives to run fsck at Xterm?
> 
> 2. How do I use fdisk to re-write MBR from xterm?
> 
> 
> The second one might be difficult as there is plently
> of info on re-creating a LiLO MBR but not GRUB on the
> internet

The best way is to boot a rescue or disk or live CD, but...
Another way is to shutdown to single user mode. This should unmount all
but the root file system. You can always do a umount -a.

Make sure root is mounted read-only. (If I recall, in SuSE when
shutting down to single-user, it mounts read-only, but Fedora did not.
So, what I do is try to write to root, and if it fails I'm read-only. 

The command to mount root readonly is:
mount -o remount,ro  /

At this point you can run fsck. 
I generally run fsck on a single partition at a time in this mode, but
you can also run multiples. 

Probably the simplest way to fix the MBR is to go to YaST/System/Boot
Loader. Stepping through this, should cause the MBR to be rebuilt.
Another way is to use the grub(8) command. Check the grub info page:
info grub
There is a section "3.2 Installing GRUB natively"
This will also rewrite the MBR.


-- 
Jerry Feldman <[EMAIL PROTECTED]>
Boston Linux and Unix user group
http://www.blu.org PGP key id:C5061EA9
PGP Key fingerprint:053C 73EC 3AC1 5C44 3E14 9245 FB00 3ED5 C506 1EA9

Attachment: signature.asc
Description: PGP signature

Reply via email to