Connect to Samba Share across OpenVPN tunnel [closed]

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
2
down vote

favorite
1












I've recently setup OpenVPN for remote connection to our CentOS 6 file server.



Server Static IP: 10.0.0.66
Remote OpenVPN IP: 10.8.0.1


However when using the OpenVPN connection I am unable to access the Samba share which would normally be accessed using 10.0.0.66 from inside the local network.



I have made the following adjustments to the smb.conf file according to the OpenVPN Website



[global]
unix charset = UTF-8
dos charset = CP932
workgroup = WORKGROUP
server string = Samba Server Version %v
# include 10.8.0.0/24 for OpenVPN
hosts allow = 10.0.0.0/100 10.8.0.0/24 127.0.0.1
interfaces = 10.0.0.0/100 10.8.0.0/24
log file = /var/log/samba/log.%m
max log size = 50
security = share
passdb backend = tdbsam

[Share]
path = /samba/share01
writable = yes
browsable = yes
guest ok = yes
guest only = yes
create mode = 0777
directory mode = 0777


Then I try to access the Samba share using 10.8.0.1 although it doesn't seem to have worked, Is there something I am missing?



UPDATE



The issue has been resolved



I made some slight changes to the smb.conf file, the one above is the latest.
The other issue was how the share was being accessed.



When mapping the network location I had to specify the share I wanted to connect to



\10.8.0.1Share


Then it brought it up just fine.



Thanks to everyone for their help










share|improve this question















closed as off-topic by sebasth, G-Man, Jeff Schaller, slm♦ Aug 14 at 1:50


This question appears to be off-topic. The users who voted to close gave this specific reason:


  • "Questions describing a problem that can't be reproduced and seemingly went away on its own (or went away when a typo was fixed) are off-topic as they are unlikely to help future readers." – sebasth, G-Man, Jeff Schaller, slm
If this question can be reworded to fit the rules in the help center, please edit the question.












  • What are the routes and local IP address on the [remote] client side?
    – user86969
    Jun 1 '15 at 8:21










  • Are you sure Server IP is 10.8.0.1? Looks like that address might be the GW address and to access the samba share you should not change any IP in you smb.conf, just make sure routes are OK after establishing the VPN connection.
    – YoMismo
    Jun 1 '15 at 8:21










  • Before the Samba share was required the server had always been accessed through ssh to 10.8.0.1 and that ssh connection still works
    – Trent
    Jun 1 '15 at 8:30










  • The client network is on the IP range 192.168.20.0/100 the client making the successful ssh connection is using the IP 192.168.20.13
    – Trent
    Jun 1 '15 at 8:31














up vote
2
down vote

favorite
1












I've recently setup OpenVPN for remote connection to our CentOS 6 file server.



Server Static IP: 10.0.0.66
Remote OpenVPN IP: 10.8.0.1


However when using the OpenVPN connection I am unable to access the Samba share which would normally be accessed using 10.0.0.66 from inside the local network.



I have made the following adjustments to the smb.conf file according to the OpenVPN Website



[global]
unix charset = UTF-8
dos charset = CP932
workgroup = WORKGROUP
server string = Samba Server Version %v
# include 10.8.0.0/24 for OpenVPN
hosts allow = 10.0.0.0/100 10.8.0.0/24 127.0.0.1
interfaces = 10.0.0.0/100 10.8.0.0/24
log file = /var/log/samba/log.%m
max log size = 50
security = share
passdb backend = tdbsam

[Share]
path = /samba/share01
writable = yes
browsable = yes
guest ok = yes
guest only = yes
create mode = 0777
directory mode = 0777


Then I try to access the Samba share using 10.8.0.1 although it doesn't seem to have worked, Is there something I am missing?



UPDATE



The issue has been resolved



I made some slight changes to the smb.conf file, the one above is the latest.
The other issue was how the share was being accessed.



When mapping the network location I had to specify the share I wanted to connect to



\10.8.0.1Share


Then it brought it up just fine.



Thanks to everyone for their help










share|improve this question















closed as off-topic by sebasth, G-Man, Jeff Schaller, slm♦ Aug 14 at 1:50


This question appears to be off-topic. The users who voted to close gave this specific reason:


  • "Questions describing a problem that can't be reproduced and seemingly went away on its own (or went away when a typo was fixed) are off-topic as they are unlikely to help future readers." – sebasth, G-Man, Jeff Schaller, slm
If this question can be reworded to fit the rules in the help center, please edit the question.












  • What are the routes and local IP address on the [remote] client side?
    – user86969
    Jun 1 '15 at 8:21










  • Are you sure Server IP is 10.8.0.1? Looks like that address might be the GW address and to access the samba share you should not change any IP in you smb.conf, just make sure routes are OK after establishing the VPN connection.
    – YoMismo
    Jun 1 '15 at 8:21










  • Before the Samba share was required the server had always been accessed through ssh to 10.8.0.1 and that ssh connection still works
    – Trent
    Jun 1 '15 at 8:30










  • The client network is on the IP range 192.168.20.0/100 the client making the successful ssh connection is using the IP 192.168.20.13
    – Trent
    Jun 1 '15 at 8:31












