I set up a pptpd on my Linux server and followed the following guide to setup a vpn server.
A Point-To-Point Tunneling Protocol (PPTP) allows you to implement your own VPN very quickly, and is compatible with most mobile devices. Even though PPTP is less secure than OpenVPN, it is faster and uses less CPU resources.
Then I connected through windows 10 from a remote machine and it connects fine. Though, I cannot see any resources or map locally any of the folders on my home folder located on the server.
Do you have any suggestions why this happens and how can I see my home folder from windows?
Have you tried typing the share in to the file browser bar (whatever it's called) Something like //server/share or //IP/share?
If I do that nothing happens, chrome just give me a 404 error. Although other services as cups and apache are visible (server address is 10.0.0.1).
No, not your web browser, the file explorer. I can't remember what it's called.
Ah sorry, If I type the path of where my shares (\ \10.0.0.1\home\myusername), windows gives me an error where it says it cannot access it.
Can you access the shares when you aren't using the VPN? Are you on the same subnet when using the VPN?
Is the share the home directory, or it is the user directory? If it's the user directory then just do
\\IP\username. Use the name of the share, not the local path to that share.
When I do not use the vpn I cannot access the server in any ways except ssh through putty (on windows) since it is located in a different town and ftp is not enabled.
I tried to map a network drive with \IP\username and still doesn't work.
what about just going to
Same error, cannot access.
Okay, it may be that you need to configure samba to listen on multiple interfaces. Open /etc/samba/smb.conf and edit the line that says
interfaces = (If it's commented out then uncomment it) and change it to
interfaces = localip vpnip where localip is your local ip address, and vpnip is the VPN server IP address, in your case 10.0.0.1. then restart the smbd service (or reboot the computer)
You may also need to add /24 to the end of each interface address you use, I'm not sure about that. You can also use the interface names, which you can find by running ifconfig in the terminal.
EDIT: It does need to be IP/24 or the interface name.
my smb.conf was already set to:
interfaces = eth0 192.168.1.0/24 10.0.0.0/24
it is both by interface and address
change it to the actual address, eth0 should cover your local interface but the vpn address should be 10.0.0.1/24 or you could use the vpn interface name instead.
is this line correct, then?
interfaces = eth0 ppp0 192.168.1.0/24 10.0.0.1/24
Looks good. You don't need the IPs if you're using the interface names and vice versa, but it should work either way
Tried that, no progression yet... I still can't map anything
Do you have a way of testing that the shares are working on the local network?
Actually I didn't do that yet. It might take me a while. I'll be back to you asap. Thanks!
I tried with a windows 7 pc inside the network and samba shares works fine. Also contacted a friend with Mac OS and he can connect fine from outside local network to his shares. Guess the issue is in my windows?
Noticed a weird thing though... when I receive the ip address from the dns (10.0.0.100) it also associates a subnet mask of 255.255.255.255. Isn't it weird?