LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 01-31-2007, 07:03 PM   #16
kvnband
Member
 
Registered: Jan 2004
Distribution: Suse 10.2
Posts: 107

Rep: Reputation: 15

If you got to the ms boxes asking for a pw, you were RIGHT there. I accidentally posted an old smb.conf earlier in this thread - one that asks for a password. Here is part of my current one, which has password free shares.

Code:
[global]
workgroup = JUKEBOX_HERO
add machine script = /usr/sbin/useradd  -c Machine -d /var/lib/nobody -s /bin/false %m$
wins support = true
domain logons = Yes
security = share
comment = The Computer Of Kevin
server string = Kevin's Computer
dns proxy = No
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192

//[Music]
//comment = Music
//inherit acls = Yes
//path = /mnt/documents/Music
//guest ok = yes
 
Old 02-01-2007, 04:13 PM   #17
JonathanWexler
Member
 
Registered: Dec 2006
Posts: 45

Original Poster
Rep: Reputation: 15
Same problem: details follow:

I still see what look like authorization errors trying to access any resources shared by Fedora.

I have included a redacted version of smb.conf below. It reflects my fruitless attempts at adding more and more "permissive" stuff.

Also note:
1) I do have the useradd script on my system, but when I go into the "Users and Groups" UI, I do not see "nobody" listed.
2) The file system permissions for "others" of the shared directory are set to create/delete (which I assume also allows browsing)
3) Some of my previous experiments included security=user, which is when I saw the MS box prompt for a password.
4) The samba log file shows lines like:
2007/02/01 16:35:34, 0] smbd/service.c:make_connection_snum(911)
'/home/samba_user/F6_share' does not exist or permission denied when connecting to [F6share] Error was Permission denied

5) As another experiment in the Fedora desktop, I open Computer/Network/PavilionF6, and sure enought the icon for F6share is there, but when I open it, I am told that the share is not there (I am running as root), so let's check the obvious. I think that F6share is found at /Computer/Filesystem/home/samba_user/F6_share (which is what the smb.conf file reflects).

[global]
workgroup = 21prince
netbios name = PavilionF6
add machine script = /usr/sbin/useradd -c Machine -d /var/lib/nobody -s /bin/false %m$
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
server string = Samba Server
load printers = yes
cups options = raw
log file = /var/log/samba/%m.log
max log size = 50
domain logons = yes
wins support = yes
dns proxy = no
guest ok = yes
guest account = nobody

#============================ Share Definitions ==============================
[homes]
comment = Home Directories
browseable = no
writeable = yes

[F6share]
comment = Shared area in home/samba_user
inherit acls = Yes
path = /home/samba_user/F6_share
writeable = yes
security = share
guest ok = yes
browseable = yes
[printers]
comment = All Printers
path = /usr/spool/samba
browseable = no
security = share
public = yes
printable = yes
 
Old 02-01-2007, 05:01 PM   #18
JonathanWexler
Member
 
Registered: Dec 2006
Posts: 45

Original Poster
Rep: Reputation: 15
Commenting out [homes] also had no effect
 
Old 02-01-2007, 10:17 PM   #19
skishak
LQ Newbie
 
Registered: Feb 2006
Distribution: Fedora Core 6
Posts: 10

Rep: Reputation: 0
i think you and I are experiencing a similar problem.

I too have fedora core 6 and till just now i was having problems accessing shares from an MS machine.
XP would display the shares on my FC6 machine, but when i tried to access one Explorer would freeze.

I think the problem has something to do with secuirty in the /home/ directory.

I've created two identical shares (same properties in smb.conf) except for their locations.
One was located in /home/lucas/ and the other in /tmp/

I still can't access the share in /home/lucas/ but i can access the one in /tmp/

I am still new to Linux, but it seems like the problem isn't in the samba configuration. Could have something to do with /home permissions.


I hope this helps.

I'll let you know if i get the share in my /home directory working.
 
Old 02-01-2007, 11:56 PM   #20
skishak
LQ Newbie
 
Registered: Feb 2006
Distribution: Fedora Core 6
Posts: 10

Rep: Reputation: 0
spoke to soon... I think it is the smb.conf

