Best way to share folder or drive over LAN and WAN

5,091

You're question is unclear what you're really asking and verging on being off-topic because it seems you are asking a question that will result in many opinion-based answers.

However, because you have mentioned some of the services many may suggest (cloud storage, Samba, SFTP, SSH etc.) then you have done some of your own research so the question isn't too bad (IMO).

A VPN would be your easiest solution because [once connected] your entire LAN can be accessible from the Internet and you can open files as if you were still inside your LAN. The downsides to a VPN are the ports required (there are some SSL based VPN solutions out there (that work over HTTPS/443 - such as SSTP or configuring OpenVPN to work over TCP 443)) and the reliability and data integrity in the event the VPN tunnel collapses.

Share:
5,091

Related videos on Youtube

Sohan Patel
Author by

Sohan Patel

Updated on September 18, 2022

Comments

  • Sohan Patel
    Sohan Patel over 1 year

    I have a dedicated home linux server and 100 Mbps internet connection at home also I use it as a central folder storage (500 GB SSD) for LAN. (I have shared a folder on the server across all computers inside the lan and as an attached drive).

    Also I want to access the shared folder as a drive/folder over the internet as well. As far as accessibility concerns, I think it is not a main issue because some blocks are blocked where I work and I can use some available ports for related services. For example some vpn, FTP, SSH ports are blocked but I can use different ports on the server to access it.

    The ideal setup would offer advantages as below,

    • Prefer faster file transfer,
    • I don't want any third-party cloud based service, want to host my files inside from my home
    • Direct file editing. I don't want to edit file and re-upload it. (Because for making notes and programming, I store notes in text files),
    • Basic security,
    • Reliable (I don't want to corrupt a file),
    • Easily available inside LAN and from WAN as well,
    • I don't want to install much unreliable third party software (could be optional)

    I have tried SFTP Why can't use SFTP? SFTP seems good but I can't edit a file directly.

    I tried WebDav. It meets some requirements, I can edit a file on the fly but I don't like it personally because I tried to upload some small files (30-40 of them between 10-1000 kb file size of individual file) and it is toooo slow. However when I edited a file in notepad and saved, it does its work very well. Since it use HTTP protocol, I guess that would be the reason why it is slower. Else it's great way to share a folder.

    I tried owncloud It's seems great but the same thing. I guess it uses PHP and WebDav. I prefer some core implementation for file sharing, not from a PHP script. However owncloud+(some other implementation would be great for accesibility as owncloud gives cross platform sharing feature across mobile, web, computers)

    I tried Samba server. I have read somewhere that it's great for sharing a folder on LAN but as far as WAN access concerns, this is not a good idea. However, I haven't tried it.

    Other thing is, I want to try creating a VPN server and I can access the server from internet (vpn clients) and so do the shared folders. But I am not sure if it is good solution. It sounds messy as I don't want the outside computer use VPN for whole computer just for accessing a folder.

    I am not sure which one is better. Is there other protocols, method I should try or you are aware of? Please give better solutions. Help would be appreciated.

    Thank you...

    • user1686
      user1686 almost 8 years
      I'd choose Samba over a VPN, personally. No protocol is going to be 'fast' if you have a high-latency WAN connection, but at least SMB is compatible with a lot of clients. (Though then you have a problem of finding a good VPN software...)
    • Sohan Patel
      Sohan Patel almost 8 years
      I guess open VPN is good. isn't it.
  • Sohan Patel
    Sohan Patel almost 8 years
    I did a lot research. But I am not aware of other solutions or implementations (for example I didn't know about Webdav before) but I want to know some other protocols, solutions. I think VPN is good solution for me but again I think there would be issue when I setup VPN client and the client computer use my internet for their bandwidth intensive tasks which I don't want to. Is there anyway I can use VPN for only file sharing?