[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Relabel partition didn't work



On Thu, Apr 05, 2007 at 02:41:03PM -0500, Manon Metten wrote:
> On 4/5/07, Douglas Allan Tutty <dtutty@porchlight.ca> wrote:
> On Thu, Apr 05, 2007 at 07:06:51AM -0500, Manon Metten wrote:
> >> Linux debian 2.6.18-4-486 #1 Mon Mar 26 16:39:10 UTC 2007 i686 GNU/Linux
> >>
> >> I want to change the name and access point of a partition on my second
> >hd.
> >> It's labeled /xyz now (coz I could think of no better name when
> >installing
> >> etch).

> >You're confusing disk lables with mount points.  Your fstab doesn't have
> >disklables in it.  You told mount to mount /dev/hdb4 on /store, so it
> >looks for the directory /store, which doesn't exist.
> >
> >So backup:
> >
> >What are you trying to do?
> >
> 
> After fiddling around with sarge for some months, I installed etch a couple
> of weeks ago.
> I've done lots of reading and I'm following this list for a while, but I'm
> new to debian anyway.
> 
> I have 4 partitions on my 2nd hd, swap, /tmp, /var & /xyz.
> /xyz is the 4th primary partition on my 2nd hd.

> When installing etch, at some point partman asked for a mount point for that
> partition and I entered /xyz.
> 
> I use this xyz partition only to store some .iso's and other large files, so
> I want rename/relabel it to /store. If I do mkdir /store, that would create
> the dir/mount point on my 1st hd where / is located (correct?). Thus the
> question is: how to change /xyz to /store on my 2nd hd, so I can do eg.
> something like this:
> 
>  mv  ~/*.iso  /store
> 
> so it moves *.iso from ~ on my 1st hd to /store on my 2nd hd.
> 

OK.

a partition lable and a mount point are two totally unrelated things,
almost.  Almost because there is a way (I don't do it, so I'll be vague)
to use disk lables in fstab to refer to partitions instead of using
device names (e.g. /dev/hda1).  This is useful on USB and SATA drives
that all show up as /dev/sd*, but the actual name for any given drive
can change depending on what other drives are connected (e.g. USB
sticks) during boot.  

If this doesn't apply to you, then you can forget lables.  Also, not all
filesystems allow you to relabel.  

Your existing fstab (the one that mounts the drive on /xyz) points to a
mount point /xyz.  

	# unmount /xyz
	
Just change the mount point in fstab to read /store.  

Rename the mount point

	# mv /xyz /store

And mount it.

	# mount /store

Doug.



Reply to: