Re: partitioning mounted devs?!?

Rogier Wolff (R.E.Wolff@BitWizard.nl)
Thu, 15 Oct 1998 12:36:28 +0200 (MEST)


H. Peter Anvin wrote:
> Followup to: <Pine.A41.3.95.981014082431.17942A-100000@stud2.tuwien.ac.at>
> By author: Peter-Paul Witta <e9525748@student.tuwien.ac.at>
> In newsgroup: linux.dev.kernel
> >
> > >
> > > > hi!
> > > > why can i delete MOUNTED partitions?
> > >
> > > If you mean
> > >
> > > mount -t ext2 /dev/hda4 /usr
> > > rm /dev/hda4
> >
> > nope, i meant
> >
> > mount -t ext2 /dev/hda4 /mnt
> > fdisk
> > p
> > d
> > 4
> > w
> > q
> > (print p-table, delete partition 4, write, wuit). imo either the kernel or
> > fdisk could check if the partition is mounted...
> >
> > regards,
> > paul.
> >
>
> Because the partition is mounted, the disk is busy (in use). Because
> the disk is in use, all partition changes are delayed, and will
> usually take effect only after reboot.

But a slightly more finer-grained check would be nice.

So instead of checking for the disk to be in use, it would be nice if
the check would only flag changes to "in-use" partitions. That way you
can delete/change partition 4 if you have partition 2 mounted.

This happens to me every now and then: I have a disk where the /
partion is ready and already mounted, and that I want to set up the
rest of the disk. Back in the old days you had to think about the
whole thing in advance. Nowadays you buy twice as much disk as you
need, just because it is sooooo cheap.

Roger.

-- 
| Most people would die sooner than think....  |    R.E.Wolff@BitWizard.nl 
| in fact, most do.  -- Bertrand Russsell      |     phone: +31-15-2137555 
We write Linux device drivers for any device you may have! fax: ..-2138217

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/