View Full Version : [ubuntu] samba and [homes]
October 19th, 2010, 03:00 PM
Hello. I have recently installed samba and started to configure it. Ive managed to make public folder pretty easily but i wish to have private folder for every user as well.
So i added to smb.conf
comment = katalog
writable = yes
Loging on another ubuntu and trying to acces home directory through
smb://ip/user_name i am receiving error:
error: failed to mount windows share
Please select another viewer and try again
users are added to smb.
Any clue whats wrong with it?
October 19th, 2010, 06:14 PM
what is the path of [homes]?
October 19th, 2010, 06:59 PM
What does it say from terminal:
smbclient //<ip>/<user-name> -U<user-name>%<user-passwd>
October 19th, 2010, 08:08 PM
kinda unknown ;p i havent found requirements to use one. but i had previously added to [homes] path = x/x/x and i doesnt worked also (x's were the folder names ofc)
Domain=[DOM] OS=[Unix] Server=[Samba 3.5.4]
tree connect failed: NT_STATUS_BAD_NETWORK_NAME
October 19th, 2010, 08:13 PM
Have you added the user to the Samba users list?
User Accounts define persons with some level of authorization to use certain computer and network resources. Typically, in a network environment, a user account is provided to each person allowed to access a computer or network, where policies and permissions then define what explicit rights that user account has access to. To define SAMBA network users for your Ubuntu system, you may use the smbpasswd command. For example to add a SAMBA user to your Ubuntu system with the user name jseinfeld, you would enter this command at the prompt:
smbpasswd -a jseinfeld
The smbpasswd application will then prompt you to enter a password for the user:
October 19th, 2010, 08:15 PM
luvshines, I don't know what you think but the last time I've seen that error it was because the full path to the target folder didn't have the correct permissions.
/home must have a 0755 or at least a 0711
and /home/$USER must have the same as above.
If you did a:
ls -al /homeit would tell you if your permissions are correct
October 19th, 2010, 08:24 PM
Yes they are added. Been using public folder with guest = no so user had to log in to enter directory and it worked just fine
I was thinking about permissions earlier so just in case i have set it all to 777 even and its still the same
edit: its alive! ok.. i was kinda stupid. All at all it seems like i had to make directory for each user as well, like they login name. Got used to Active Directory and though it will make it by itself upon logging or something.
However ive got another question. Everything is ok if i log in through console or by using smb://<ip>/<user_name> but.. through places -> network etc etc doesnt work. Public directory works with no problem. So if i get there throught smb://........ folder gets automatically mounted to the desktop, but why cant it work regular way throught network or something?
October 19th, 2010, 08:46 PM
Deleted (by the time my post was submitted it was already working :) [hate my sluggish internet connection] )
October 19th, 2010, 08:59 PM
Load smb config files from /etc/samba/smb.conf
rlimit_max: rlimit_max (1024) below minimum Windows limit (16384)
Processing section "[share]"
Processing section "[homes]"
Loaded services file OK.
Server role: ROLE_STANDALONE
workgroup = DOM
netbios name = SERWEREK
server string = domowy serwer plikow
comment = share
path = /home/aden/share
read only = No
create mask = 0777
directory mask = 0777
guest ok = Yes
comment = katalog
path = /home/aden/homes/%S
read only = No
some of the names like server string are not in english, not important tho.
edit: looks like it doesnt showed
security = user
which is in the [global] section of smb.conf
October 19th, 2010, 09:26 PM
However ive got another question. Everything is ok if i log in through console or by using smb://<ip>/<user_name> but.. through places -> network etc etc doesnt work. Public directory works with no problem. So if i get there throught smb://........ folder gets automatically mounted to the desktop, but why cant it work regular way throught network or something?Are you talking about the [homes] share?
I do not believe it's browseable through Places > Network like a normal share because it's created "on the fly" the moment the remote user asks for it. It uses the [homes] share definition as a template and creates a share for that user at that moment. If you want them to show up under places > network you need to actually create separate shares for each of them and use a "valid user =" option to restrict it's use to that user.
Anyway that's how I remember it working :wink:
October 19th, 2010, 09:30 PM
I see. Well thanks for help everyone. After all it works ;]
Powered by vBulletin® Version 4.2.2 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.