up vote
2
down vote

favorite
1









up vote
2
down vote

favorite
1






1





I've recently setup OpenVPN for remote connection to our CentOS 6 file server.



Server Static IP: 10.0.0.66
Remote OpenVPN IP: 10.8.0.1


However when using the OpenVPN connection I am unable to access the Samba share which would normally be accessed using 10.0.0.66 from inside the local network.



I have made the following adjustments to the smb.conf file according to the OpenVPN Website



[global]
unix charset = UTF-8
dos charset = CP932
workgroup = WORKGROUP
server string = Samba Server Version %v
# include 10.8.0.0/24 for OpenVPN
hosts allow = 10.0.0.0/100 10.8.0.0/24 127.0.0.1
interfaces = 10.0.0.0/100 10.8.0.0/24
log file = /var/log/samba/log.%m
max log size = 50
security = share
passdb backend = tdbsam

[Share]
path = /samba/share01
writable = yes
browsable = yes
guest ok = yes
guest only = yes
create mode = 0777
directory mode = 0777


Then I try to access the Samba share using 10.8.0.1 although it doesn't seem to have worked, Is there something I am missing?



UPDATE



The issue has been resolved



I made some slight changes to the smb.conf file, the one above is the latest.
The other issue was how the share was being accessed.



When mapping the network location I had to specify the share I wanted to connect to



\10.8.0.1Share


Then it brought it up just fine.



Thanks to everyone for their help










share|improve this question















I've recently setup OpenVPN for remote connection to our CentOS 6 file server.



Server Static IP: 10.0.0.66
Remote OpenVPN IP: 10.8.0.1


However when using the OpenVPN connection I am unable to access the Samba share which would normally be accessed using 10.0.0.66 from inside the local network.



I have made the following adjustments to the smb.conf file according to the OpenVPN Website



[global]
unix charset = UTF-8
dos charset = CP932
workgroup = WORKGROUP
server string = Samba Server Version %v
# include 10.8.0.0/24 for OpenVPN
hosts allow = 10.0.0.0/100 10.8.0.0/24 127.0.0.1
interfaces = 10.0.0.0/100 10.8.0.0/24
log file = /var/log/samba/log.%m
max log size = 50
security = share
passdb backend = tdbsam

[Share]
path = /samba/share01
writable = yes
browsable = yes
guest ok = yes
guest only = yes
create mode = 0777
directory mode = 0777


Then I try to access the Samba share using 10.8.0.1 although it doesn't seem to have worked, Is there something I am missing?



UPDATE



The issue has been resolved



I made some slight changes to the smb.conf file, the one above is the latest.
The other issue was how the share was being accessed.



When mapping the network location I had to specify the share I wanted to connect to



\10.8.0.1Share


Then it brought it up just fine.



Thanks to everyone for their help







centos samba remote openvpn






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Jun 1 '15 at 11:03

























asked Jun 1 '15 at 7:46









Trent

1,21671427




1,21671427




closed as off-topic by sebasth, G-Man, Jeff Schaller, slm♦ Aug 14 at 1:50


This question appears to be off-topic. The users who voted to close gave this specific reason:


  • "Questions describing a problem that can't be reproduced and seemingly went away on its own (or went away when a typo was fixed) are off-topic as they are unlikely to help future readers." – sebasth, G-Man, Jeff Schaller, slm
If this question can be reworded to fit the rules in the help center, please edit the question.




closed as off-topic by sebasth, G-Man, Jeff Schaller, slm♦ Aug 14 at 1:50


This question appears to be off-topic. The users who voted to close gave this specific reason:


  • "Questions describing a problem that can't be reproduced and seemingly went away on its own (or went away when a typo was fixed) are off-topic as they are unlikely to help future readers." – sebasth, G-Man, Jeff Schaller, slm
If this question can be reworded to fit the rules in the help center, please edit the question.











  • What are the routes and local IP address on the [remote] client side?
    – user86969
    Jun 1 '15 at 8:21










  • Are you sure Server IP is 10.8.0.1? Looks like that address might be the GW address and to access the samba share you should not change any IP in you smb.conf, just make sure routes are OK after establishing the VPN connection.
    – YoMismo
    Jun 1 '15 at 8:21










  • Before the Samba share was required the server had always been accessed through ssh to 10.8.0.1 and that ssh connection still works
    – Trent
    Jun 1 '15 at 8:30










  • The client network is on the IP range 192.168.20.0/100 the client making the successful ssh connection is using the IP 192.168.20.13
    – Trent
    Jun 1 '15 at 8:31
















  • What are the routes and local IP address on the [remote] client side?
    – user86969
    Jun 1 '15 at 8:21










  • Are you sure Server IP is 10.8.0.1? Looks like that address might be the GW address and to access the samba share you should not change any IP in you smb.conf, just make sure routes are OK after establishing the VPN connection.
    – YoMismo
    Jun 1 '15 at 8:21










  • Before the Samba share was required the server had always been accessed through ssh to 10.8.0.1 and that ssh connection still works
    – Trent
    Jun 1 '15 at 8:30










  • The client network is on the IP range 192.168.20.0/100 the client making the successful ssh connection is using the IP 192.168.20.13
    – Trent
    Jun 1 '15 at 8:31















