Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Can Freenas use storage on another server

Posted on 2014-03-12
11
Medium Priority
?
1,411 Views
Last Modified: 2014-05-07
I have a Freenas box running on the same network as a Ubuntu Linux box. The Freenas box provides an FTP service and files are stored locally. I have a requirement for one user to use the same FTP service but store their files on the Ubuntu Linux box (it's a web server so I want them to be able to amend their web site).
Can the Freenas box address storage on the Ubuntu box?
0
Comment
Question by:ClintonK
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 3
  • 3
11 Comments
 
LVL 21

Expert Comment

by:Mazdajai
ID: 39924281
Are you asking if you can mount Ubuntu server in Freenas so FTP are send to ubuntu instead?
0
 

Author Comment

by:ClintonK
ID: 39924288
yes, exactly but only for one user.
0
 
LVL 21

Expert Comment

by:Mazdajai
ID: 39924301
Sure. I see no reason why it won't work.

You can setup NFS in Ubuntu and export the path then mount Ubuntu in freenas. If it works, add it to fstab so it will remount on boot.
0
Stressed Out?

Watch some penguins on the livecam!

 

Author Comment

by:ClintonK
ID: 39924901
I've created a NFS share on Ubuntu and successfully mounted in through the shell on freenas. The next step was to make the new mapped share the home directory of the ftp user but when I give the share to the user I get the error "The path must reside within a volume mount point"
Not sure what that means.
0
 
LVL 21

Expert Comment

by:Mazdajai
ID: 39925257
Do you get the error from the GUI? What error of freeNas are you using?

Can you provide the exact commands or steps you have done?
0
 
LVL 27

Assisted Solution

by:skullnobrains
skullnobrains earned 2000 total points
ID: 39932522
freenas apparently does not allow you to create a share on something that is not listed in it's volumes

you need to create a volume from the GUI, and mount your nfs share in a directory inside that mount point or possibly create a nullfs mount to map a directory to the nfs share. i think it will also work on the root of the volume you create from the gui

obviously, you can rely on an existing volume. it is likely much simpler to simply mount the nfs volume inside an existing volume
0
 

Author Comment

by:ClintonK
ID: 39936413
Yes, Freenas doesn't see anything that it didn't create through the GUI. What I've done is to look at it from another angle and create a NFS share on the Freenas box and then mount that from the Web server and put the web site on the share. I think this is a better solution anyway because now the website resides on a RAID5 array.
0
 
LVL 27

Assisted Solution

by:skullnobrains
skullnobrains earned 2000 total points
ID: 39936670
create a NFS share on the Freenas box and then mount that from the Web server and put the web site on the share. I think this is a better solution anyway because now the website resides on a RAID5 array.

if you did that, you are using freenas as the file store and not the web server so the raid5 array does not come to play

as a general rule serving a web site over NFS is not a very good idea

no idea what you are comparing raid5 with since i have no idea about your freenas setup, but it is unlikely that the raid5 is faster or even more secure in terms of data integrity

---

did you give a try to the solution i suggested above ? create a share on the freenas and then mount your nfs on or inside the corresponding location  on the freenas ?
0
 

Author Comment

by:ClintonK
ID: 39936681
The NFS share is created on the RAID 5 array and mounted by the web server so the data does reside on the RAID 5.
I did wonder about the integrity of the solution and whether it was a good idea to do what I've done - it does work but maybe it's not the best way.
I will try your suggestion (skullnobrains) this evening and report back. Cheers.
0
 
LVL 27

Accepted Solution

by:
skullnobrains earned 2000 total points
ID: 39936849
The NFS share is created on the RAID 5 array and mounted by the web server so the data does reside on the RAID 5.
oups i misread. the raid5 is the nas and not the server, my bad

btw, if you're using zfs with freenas, you're using raidz and not raid5... hopefully

I did wonder about the integrity of the solution and whether it was a good idea to do what I've done - it does work but maybe it's not the best way.
try and emulate packet loss or worse by blocking the nfs flow in either host's firewall or killing tcp sessions if your nfs is over tcp. last time i checked this at least required tweaking in order to prevent accumulation of stale file handles, unkillable httpd threads (at least with apache) and similar problems. it is also likely to be much slower even considering os-level and server-level caches... but them some folks do run production servers like this and they're not all crazy
0
 

Author Closing Comment

by:ClintonK
ID: 40048390
I've been running the nginx web server with a NFS mounted file system hosted on the FreeNas server and all seems good. It's only a very low volume site so performance is not really an issue so I'm happy with this solution.
Thanks all for the input.
0

Featured Post

Visualize your virtual and backup environments

Create well-organized and polished visualizations of your virtual and backup environments when planning VMware vSphere, Microsoft Hyper-V or Veeam deployments. It helps you to gain better visibility and valuable business insights.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The question appears often enough, how do I transfer my data from my old server to the new server while preserving file shares, share permissions, and NTFS permisions.  Here are my tips for handling such a transfer.
Windows Server 2003 introduced persistent Volume Shadow Copies and made 2003 a must-do upgrade.  Since then, it's been a must-implement feature for all servers doing any kind of file sharing.
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
Suggested Courses

722 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question