Mercoledì, 18 Marzo 2015 22:45

Samba!

Rate this item
(0 votes)

Una delle cose che non mi ricordo mai quando installo LInux è la configurazione del protocollo di condivisione file e stampanti con l'ambiente windows: Samba.

Di solito conviene creare su Samba degli utenti analoghi a quelli dei sistemi windows che devono condividere qualcosa con LInux, o utilizzare un utente guest, ma sempre con una password. In realtà per piccole reti, specie se domestiche questo non ha molto senso. Nel tempo e da vari forum ho trovato il modo di avere la condivisione su specifiche cartelle completamente libera....ma mi dimentico sempre tutto. Allora o ho dei vecchi file di configurazione a cui attingere o...niente!

Allora metto qualcosa qui sul blog.

cmq per riferimenti qui c'è un pò di cose:

https://wiki.gentoo.org/wiki/Samba/Configuration

#======================= Global Settings =======================

[global]

## Browsing/Identification ###

# Change this to the workgroup/NT-domain name your Samba server will part of
    workgroup =mia-rete

# server string is the equivalent of the NT Description field
    server string = Luca-Linux

# Windows Internet Name Serving Support Section:
# WINS Support - Tells the NMBD component of Samba to enable its WINS Server
#   wins support = no

# WINS Server - Tells the NMBD components of Samba to be a WINS Client
# Note: Samba can be either a WINS Server, or a WINS Client, but NOT both
;   wins server = w.x.y.z

# This will prevent nmbd to search for NetBIOS names through DNS.
    dns proxy = no

####### Authentication #######


    server role = standalone server

   obey pam restrictions = yes

   unix password sync = yes

    passwd program = /usr/bin/passwd %u
    passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .

   pam password change = yes

   map to guest = bad user

############ Misc ############

# Allow users who've been granted usershare privileges to create
# public shares, not just authenticated ones
    usershare allow guests = yes
    username map = /etc/samba/smbusers
    security = user
;    encrypt passwords = yes
;    guest ok = no
;    guest account = nobody

#======================= Share Definitions =======================

# Un-comment the following (and tweak the other settings below to suit)
# to enable the default home directory shares. This will share each
# user's home directory as \\server\username
;[homes]
;   comment = Home Directories
;   browseable = no

# By default, the home directories are exported read-only. Change the
# next parameter to 'no' if you want to be able to write to them.
;   read only = yes

# File creation mask is set to 0700 for security reasons. If you want to
# create files with group=rw permissions, set next parameter to 0775.
;   create mask = 0700

# Directory creation mask is set to 0700 for security reasons. If you want to
# create dirs. with group=rw permissions, set next parameter to 0775.
;   directory mask = 0700

# By default, \\server\username shares can be connected to by anyone
# with access to the samba server.
# Un-comment the following parameter to make sure that only "username"
# can connect to \\server\username
# This might need tweaking when using external authentication schemes
;   valid users = %S

# Un-comment the following and create the netlogon directory for Domain Logons
# (you need to configure Samba to act as a domain controller too.)
;[netlogon]
;   comment = Network Logon Service
;   path = /home/samba/netlogon
;   guest ok = yes
;   read only = yes

# Un-comment the following and create the profiles directory to store
# users profiles (see the "logon path" option above)
# (you need to configure Samba to act as a domain controller too.)
# The path below should be writable by all users so that their
# profile directory may be created the first time they log on
;[profiles]
;   comment = Users profiles
;   path = /home/samba/profiles
;   guest ok = no
;   browseable = no
;   create mask = 0600
;   directory mask = 0700

[printers]
   comment = All Printers
   browseable = yes
   path = /var/spool/samba
   printable = yes
   guest ok = yes
   read only = no
;    create mask = 0700

# Windows clients look for this share name as a source of downloadable
# printer drivers

[Musica]
    path = /home/luca/Musica
;    writeable = no
;    browseable = yes
    guest ok = yes

[Pubblici]
    path = /home/luca/Pubblici
    writeable = yes
;    browseable = yes
    guest ok = yes

Read 2860 times Last modified on Giovedì, 02 Marzo 2017 14:07

Leave a comment

Make sure you enter all the required information, indicated by an asterisk (*). HTML code is not allowed.

Annuncio pubblicitario by google

Questo sito utilizza cookies per amministrare autenticazioni, navigazione, statistiche di accesso e/o altre funzioni. Continuando la navigazione nel sito acconsentite che questi tipi di cookie vengano memorizzati nel vostro dispositivo.

Visualizzare la Politica sui Cookies

Visualizzare il Documento della Direttiva sulla e-Privacy

Avete Rifiutato i cookies. Questa decisione puo'essere modificata.

Avete acconsentito all'uso dei cookies. Questa decisione puo' essere modificata.