The Sorrow Posted August 14, 2012 Share Posted August 14, 2012 i have a TON of files on my NAS. Can i use NFS to mount the shares on my FTP server root? eg my FTP root is /opt/vsftpd/FTPServer. can i set my nfs shares to load in /opt/vsftpd/FTPServer? Quote Link to comment Share on other sites More sharing options...
Jason Cooper Posted August 14, 2012 Share Posted August 14, 2012 (edited) Sure, just make directories for each share you want to mount in /opt/vsftpd/FTPServer and then mount them (add them to your fstab to get them mounted automatically when your machine starts) e.g. to mount an nfs share from a NAS with IP of 192.168.1.2 (If you have DNS you can use the fully qualified domain name fro the host) as share1 mkdir /opt/vsftpd/FTPServer/share1 mount -t nfs 192.168.1.2:/path/to/nfs/share /opt/vsftpd/FTPServer/share1 and to auto mount on start you would add the following line to you fstab (Feel free to read up on the flags and pick those that you think will work best in your situation) 192.168.1.2:/path/to/nfs/share /opt/vsftpd/FTPServer/share1 nfs rw,hard,intr 0 0 If they are available as smb/cifs shares and not nfs shares then you would need to change the mount types from nfs to either cifs or smbfs. You will also need to change the flags/options you use to mount it to get things like permissions correct. Edited August 20, 2012 by Jason Cooper Quote Link to comment Share on other sites More sharing options...
The Sorrow Posted August 20, 2012 Author Share Posted August 20, 2012 so to add my video share all i need to do is: 10.50.0.100 /mnt/Videos /opt/vsftpd/FTPServer/Videos nfs rw,hard,intr 0 0[/CODE]yes/no? Quote Link to comment Share on other sites More sharing options...
Jason Cooper Posted August 20, 2012 Share Posted August 20, 2012 (edited) Sorry, the first space should have been a colon. 192.168.1.2:/path/to/nfs/share /opt/vsftpd/FTPServer/share1 nfs rw,hard,intr 0 0 Edited August 20, 2012 by Jason Cooper Quote Link to comment Share on other sites More sharing options...
The Sorrow Posted August 20, 2012 Author Share Posted August 20, 2012 Sorry, the first space should have been a colon. 192.168.1.2:/path/to/nfs/share /opt/vsftpd/FTPServer/share1 nfs rw,hard,intr 0 0 I keep getting a "[mntent]: line 16 in /etc/fstab is bad" heres the line 10.50.0.100:/mnt/Videos /opt/The\ Lair\ FTP/Videos/ nfs rw,hard,intr 0 0[/CODE] Quote Link to comment Share on other sites More sharing options...
Jason Cooper Posted August 21, 2012 Share Posted August 21, 2012 Check the exported path from your nfs server is /mnt/Videos (This is going to be case-sensitive so check if it is an uppercase V or a lowercase v). Remove the / from the end of /opt/The\ Lair\ FTP/Videos/ so that it is 10.50.0.100:/mnt/Videos /opt/The\ Lair\ FTP/Videos nfs rw,hard,intr 0 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.