Re: Networking Problems - smb.conf suggestions

From: David Wright (david_c_wright_at_hotmail.com)
Date: 07/15/04


Date: Thu, 15 Jul 2004 10:54:10 +0200

George Peatty wrote:

<snip>
> Here is the global section of my smb.conf:
>
> [global]
> workgroup = MyPCs
> os level = 2
> time server = Yes
> unix extensions = Yes
> encrypt passwords = Yes
> hosts allow = 192.168.0.1 192.168.0.2 192.168.0.3
> security = user
> server string = Linux here!
> log level = 1
> syslog = 0
> printing = CUPS
> printcap name = CUPS
> socket options = SO_KEEPALIVE IPTOS_LOWDELAY TCP_NODELAY
> wins support = No
> veto files = /*.eml/*.nws/riched20.dll/*.{*}/

There are a couple of things missing, for example you haven't given your
server a netbios name! So the Windows PC's won't be able to browse it...

Try the following:

[global]
#
# Example global section for smb.conf file.
# by D. Wright, 15/07/2004
#

#
# Define which interfaces and machines are allowed access:
#
   interfaces = 127.0.0.1 eth0
   bind interfaces only = true
   hosts allow = 192.168.0.1 192.168.0.2 192.168.0.3

#
# Specify the workgroup and netbios name of the server
# otherwise Windows machines won't be able to find us...
#
   workgroup = mypcs
   netbios name = susebox
   server string = Come and get it!
#
# If you have any printers connected to your Linux box you
# want to share, include this section:
#
   load printers = yes
   printing = CUPS
   printcap name = CUPS
   printer admin = root, administrator

#
# Security settings. NOTE: Won't work with Win 95 unless
# it has been updated, Win 95 didn't support encrypted
# passwords when it first came out.
#
   encrypt passwords = yes
   map to guest = Bad User
   security = user

#
# Browser master settings.
# lets Samba become the workgroup master browser-
#
   local master = yes
   preferred master = yes
   os level = 65

#
# Optional item, tell Samba to offer a time service.
#
   time server = yes

#
# Shares given out to other machines:
#
[homes]
   comment = Home Directories
   valid users = %S
   browseable = no
   read only = no
   guest ok = no
   printable = no

[data]
   browseable = yes
   comment = General data share for all Windows users
   guest ok = no
   path = /data
   printable = no
   writeable = yes

[printers]
   comment = All Printers
   printing = CUPS
   path = /var/tmp
   printable = yes
   create mask = 0600
   browseable = yes
   guest ok = no
   writeable = no
#
# End of smb.conf sample
#

This should work, it shares the home directories invisibly (they shouldn't
be browseable by other users as they are personal. The share will exist
as //susebox/user1, //susebox/user2 etc. where user1 or 2 are replaced with
real user names.

The [data] share is an example of a normal share which is browseable by
Windows (SMB) clients. To test this one, you will need to create a /data
directory using root and chmod it to 777 (chmod 777 /data). /data is
possibly not the safest place on a production network, but on a simple home
network, it should suffice for testing.

It also shares any printers you may have connected. If you don't currently
have printers attached, comment out (put a # at the beginning of the lines)
the [printers] section and in the global section also comment out the
optional printer config section.

Hope this helps you out... If this doesn't work, we will need to delve
deeper into the configuration of your network and how the Windows PC's are
setup. As the Linux box can see the Windows machines (see separate post for
auto mounting shares), then the network in general seems to be correctly
configured...

Dave



Relevant Pages

  • Re: CUPS Server Error
    ... Server Identity ... > # Classification: the classification level of the server. ... the default language if not specified by the browser. ... determines whether the scheduler will allow new printers ...
    (Debian-User)
  • Re: Cups printing problem
    ... # ServerName: the hostname of your server, ... the default language if not specified by the browser. ... determines whether the scheduler will allow new printers ... # ImplicitClasses: whether or not to use implicit classes. ...
    (freebsd-questions)
  • Re: FreeBSD 5.1, Cups problem
    ... Server Identity ... > # Classification: the classification level of the server. ... the default language if not specified by the browser. ... > # not advertised but you can still see printers on other hosts. ...
    (freebsd-questions)
  • Re: Got TCP/IP connection, but no file sharing!?
    ... No where can I find that having the Computer Browser Service ... and the server announces itself on the networking using the special ... and why doesn't a workgroup environment work the same ... server) generally acts as the master browser. ...
    (microsoft.public.windowsxp.network_web)
  • Re: Got TCP/IP connection, but no file sharing!?
    ... I guess the answer for whether the Computer Browser service should ... and why doesn't a workgroup environment work ... > server) generally acts as the master browser. ...
    (microsoft.public.windowsxp.network_web)