Re: Disk maintenance
> On Sat, Jan 09, 1999 at 01:32:02PM +0000, Christian Lavoie wrote:
> > What is the best way to defrag/scan disks?
> >
> > Mounted disks can't be defragged, and you can't umount the root
> > partition, can you?
> I don't know how to defrag a disk (you rarely need to anyway), but the
> following would work, for checking as well.
> Either boot up the system in `single' or `emergency' mode
> (at the LILO prompt, "linux single" or "linux emergency"). emergency
> in particular will mount the root read-only and enter single user
mode.
> (I think single will mount all file systems read-write, and still
enter
> single user mode.)
> Or you can shutdown the running system to single user mode;
> "shutdown -h now" will get you to single user mode. Then unmount
partitions,
> and remount the root read only with
> mount -o remount,ro -n /
> To get the system back to multiuser, you can either reboot, or remount
> everything read/write and exit the single user shell. (I think the
system
> goes back to multiuser in this situation). If you forget to remount as
read
> write, it'll enter multiuser mode with the disk read/only, and you
won't
> like that.
Hmmm...
I've got a single ext2fs partition, so it is the root partition.
That's the one I need to defrag/scan, so even having it mounted as
read only won't help. (At least for the defrag)
So as far as I can tell I need either:
- A win95/dos based tool to defragment a linux partition (yeah right)
- A floppy (or CD-ROM) based dist that won't access my HD at all. (And
has the adequate tools)
- Another computer with linux installed. (Forget it)
- A way to boot without any root partition.
But then, how does UNIX administrator were dealing with such issues?
How can one scan and/or defrag a ext2fs?
Reply to: