Log inUsernamePassword
Log me on automatically each visit    
Register
Register
Log in to check your private messages
Log in to check your private messages
SMS Forum Index » SMS User Support

Post new topic   Reply to topic
Problem mounting NTFS USB drive for Samba
View previous topic :: View next topic  
Author Message
justaweso
Junior Member


Joined: 12 Jul 2010
Posts: 6

PostPosted: Sun Jul 18, 2010 2:40 am    Post subject: Problem mounting NTFS USB drive for Samba Reply with quote

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
View user's profile Send private message
gerasimos_h
Site Admin


Joined: 09 Aug 2007
Posts: 1757
Location: Greece

PostPosted: Sun Jul 18, 2010 9:58 am    Post subject: Reply with quote

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
View user's profile Send private message Visit poster's website
justaweso
Junior Member


Joined: 12 Jul 2010
Posts: 6

PostPosted: Sun Jul 18, 2010 8:35 pm    Post subject: Reply with quote

That worked great, thanks
Back to top
View user's profile Send private message
kissson
Junior Member


Joined: 24 Jul 2010
Posts: 3

PostPosted: Sat Jul 24, 2010 5:40 pm    Post subject: Reply with quote

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
View user's profile Send private message
gerasimos_h
Site Admin


Joined: 09 Aug 2007
Posts: 1757
Location: Greece

PostPosted: Sat Jul 24, 2010 6:26 pm    Post subject: Reply with quote

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
View user's profile Send private message Visit poster's website
kissson
Junior Member


Joined: 24 Jul 2010
Posts: 3

PostPosted: Sat Jul 24, 2010 7:04 pm    Post subject: Reply with quote

great , you and your app is superb
thx
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    SMS Forum Index » SMS User Support All times are GMT + 2 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum

SMS - Superb! Mini Server Project © 2016
Powered by phpBB © 2001, 2002 phpBB Group
iCGstation v1.0 Template By Ray © 2003, 2004 iOptional