Solved

Questions about cabled networking
Forum rules
Before you post please read this

Solved

Postby burrina on Sat Feb 05, 2011 11:14 pm

Sorry about this but my brain is fried from trying to figure this out myself.I am running Mint 10 on 2 machines, 1 desktop and 1 netbook.They both have samba installed on them.We both have admin rights.By this time I could have copied the files onto a cd and walked into the bedroom and installed them already,geesh! My desktop sees the netbook but wants a password,it is using workgroup not samba,cant access the netbooks files.On my netbook I cant even see the desktop at all.I do have checked off via samba all users and make visible and read/write. What am I messing here? I of course have the folders shared as well.
Last edited by burrina on Thu Jun 09, 2011 3:31 pm, edited 1 time in total.
Dave
burrina
Level 2
Level 2
 
Posts: 60
Joined: Fri May 21, 2010 12:31 pm

Linux Mint is funded by ads and donations.
 

Re: File Sharing with Samba

Postby altair4 on Sun Feb 06, 2011 8:50 am

Since I can't follow your description of the problem please post the output of the following commands from the netbook:
Code: Select all
testparm -s

Code: Select all
net usershare info --long

EDIT: Sorry one more:
Code: Select all
smbtree
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
altair4
Level 13
Level 13
 
Posts: 4741
Joined: Tue Feb 03, 2009 10:27 am

Re: File Sharing with Samba

Postby GregE on Sat Feb 12, 2011 12:57 am

I am guessing you started this the wrong way by trying to manually setup shares.

Install nautilus-share and it's dependencies and delete /etc/samba/smb.conf and reinstall samba to create a clean smb.conf

Restart

Then use nautilus share to create the shares on each machine. Right click on a folder then select 'sharing options". This will automatically configure permissions and group memberships.

Your post is six days old, so let us know if it is still unfixed or if you fixed it yourself.
User avatar
GregE
Level 4
Level 4
 
Posts: 426
Joined: Sun Jan 16, 2011 6:24 am
Location: Melbourne, Australia

Re: File Sharing with Samba

Postby altair4 on Sat Feb 12, 2011 8:03 am

GregE wrote:I am guessing you started this the wrong way by trying to manually setup shares.

Install nautilus-share and it's dependencies and delete /etc/samba/smb.conf and reinstall samba to create a clean smb.conf

Restart

Then use nautilus share to create the shares on each machine. Right click on a folder then select 'sharing options". This will automatically configure permissions and group memberships.

Your post is six days old, so let us know if it is still unfixed or if you fixed it yourself.

