Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
The whole idea is to share a folder (duh..) within a network and if that is working, then I want to extend it over the internet, with the needed security ofcourse.
I installed Samba on my Ubuntu 12.04, but I cannot find my shared folder..
Maybe nice to know, that I'm doing this on the network from my work (so not my home network, didn't had the time to check it yesterday)
[Global]
security = user
workgroup = wokrgroup
server string = Samba server %v
netbios name = ubuntu
map to guest = bad user
dns proxy = no
[share]
path = /samba/share
browsable = yes
writable = yes
guest ok = yes
read only = no
I want to get access to this file with my Windows 7 laptop (the samba server, which is also a laptop and the W7 laptop are 2 separate physical devices)
So, when I use RUN and enter \\ubuntu, it cannot find the server..
The problem seems to be not in Samba but in name resolving.
Are you sure, your Win PC knows the IP address of the PC with the hostname 'ubuntu' ?
Add the appropriate entry to your DNS server (if you use one) or at least an entry to Windows' hosts file.
The other way is just to use the IP address instead of hostname, while connecting to your Samba PC, e.g. on Windows - \\192.168.0.4
--
You may also chech your Samba config file with 'testparm' command (on Ubuntu). And also look at your own shares with 'smbclient -L localhost' command.
Um, not sure if he knows that IP address..
When I do ifconfig on my ubuntu laptop, i have 4 different ip addresses.
Which one do I need to use and in what way?
- lo (loopback, so no need for that one)
- eth0 (no cable, so no luck here)
- tunsnx (I believe the IP address for my VPN connection or something?)
- wlan0 (since it's connected over wireless, this is my best bet)
So, assume that the IP address of wlan0 -> 192.168.0.22
How can I gain access with this IP address on my WIN laptop?
I did it with run (\\192.168.0.22\) but appears to be not successfull
and in firefox (http://192.169.0.22/) but also no luck..
About interfaces:
you must know exactly in what network is your Samba PC located, and the Win PC must be in the same subnet. Compare Windows' IP addresses with the Ubuntu's IP addresses. They must be equal (not guaranteed if to be honest). Just try connecting to all of them, except loopback, whe connecting from Windows.
About Firefox:
you can not connect Samba server via HTTP protocol , like you can not drive your car like a plane.
Samba uses the very other TCP protocol than HTTP. It's very different things.
So, first of all you have to be sure that your PCs see each other. When it will be so, you can configure any services you want.
About interfaces:
you must know exactly in what network is your Samba PC located, and the Win PC must be in the same subnet. Compare Windows' IP addresses with the Ubuntu's IP addresses. They must be equal (not guaranteed if to be honest). Just try connecting to all of them, except loopback, whe connecting from Windows.
About Firefox:
you can not connect Samba server via HTTP protocol , like you can not drive your car like a plane.
Samba uses the very other TCP protocol than HTTP. It's very different things.
So, first of all you have to be sure that your PCs see each other. When it will be so, you can configure any services you want.
Good point about the devices should be in the same network.
Subnetmask is 255.255.240.0, so the range goes from 192.168.0.1 to 192.168.15.254, and then 192.168.16.1 to 192.168.30.254, and so on ... (broadcast address and network address left out)
If I'm not mistaking? (it has been a while )
If so, then they are in the same subnet..
Would it make sense that I copy the /etc/samba/smb.conf file here? So you can take a look how everything is configured?
Did you restart Samba(its easier to just restart both computers)?
Also, make sure that the workgroups are the same and that a firewall is not blocking your samba server. If you have an autoconfigured firewall it will usually block it unless you specify it not to.
If its on the same workgroup and not blocked by a firewall, after a restart, windows should detect it.
Like I said in my first post, at this moment I'm on the network of my company.. So I assume the FW of this network is blocking it.
Just wanted to make sure if that was the case.
Can I verify this, by perhaps pinging to a IP address or whatever?
If your windows and ubuntu machine are on the same network then you should be able to access the shares
So basically you are not on VPN and you have not connected LAN cable and you are on Wireless which is on same network as on Windows 7. If all these are correct then give a check to firewall and selinux on ubuntu.
Once you restart your smb and nmb services check the log file for any clue. Disable your firewall or create new rules for firewall
I am not so good with selinux rules so you can hit a google search for how to allow samba to pass through selinux or you can disable it and do a restart to make the changes affect
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.