What are the routes and local IP address on the [remote] client side?
– user86969
Jun 1 '15 at 8:21




What are the routes and local IP address on the [remote] client side?
– user86969
Jun 1 '15 at 8:21












Are you sure Server IP is 10.8.0.1? Looks like that address might be the GW address and to access the samba share you should not change any IP in you smb.conf, just make sure routes are OK after establishing the VPN connection.
– YoMismo
Jun 1 '15 at 8:21




Are you sure Server IP is 10.8.0.1? Looks like that address might be the GW address and to access the samba share you should not change any IP in you smb.conf, just make sure routes are OK after establishing the VPN connection.
– YoMismo
Jun 1 '15 at 8:21












Before the Samba share was required the server had always been accessed through ssh to 10.8.0.1 and that ssh connection still works
– Trent
Jun 1 '15 at 8:30




Before the Samba share was required the server had always been accessed through ssh to 10.8.0.1 and that ssh connection still works
– Trent
Jun 1 '15 at 8:30












The client network is on the IP range 192.168.20.0/100 the client making the successful ssh connection is using the IP 192.168.20.13
– Trent
Jun 1 '15 at 8:31




The client network is on the IP range 192.168.20.0/100 the client making the successful ssh connection is using the IP 192.168.20.13
– Trent
Jun 1 '15 at 8:31










1 Answer
1






active

oldest

votes

















up vote
0
down vote













This [most probably] is a routing issue.



Your Samba server, as far as the remote part is concerned, is accessed from 192.168.20.0/100 so here are two possibilities:



  • either route 192.168.20.0/100 traffic through the OpenVPN interface on the server — it does require a change in smb.conf to allow access from 192.168.20.0/100 though;

  • or you can just NAT (actually masquerade) traffic coming from the 192.168.20.0/100 network on your OpenVPN server interface using iptables.

The latter option should require no change in smb.conf.






share|improve this answer



























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    0
    down vote













    This [most probably] is a routing issue.



    Your Samba server, as far as the remote part is concerned, is accessed from 192.168.20.0/100 so here are two possibilities:



    • either route 192.168.20.0/100 traffic through the OpenVPN interface on the server — it does require a change in smb.conf to allow access from 192.168.20.0/100 though;

    • or you can just NAT (actually masquerade) traffic coming from the 192.168.20.0/100 network on your OpenVPN server interface using iptables.

    The latter option should require no change in smb.conf.






    share|improve this answer
























      up vote
      0
      down vote













      This [most probably] is a routing issue.



      Your Samba server, as far as the remote part is concerned, is accessed from 192.168.20.0/100 so here are two possibilities:



      • either route 192.168.20.0/100 traffic through the OpenVPN interface on the server — it does require a change in smb.conf to allow access from 192.168.20.0/100 though;

      • or you can just NAT (actually masquerade) traffic coming from the 192.168.20.0/100 network on your OpenVPN server interface using iptables.

      The latter option should require no change in smb.conf.






      share|improve this answer






















        up vote
        0
        down vote










        up vote
        0
        down vote









        This [most probably] is a routing issue.



        Your Samba server, as far as the remote part is concerned, is accessed from 192.168.20.0/100 so here are two possibilities:



        • either route 192.168.20.0/100 traffic through the OpenVPN interface on the server — it does require a change in smb.conf to allow access from 192.168.20.0/100 though;

        • or you can just NAT (actually masquerade) traffic coming from the 192.168.20.0/100 network on your OpenVPN server interface using iptables.

        The latter option should require no change in smb.conf.






        share|improve this answer












        This [most probably] is a routing issue.



        Your Samba server, as far as the remote part is concerned, is accessed from 192.168.20.0/100 so here are two possibilities:



        • either route 192.168.20.0/100 traffic through the OpenVPN interface on the server — it does require a change in smb.conf to allow access from 192.168.20.0/100 though;

        • or you can just NAT (actually masquerade) traffic coming from the 192.168.20.0/100 network on your OpenVPN server interface using iptables.

        The latter option should require no change in smb.conf.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Jun 1 '15 at 9:37







        user86969



















            Popular posts from this blog

            How to check contact read email or not when send email to Individual?

            Bahrain

            Postfix configuration issue with fips on centos 7; mailgun relay