I've got it to work under user type, and added a unix user, with a different password

I wonder now if it is actually possible to access a share located in a /home directory without actually using the unix username.
 
Old 02-02-2007, 02:28 AM   #21
jason_dustrose
Member
 
Registered: Feb 2007
Location: Arizona
Distribution: Currently toying with Debian-based MEPIS
Posts: 31

Rep: Reputation: 15
Let's Go Through This Thing...

I would like to start off by saying that Fedora is the perfect tool for learning Samba, however, there are a few things that took me forever to discover when I was where you are right now. First of all: SE Linux... turn this thing off, otherwise no matter what you do, Samba will never work correctly. Secondly, I would recommend getting used to doing everything from the console right off the bat. It might sound hard right now, but once you learn a few commands, you'll love it (it's much quicker anyway). I say that because when you do everything with a GUI, like setting file permissions for example, things are so much more intimidating when you've got tons of pull down boxes, and settings you've never seen before.

Thank you for letting me rant, anyway, the first thing I would do is scrap your smb.conf (rm -f /etc/samba/smb.conf), and your smbpasswd file (rm -f /etc/samba/smbpasswd). I imagine that something there is a little screwy. I would also try deleting and adding your users back to your machine (userdel [username] & useradd [username]) because I have found that sometimes GUI tools mix things up involving passwd,shadow,gshadow files, which would make it highly unlikely that your user accounts would work anyway.

Now after you've got your users, make sure you've got the current Samba version (3.0.23c I think it is) (yum install *samba*). I don't think you need the *, that's just a habit. You should be in good starting shape. Assuming you have all of the directories that you want made we can move on... Once again remove the smb.conf file, because now the one that's there has a bunch of garbage comments that you'll never pay attention to, and make a new one (pico smb.conf). Here's a good basic setup:

[global]

workgroup = smb
netbios name = smbwork
server string = SMB server

load printers = yes
printing options = raw

[printers]
comment = These are my Printers
path = /var/spool/samba
browsable = yes
writable = yes
printable = yes

[home]
comment = User Home
path = /home/%U
browsable = yes
writable = yes
create mask = 0700

[share]
comment = Share Directory
path = /home/share
browsable = yes
writable = yes
create mask = 0777

And there's something to get you started. Most of those options you had don't even need to be defined for a basic setup, usually all of the defaults are just fine. The %U is a variable that tells Samba to use the username, instead of defining hundreds of shares, or having the share as just /home, which can get messy. Create mask is telling Samba to set file permissions auto-magically, just to make things easier. Now add your users to Samba (smbpasswd -a [username]) and set the passwords.

