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

Re: Renamiing a USB external h/d



On 12/01/2012 13:38, Sharon Kimble wrote:
I have a USB external hard drive for my backups which is formatted ext
3. It is currently named as
'/media/8eef3b99-c17b-4913-ae61-d34c7fd5d459_ ' and mounted via fstab.

I've tried using e2label as follows;-
sudo e2label /media/8eef3b99-c17b-4913-ae61-d34c7fd5d459_ /media/backup
e2label: Is a directory while trying to open
/media/8eef3b99-c17b-4913-ae61-d34c7fd5d459_
Couldn't find valid filesystem superblock.

Use tune2fs to set the label of ext2 or ext3 volumes:

  tune2fs -L YOUR_LABEL device # as root

where device is something like /dev/..., you'll find it with

  grep 8eef3b99 /etc/fstab

So I tried using rename as follows;-
sudo rename /media/8eef3b99-c17b-4913-ae61-d34c7fd5d459_ /media/backup
Number found where operator expected at (eval 1) line 1, near "/media/8"
	(Missing operator before 8?)
Bareword found where operator expected at (eval 1) line 1, near "8eef3b99"
	(Missing operator before eef3b99?)
syntax error at (eval 1) line 1, near "/media/8"

This would never work.


Then, I think you have to create a permanent directory, if required:

  mkdir /media/backup # as root

and then setup the appropriate line in /etc/fstab (the udev way being
more complicated) with something like:

  LABEL=YOUR_LABEL	/media/backup	ext3	rw,user,noauto	0 0

read mount(8) for more details:

  man 8 mount

When the disk will be plugged after the system has started, you'll may
have to mount it manually, as a regular user:

  mount /media/backup

Nicolas


Reply to: