View previous topic :: View next topic |
Author |
Message |
justaweso Junior Member
Joined: 12 Jul 2010 Posts: 6
|
Posted: Sun Jul 18, 2010 2:40 am Post subject: Problem mounting NTFS USB drive for Samba |
|
|
I've got a 500 Gig freeagent drive formated as NTFS that I'm trying to hook up to my SMS box, but I keep running into trouble. First off my box is a NorhTec micro server (specs here http://www.norhtec.com/products/hp/details.html).
It seem that I can actually mount the drive just fine, but I can't actually do anything with it:
:/mnt$ mount -t ntfs-3g /dev/sdb1 /mnt/freeagent
ntfs-3g-mount: mount failed: Device or resource busy
:/mnt$ mount /dev/sdb1 /mnt/freeagent
:/mnt$ ls -al /mnt/freeagent
total 9237156
<<shows entire contents of my drive>>
:/mnt$ chmod 777 freeagent
chmod: changing permissions of `freeagent': Read-only file system
:/mnt$ cd freeagent
-sh: cd: freeagent: Permission denied
that was from an ssh session. from the web command console I can actually see the contents of the drive but I'm still prevented from doing much with it.
after it's registered in samba, none of my machines can get into it.
The drive can be accessed fine when attached to my windows box. |
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Sun Jul 18, 2010 9:58 am Post subject: |
|
|
Have you try
Code: | mount.ntfs-3g /dev/sdb1 /mnt/freeagent |
By typing mount you should see something like
Code: | /dev/sdd3 on /mnt/windows type fuseblk (rw,allow_other,blksize=4096) |
What "dmesg |tail " says about that when trying to mount.
Have you enable fuse module on startup (/etc/rc.d/rc.fuse)?
Do a "lsmod | grep fuse"
Also on Samba you need a line like
Code: | [USB_DISK]
path = /mnt/freeagent/
read only = no |
gerasimos_h _________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
justaweso Junior Member
Joined: 12 Jul 2010 Posts: 6
|
Posted: Sun Jul 18, 2010 8:35 pm Post subject: |
|
|
That worked great, thanks |
|
Back to top |
|
kissson Junior Member
Joined: 24 Jul 2010 Posts: 3
|
Posted: Sat Jul 24, 2010 5:40 pm Post subject: |
|
|
thx for the mount ntfs-3g method
but after I use /mnt/sda1 as 'Document root directory' in apache ,
Forbidden
You don't have permission to access / on this server.
how can I fix it ? thx |
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Sat Jul 24, 2010 6:26 pm Post subject: |
|
|
Don't use '/mnt/sda1' as document root, as it must be owned by apache user, and since you probably want to only look the contents over http, just restore document root to "/var/www/htdocs" and add in your /etc/httpd/httpd.conf
Code: | Alias /ntfsdisk /mnt/sda1/
<Directory /mnt/sda1>
Options Indexes
AllowOverride None
Allow from All
</Directory> |
And you should access your windows disk at http://[sms or yourIP]/ntfsdisk.
gerasimos_h _________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
kissson Junior Member
Joined: 24 Jul 2010 Posts: 3
|
Posted: Sat Jul 24, 2010 7:04 pm Post subject: |
|
|
great , you and your app is superb
thx |
|
Back to top |
|
|