Now for the moment of truth, start Samba (service samba start), and you should be in good shape. Try to connect using the IP address, not the name (which needs to be defined in the hosts file, otherwise there's no guarantee). If you don't know the address, go to your console and type "ifconfig" which should bring up a bunch of garble talk. You should see something like: "inet addr:" and next to that is your IP.

After all of this you should be just fine. If not I would recommend moving to FC5 instead of 6 because I've had problems from the get go with that thing. Please don't take anything I've written as rude or condescending, that's just how I sound, and I have no idea how much you are familiar with Linux or Samba, so I just wanted to cover all the basis.
 
Old 02-02-2007, 10:23 AM   #22
Tino27
Member
 
Registered: Aug 2003
Location: Akron, OH
Distribution: Slackware 14.2-stable, Ubuntu 16.04 LTS
Posts: 401

Rep: Reputation: 30
Quote:
Originally Posted by JonathanWexler
MS boxes seeing the printers on the Fedora box - to repeat, the Fedora box does not show up in Network Neighborhood, nor can it be found by explicitly asking for "\\pavilionF6". In the UI "System/Administration/Printers" the printers appear as local printers, with the checkbox set for "Share this printer".

Thanks
Jonathan
I set up my aunt & uncle's home network. My aunt is running on Slackware with a Canon S520 hanging off the parallel port. My uncle was running Windows and wanted the ability to print to the printer. You have several routes you can take, but I ended up configuring CUPS on my aunt's computer. There are several changes you have to make to /etc/cups/cupsd.conf and one change to /etc/cups/mime.types. To restrict printing to only the local network, I also added an entry in /etc/hosts.allow.

You still couldn't "browse" for a printer, but if you added the correct connection information when adding a new printer in Windows, it worked just fine.

I'm not going to post my cupsd.conf here as it would be wicked long. However, if you'd like copies of the files listed above so you can see what I did, just PM me.
 
Old 02-02-2007, 03:08 PM   #23
JonathanWexler
Member
 
Registered: Dec 2006
Posts: 45

Original Poster
Rep: Reputation: 15
SELinux was all of my problems with file shares (and I think I now understand everything I had been seeing). SELinux was installed and activiated by default by the Fedora 6 distribution I used. Entering "setenforce 0" at the command line made file sharing work.

Now, for sharing the darn printers. I think I see an obvious problem with the default "smb.conf" which got installed. The [Printers] section has a command "Path = /usr/spool/samba" and when I went to check the permissions on this, I discovered that it did not exist. However, "/var/spool/samba" does exist. Does anyone know if the latter is correct, what the folder permissions need to be, and if "Browseable = no" really makes sense?
 
Old 02-02-2007, 08:43 PM   #24
JonathanWexler
Member
 
Registered: Dec 2006
Posts: 45

Original Poster
Rep: Reputation: 15
I tried the /var/spool/samba and realized that - while the XP system is seeing the printer names published by Fedora, it does not
seem to be understanding it. The printers on the Fedora box were marked as "shared" (which given the "load printers = Yes" in smb.conf is probably superfluous). There are no files in /var/spool/samba - maybe print jobqueue metadata is kept elsewhere, I have no clue.

So, let me describe what the XP side looks like when I open up "pavilionF6" (the Fedora box) in Network Neighborhood
a) icons for the file shares corresponding to folders published by pavilionF6
b) icons for the two printers locally attached to pavilionF6 - in usual XP usage, this would be where you check the print queues on pavilionF6
c) A "Printers and Faxes" folder which - when opened - shows the two printers - in usual XP usage, this is where you add remote printers to the local system's list of printers.

When I try to open the icons in (b) above, XP tells me "cannot access", but nothing is showing up in the samba error log on pavilionF6, leading me to believe that XP has no idea of how to access it. I am making the perhaps erroneous assumption that samba protocols in fact allow for communicating print queue information.

When I try to open the icons in (c) above, I once again get a "cannot access" message, but an error shows up in var/log/samba/familyroom.log:

[2007/02/02 20:46:44, 0] smbd/service.c:make_connection(1102)
familyroom (192.168.0.100) couldn't find service ::{2227a280-3aea-1069-a2de-08002b30309d}

The strange hexadecimal numbers appears to be an Windows GUID (globally unique ID)

Jonathan
 
Old 02-03-2007, 09:15 AM   #25
JonathanWexler
Member
 
Registered: Dec 2006
Posts: 45

Original Poster
Rep: Reputation: 15
The light is dawning (slowly) ....

On the XP system, I tried deleting and reestablishing the reference to the shared printer on the Fedora box. I thought this had failed as I kept seeing the "Access error - cannot connect" legend every time I tried to browse the queue. It turns out that - despite that - I actually can print.

Any learning on what is required to get the print queue mechanics working - a differnt LINUX printing subsystem.

By the way, how do I tell which subsystem is already installed? In the "Printer Configuration UI", I can click the button "GoTo Server" and the Fedora system tries (and fails) to connect to a CUPS server.

Jonathan
 
  


Reply

Tags
samba, workgroup



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Samba Workgroup and Domain with File n printer Share full Configuration for Fedora 4 d.vinayaham Linux - Software 8 11-02-2006 03:13 AM
Workgroup vs Domain configuration santhosh.bachu Linux - Networking 1 07-27-2006 07:19 AM
smbclient to join workgroup and a domain JimBass Linux - Newbie 1 12-31-2005 11:19 AM
how do you join an existing windoze workgroup mnm_mc Linux - Networking 6 09-29-2004 11:10 AM
can a linux box join a windows workgroup? PlatinumRik Linux - Networking 2 06-04-2003 07:57 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 08:13 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration