/media/disk contains an invalid character. you must choose a name, not a directory

Asked by reswob on 2007-06-09

ntfs-3 wrote my fstab file as

/dev/sda3 /media/local ntfs-3g defaults, locale=en_US.UTF-8 0 0
/dev/sdb3 /media/disk ntfs-3g defaults, locale=en_US.UTF-8 0 0

but when I do an fdisk -l, it shows my drives as /dev/hda3 and /dev/hdb3

When I click on the NTFS configuration tool, it tells me that there are two drives detected /dev/hda3 and /dev/hdb3. The Mount point for /dev/hdb3 is blank and says <click here to set mount point>. When I enter /media/disk it tell me

/media/disk contains an invalid character. you must choose a name, not a directory

I hit OK, but it won't let me enter anything (even other directory names in /media) in the box. I then check the box for the other detected drive /dev/hda3 which has the mount point already entered as /media/Local Disk. No matter if I leave that entry as is or enter something else, it tells me

An error occured when trying to configure /media/Local Disk, please retry.

I hit OK. Then the window pops up where you enable write support for internal and external devices pops up. I hit OK. But none of my drives show up.

Everything worked nicely before the last kernel update (2.6.20.15 to 2.6.20.16), now it no workie. I removed ntfs-3g, rebooted and re-installed ntfs-3g, but it still has the same problem. I tried manually editing fstab, but ntfs-3g wouldn't let me overwrite the file even after doing a sudo su. Also, the applicable directories being mapped are in /media.

Could I have the wrong permissions on the directories in /media? I didn't change the permissions from the defaults they had when I created them.

When I ran "ntfs-config --debug --query-database=all" as root I got the following:

** (ntfs-config:3097): WARNING **: /media/disk contains an invalid caracter.
you must choose a name, not a directory.

** (ntfs-config:3097): WARNING **: Failed to create /media/Local Disk.

** (ntfs-config:3097): WARNING **: Error : An error occured when trying to configure
 /media/Local Disk, please retry. Thanks.

Below is my fstab file which was autogenerated by ntfs-config

proc /proc proc defaults 0 0
# Entry for /dev/hdb1 :
UUID=10bf2884-3cfd-4d08-ab8c-03d5ceb848d3 / ext3 defaults,errors=remount-ro 0 1
# Entry for /dev/hdb5 :
UUID=8ab7c89c-c460-474a-89ce-53e9f70fe3b2 none swap sw 0 0
/dev/hdc /media/cdrom0 udf,iso9660 user,noauto 0 0
/dev/cdrom /media/cdrom1 udf,iso9660 user,noauto 0 0
/dev/ /media/floppy0 auto rw,user,noauto 0 0
/dev/sda3 /media/local ntfs-3g defaults,locale=en_US.UTF-8 0 0
/dev/sdb3 /media/disk ntfs-3g defaults,locale=en_US.UTF-8 0 0
//10.10.0.190/Music /media/Music smbfs credentials=/home/craig/.smbpassword,uid=craig,gid=users 0 0
//10.10.0.190/Documents /media/Documents smbfs credentials=/home/craig/.smbpassword 0 0
//10.10.0.190/Photographs /media/Photos smbfs credentials=/home/craig/.smbpassword 0 0
//10.10.0.190/Storage /media/Storage smbfs credentials=/home/craig/.smbpassword,uid=craig,gid=users 0 0

Is there more information I need to provide? Any help would be appreciated...

Thanks.

Question information

Language:
English Edit question
Status:
Solved
For:
Disk Manager Edit question
Assignee:
No assignee Edit question
Solved by:
reswob
Solved:
2007-06-11
Last query:
2007-06-11
Last reply:
reswob (reswob10) said : #1

Just a note to be clear:

I'm trying to map my two NTFS partitions so I can access them and read/write to them.

Right now, I can't do either.

Here is the result of an fdisk /dev/hdb -l

Disk /dev/hdb: 40.0 GB, 40020664320 bytes
255 heads, 63 sectors/track, 4865 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot Start End Blocks Id System
/dev/hdb1 * 1 3377 27125721 83 Linux
/dev/hdb2 4665 4865 1614532+ 5 Extended
/dev/hdb3 3378 4664 10337827+ 7 HPFS/NTFS
/dev/hdb5 4665 4865 1614501 82 Linux swap / Solaris

and here is the result of an fdisk /dev/hda -l

Disk /dev/hda: 20.0 GB, 20000000000 bytes
255 heads, 63 sectors/track, 2431 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot Start End Blocks Id System
/dev/hda2 1 4 32098+ de Dell Utility
/dev/hda3 * 5 2431 19494877+ 7 HPFS/NTFS

Hope this helps some...

Best reswob (reswob10) said : #2

OK, this is weird, and I can't provide any information. Yesterday, Sunday the 10 of June, I applied the patches in the Ubuntu notification, and lo and behold, when I rebooted, I again had my NTFS drives mounted with read/write access.

If you want, I can try and figure out what patches were applied... Or you can just declare this closed...

apecar (dbaston) said : #3

This is an extremely confusing error message. The user is prompted for a mount point, but the program will not accept a directory. Doesn't a mount point have to be a directory?

Richard Corner (rcorner) said : #4

I figured out what you have to do:

When you start ntfs-config it'll show a suggested mount point like /media/Data for your NTFS partition. If you try to change this, for example, to /media/windowsdata or /mnt/windowsdata, it'll show the error message about "invalid character" and wanting a name rather than a directory.

What you have to do is enter just the name of the mount point, without any path information - e.g. just "windowsdata" instead of "/media/windowsdata". It will fill in the "/media/" part automatically, and then it is happy. When you do this your mount point will be listed as "/media/windowsdata".

This seems like a bug in ntfs-config - or at least a serious usability issue. I have three gripes about it:

1. Because it won't accept a full path, it doesn't seem to allow you to mount NTFS partitions anywhere other than in subdirectories of /media. It should allow you to pick whichever path you want.

2. It displays the current mount point as a full path, yet when you try to edit the path it complains you shouldn't use a path. Why display the mount point in a text input field in a format which is treated as invalid by the program itself?

3. If you're going to make it that awkward to use, a little help text wouldn't go amiss.