* Manually setting up shares isn't the wrong way - it's the Classic way. Nautilus-share isn't a better way - it's another way.
* Nautilus-shares should be there by default even in LMDE.
* Deleting smb.conf and reinstalling Samba seems a bit extreme especially since there's a backup copy of smb.conf already present on the system.
* Nautilus-share will modify Linux permissions ( unless it's a NTFS or FAT32 partition ) but it does nothing with group membership.

From his original post it sounds like he's using both Nautilus-share and Classic-share at the same time which is not the best of practices but it can be done. That's why I suggested getting some facts about his setup first. The commands I suggested will tell us how his smb.conf is configured and if and how his nautilus-shares are configured.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
altair4
Level 13
Level 13
 
Posts: 4741
Joined: Tue Feb 03, 2009 10:27 am

Re: File Sharing with Samba

Postby GregE on Sat Feb 12, 2011 8:42 am

The classic way can be an issue as many Debian based instructions are way out of date. Ubuntu and thus Mint keeps it's share definitions in /var/lib/samba/usershares whereas most HowTos still get you to edit smb.conf and add the shares at the end. In LMDE nautilus share will not work at all because Debian is not configured for Ubuntu style shares.

LMDE can be configured for Ubuntu style shares, but it takes a bit of work.

This is probably not the place for this discussion but for the benefit of those trying to configure LMDE shares to work like Ubuntu based Mint.

Mini HowTo: Create Ubuntu like Samba Shares in LMDE

1
in the global section of /etc/samba/smb.conf add three lines

usershare allow guests = Yes
usershare max shares = 100
usershare owner only = False

uncomment the line ; security = user

and change it to security = share

2
sudo chgrp sambashare /var/lib/samba/usershares
sudo chmod 1770 /var/lib/samba/usershares

Ensure the group sambashare is added to your user profile, it probably already is - Just go into "Users and Groups" and check, add if necessary.

3
Install nautilus-share if it is not already installed. Restart and you should be able to right click on a folder select sharing options just like in Ubuntu, and others on your network (including media players) should be able to see and browse the shared folders.

You might have to alter permissions on shared folders, although nautilus-share should correctly configure them.

It took me a long time to work all this out so my WDTV Live could stream media from my hard drive running LMDE.
User avatar
GregE
Level 4
Level 4
 
Posts: 426
Joined: Sun Jan 16, 2011 6:24 am
Location: Melbourne, Australia

Re: File Sharing with Samba

Postby altair4 on Sat Feb 12, 2011 9:18 am

* Ubuntu, Mint, and Debian keeps share definitions in two different locations based on what method the user chooses to create the shares.
* usershare max shares = 100 is in the default ( that's what the ";" at the beginning of the line in smb.conf indicates.
* usershare owner only = False is a bad idea if you have multiple login users for obvious reasons.
*
uncomment the line ; security = user
and change it to security = share

Share level security hasn't been used since the Eisenhower administration ( that might be a slight exaggeration ). The current way to achieve the same goal is to keep it at the default user level security and add one line to the global section of smb.conf:
Code: Select all
map to guest = bad user

* Your item 2 should be the default. It is true that in Debian you need to add the user to the sambashare group.
* There are a few other things you need to do to get the full affect of Samba ( from both a server and client perspective) in LMDE. Please see the Debian subsection of the following HowTo: viewtopic.php?f=42&t=23169&p=315218#p315218
* The original poster never said he was running LMDE
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
altair4
Level 13
Level 13
 
Posts: 4741
Joined: Tue Feb 03, 2009 10:27 am

Re: File Sharing with Samba

Postby GregE on Sat Feb 12, 2011 7:17 pm

My comments about LMDE were just for you not burrina, as you mentioned that you thought nautilus-share should be the default for both versions and I wanted to point out that it will not work under LMDE without a lot more effort. With a home based multiuser machine having access to all shares by everyone is actually what you want for multimedia and home network streaming as it all needs to be passwordless and shared by everone.

Thus setting shares up the Ubuntu way not the Debian way. The method described is for those LMDE users who want to set up their shares in the same manner that Ubuntu does it. If some of the instructions need improvement then please feel free to do it, as they stand they do result in Ubuntu style shares under Debian.

Using the methods you describe in the link will still result in a share that dumb device like a WDTV Live cannot access directly. Plus every Debian Howto for passwordless shares I ever read did not work as they were all written in the days of Potato. You can set up the WDTV Live to use linux shares and you can add passwords or just do it the easy way. Internal network security at home is not an issue for most people and in the case of media streaming it just gets in the way.

Different approaches for different reasons. However I do agree that nautilus-share should be in the default install for Ubuntu based Mint as it reduces samba shares to a few clicks of the mouse.

My original comment to burrina was to try and help him solve his problem as simply as possible and he clearly wants simple shares without passwords.
User avatar
GregE
Level 4
Level 4
 
Posts: 426
Joined: Sun Jan 16, 2011 6:24 am
Location: Melbourne, Australia

Re: File Sharing with Samba

Postby altair4 on Sat Feb 12, 2011 8:36 pm

My comments about LMDE were just for you not burrina, as you mentioned that you thought nautilus-share should be the default for both versions and I wanted to point out that it will not work under LMDE without a lot more effort.

My comment was that "nautilus-share" should be there by default. That was in response to your instruction to install "nautilus-share". In both cases we were both referring to the package not the process. I'm aware that Usershare does not work by default in LMDE. I'm also aware that Classic-share doesn't work very well without modification either.
With a home based multiuser machine having access to all shares by everyone is actually what you want for multimedia and home network streaming as it all needs to be passwordless and shared by everone.

If that's a response to my post:
usershare owner only = False is a bad idea if you have multiple login users for obvious reasons.

I think you are confused about what I was referring to. That parameter will allow all local login users to share anything on that box including say .. the home directory of another user. If you only have one local user then it's not an issue but if you're going to include it in a process you need to explain the caveat.

As for having the ability to create guest accessible shares I agree and as stated in this HowTo:
Simple File Sharing in Mint: viewtopic.php?f=42&t=23169 :
For those of you that have installed Mint Debian you have probably noticed that Nautilus-share does not work. There are a few more steps required:
Linux Mint Debian Edition Preliminary Steps

Step 1: "Guest Access" is disabled.
Open smb.conf as root:
Code: Select all
gksu gedit /etc/samba/smb.conf

Add the following lines to the [global] section:
Code: Select all
usershare allow guests = yes

Code: Select all
map to guest = Bad user

And restart samba:
Code: Select all
sudo service samba restart

Using the methods you describe in the link will still result in a share that dumb device like a WDTV Live cannot access directly.

What I did post was the modern equivalent ( as share level security has been deprecated ) to creating a guest accessible share using both Usershare and Classic-share: usershare allow guests = yes, map to guest = Bad User, combined with security = user will yield an environment for a passwordless share. This is how Ubuntu and regular Mint have their smb.conf configured.

As for what the OP wants or doesn't want I haven't yet determined that. It appears he has used the Classic method and it will yield a passwordless share but I'm not entirely sure what else he had done which is why I had asked for facts before making a judgment. Just to reintereate to the OP: Please post the output of the following commands:
Code: Select all
testparm -s
net usershare info --long
smbtree
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
altair4
Level 13
Level 13
 
Posts: 4741
Joined: Tue Feb 03, 2009 10:27 am

Re: File Sharing with Samba

Postby Chainy on Tue Apr 19, 2011 12:22 pm

GregE wrote:Install nautilus-share and it's dependencies and delete /etc/samba/smb.conf and reinstall samba to create a clean smb.conf

Restart


Ok, maybe I made a mistake as I tried doing this on a Ubuntu computer. The smb.conf file was not recreated after the reinstallation of samba. Any ideas on what I should do now?! Thank you for you help.
Chainy
Level 1
Level 1
 
Posts: 9
Joined: Mon Oct 05, 2009 12:32 pm

Re: File Sharing with Samba

Postby altair4 on Tue Apr 19, 2011 1:30 pm

1) Make sure the following file exists:
/usr/share/samba/smb.conf

(2) Copy it to the original location:
Code: Select all
sudo cp -a /usr/share/samba/smb.conf /etc/samba/

(3) Correct one mistake in the new one:
encrypt passwords = false

It could also list it as No.

and change it to:
encrypt passwords = true


(4) Restart samba
Code: Select all
sudo service smbd restart

If samba was never started:
Code: Select all
sudo service smbd start
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
altair4
Level 13
Level 13
 
Posts: 4741
Joined: Tue Feb 03, 2009 10:27 am

Re: File Sharing with Samba

Postby slnner on Mon Apr 25, 2011 1:02 pm

in LMDE which i believe this is about....the service is simply samba.

Code: Select all
sudo service samba restart


or if not already started

Code: Select all
sudo service samba start


at least for me it is anyway.
slnner
Level 1
Level 1
 
Posts: 2
Joined: Mon Apr 25, 2011 12:53 pm

Re: File Sharing with Samba

Postby altair4 on Mon Apr 25, 2011 1:30 pm

slnner wrote:in LMDE which i believe this is about....the service is simply samba.

Code: Select all
sudo service samba restart


or if not already started

Code: Select all
sudo service samba start


at least for me it is anyway.

You are correct but my last post was in response to Chainy:
Ok, maybe I made a mistake as I tried doing this on a Ubuntu computer.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
altair4
Level 13
Level 13
 
Posts: 4741
Joined: Tue Feb 03, 2009 10:27 am

Linux Mint is funded by ads and donations.
 

Return to Ethernet

Who is online

Users browsing this forum: No registered users and 0 guests