daviid
Anmeldungsdatum: 14. April 2009
Beiträge: 14
|
Hallo, ich habe jetzt seit neustem einen HP Microserver N40L, nettes Teil.
Dadrauf läuft Debian 6.0, nicht das was ich oben angegeben hab, denn da musst man irgendwas angeben ... Jetzt will ich dadrauf Samba Freigaben einrichten, einmal eine öffentliche wo Musik und ähnliches für alle Nutzer zur Verfügung steht, und für jeden Benutzer sein Home-Verzeichnis. Nur wird das einfach nichts, und zwar möchte ich das ich generell auf die public Freigabe komme ohne mich anmelden zu müssen, in die Home Verzeichnisse will ich aber natürlich nur mit anmelden. Hier mal meine Config: 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128 | #======================= Global Settings =======================
[global]
## Browsing/Identification ###
# Change this to the workgroup/NT-domain name your Samba server will part of
workgroup = WORKGROUP
# server string is the equivalent of the NT Description field
server string = %h server
# 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
#### Debugging/Accounting ####
# This tells Samba to use a separate log file for each machine
# that connects
#log file = /var/log/samba/log.%m
# Cap the size of the individual log files (in KiB).
max log size = 1000
# If you want Samba to only log through syslog then set the following
# parameter to 'yes'.
syslog only = yes
# We want Samba to log a minimum amount of information to syslog. Everything
# should go to /var/log/samba/log.{smbd,nmbd} instead. If you want to log
# through syslog you should set the following parameter to something higher.
syslog = 1
# Do something sensible when Samba crashes: mail the admin a backtrace
panic action = /usr/share/samba/panic-action %d
####### Authentication #######
# "security = user" is always a good idea. This will require a Unix account
# in this server for every user accessing the server. See
# /usr/share/doc/samba-doc/htmldocs/Samba3-HOWTO/ServerType.html
# in the samba-doc package for details.
# security = user
security = share
# You may wish to use password encryption. See the section on
# 'encrypt passwords' in the smb.conf(5) manpage before enabling.
encrypt passwords = true
# If you are using encrypted passwords, Samba will need to know what
# password database type you are using.
passdb backend = tdbsam
obey pam restrictions = yes
# This boolean parameter controls whether Samba attempts to sync the Unix
# password with the SMB password when the encrypted SMB password in the
# passdb is changed.
unix password sync = yes
# For Unix password sync to work on a Debian GNU/Linux system, the following
# parameters must be set (thanks to Ian Kahan <<kahan@informatik.tu-muenchen.de> for
# sending the correct chat script for the passwd program in Debian Sarge).
passwd program = /usr/bin/passwd %u
passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
# This boolean controls whether PAM will be used for password changes
# when requested by an SMB client instead of the program listed in
# 'passwd program'. The default is 'no'.
pam password change = yes
#======================= Share Definitions =======================
#[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.
# The following parameter makes sure that only "username" can connect
# to \\server\username
# This might need tweaking when using external authentication schemes
valid users = %S
[dingo_public]
writeable = yes
browseable = yes
path = /media/data/public_data
force directory mode = 777
force create mode = 777
public = yes
create mode = 777
directory mode = 777
[homes]
comment = Home Directories
browseable = no
valid users = %S
writable = yes
create mode = 777
directory mode = 777
|
So komm ich allerdings ohne einloggen nicht zur Public-Freigabe, und in die Home-Verzeichnisse komm ich dann wieder nicht obwohl ich mich einlogg weil User und PW als falsch angesehen werden, obwohl die user natürlich auch samba-user sind. Samba restart mach ich natürlich immer. Ich komm da echt nicht mehr weiter, hab auch schon alle möglichen Configs ausem Netz probiert, aber auch da das selbe, so wie ich mich kenn isses nur irgendwas ganz kleines mit großer Wirkung ... Achja als Client kommt Win7 und OSX 10.8 zum Einsatz, tut bei beiden nicht 😉 Ich bin doch nicht der Erste der so ne Konfiguration machen will, vlt kann mir jemand mal seine komplette Config zukommen lassen ☺ Gruß
David Bearbeitet von tomtomtom: Absichtlich falsch gesetzte Version aus Versionauswahl entfernt.
|
tomtomtom
Supporter
Anmeldungsdatum: 22. August 2008
Beiträge: 55472
Wohnort: Berlin
|
daviid schrieb: Dadrauf läuft Debian 6.0, nicht das was ich oben angegeben hab, denn da musst man irgendwas angeben ...
Das liegt überraschender Weise daran, dass das hier ein Ubuntu-Supportforum ist und man daher die genutzte Ubuntu-Version dort einträgt. Nutzt man eine andere Distribution, postet man eben nicht im Supportbereich und muss auch keine Version auswählen. Und die Leute, die Themen zu einer bestimmten Ubuntu-Version abonniert haben, um damit zu helfen, freuen sich sicherlich immer sehr, wenn sie Benachrichtigungen bekommen, weil User absichtlich falsche Angaben machen.
|
daviid
(Themenstarter)
Anmeldungsdatum: 14. April 2009
Beiträge: 14
|
Schön, aber wo soll es denn dann hin? Außerdem ist bei solchen Fragen die Distri relativ egal, erst recht wenns um Debian geht, denn dadrauf basiert Ubuntu schließlich. Wenns nen besseren Bereich gibt bitte verschieben. Ansonsten freu ich mich auch wirklich über Antworten zum eigentlichen Thema ☺
|
tomtomtom
Supporter
Anmeldungsdatum: 22. August 2008
Beiträge: 55472
Wohnort: Berlin
|
daviid schrieb: Schön, aber wo soll es denn dann hin?
In ein Debianforum, wäre wohl die sinnvollste Antwort. Klingt logisch, ist aber so. Ansonten gibt es in diesem Ubuntu-Forum ein Unterforum "Rund um Linux und OpenSource".
Außerdem ist bei solchen Fragen die Distri relativ egal, erst recht wenns um Debian geht, denn dadrauf basiert Ubuntu schließlich.
Zum zwölfundreißigsten Mal: Wenn man danach gehen würde, würde es überhaupt keine Distributionsspezifischen Foren geben. Die Community gehört nämlich zur gewählten Distribution dazu...
|
daviid
(Themenstarter)
Anmeldungsdatum: 14. April 2009
Beiträge: 14
|
Du willst mir jetzt nicht ernsthaft verklickern dass es jetzt nen Unterschied macht ob das Problem jetzt auf Debian oder Ubuntu besteht, nächstes mal geb ich einfach irgendne Ubuntuversion an, dann scheint man wohl zufrieden zu sein. Warum ich nicht ins Debianforum gegangen bin? Weil ich hier schon angemeldet bin, ganz einfach. Da man hier aber anscheinend eine Abneigung gegen Debianuser hat, wars dass dann auch erstmal, Zeitverschwendung da zu diskutieren. Ich komm dann wieder vorbei sollt ich mal nen Ubuntu Problem haben, aber auch NUR dann!
|
tomtomtom
Supporter
Anmeldungsdatum: 22. August 2008
Beiträge: 55472
Wohnort: Berlin
|
daviid schrieb: Du willst mir jetzt nicht ernsthaft verklickern dass es jetzt nen Unterschied macht ob das Problem jetzt auf Debian oder Ubuntu besteht
Wäre nicht unmöglich, habe ich aber nie behauptet. nächstes mal geb ich einfach irgendne Ubuntuversion an, dann scheint man wohl zufrieden zu sein.
Genau das hast du getan und genau das wurde bemängelt...
Warum ich nicht ins Debianforum gegangen bin? Weil ich hier schon angemeldet bin, ganz einfach.
...
Da man hier aber anscheinend eine Abneigung gegen Debianuser hat
Ich bin selbst Debian-User und hab da naturgemäß keine Abneigung gegen. Allerdings hab ich eine Aversion gegen Leute, die mit falschen Angaben in falschen Foren posten und sich beschweren, dass man auch noch etwas dazu sagt...
|
Max-Ulrich_Farber
Anmeldungsdatum: 23. Januar 2007
Beiträge: 8010
|
Ich verstehe tomtomtom gut, dass er sich ärgert, weil Du eine falsche Linux-Version angegeben hast. Als Supporter und Moderator hat er mit solchen Dingen eben immer wieder nur Ärger. Sehen wir mal von diesem Fehler (denn es war einer) ab und versuchen wir, das Problem trotzdem zu lösen. Denn Du hast schon Recht, Samba ist in Debian und Ubuntu das gleiche. Und Du bist ja (nebenbei) auch noch Ubuntu-User 😉 .
security = share
Das ist auf jeden Fall ungünstig; security = user wäre sicher besser. Außerdem sind Deine Angaben zu create mode = xxx usw. seltsam. Sinnvoll wäre
# in [dingo_public]:
force directory mode = 0777
force create mode = 0666
# Einschränkungen mittels `directory mode` und `create mode` sind nicht nötig.
# in [homes]:
create mode = 0600
directory mode = 0700
Hast Du bedacht, dass diese Optionen nur für Dateien und Ordner gelten, die Du über Samba neu anlegst? Für alle übrigen Ordner und Dateien musst Du die Rechte mittels chown und ccmod von Hand passend einrichten. Wenn Du auch den Gast-Zugriff verwendest, wären sicher im Teil [global] folgende Optionen sinnvoll:
map to guest = bad user
guest account = nobody Damit wäre Deine smb.conf soweit ich sehe recht normal. Weitere Probleme sind dann wahrscheinlich von den Clients bedingt. - Du hast bedacht, dass man sich von Windows aus nicht während der gleichen Sitzung mit verschiedenen Identitäten auf dem gleichen Server anmelden kann? Ich denke, das ist wohl bei Win7 und Win8 immer noch so (?). Gruß - Max-Ulrich
|
daviid
(Themenstarter)
Anmeldungsdatum: 14. April 2009
Beiträge: 14
|
OK, danke für die Antwort. Hab die Config jetzt nach deinen Vorschlägen geändert:
#======================= Global Settings =======================
[global]
## Browsing/Identification ###
# Change this to the workgroup/NT-domain name your Samba server will part of
workgroup = WORKGROUP
# server string is the equivalent of the NT Description field
server string = %h server
# 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
map to guest = bad user
guest account = nobody
#### Debugging/Accounting ####
# This tells Samba to use a separate log file for each machine
# that connects
#log file = /var/log/samba/log.%m
# Cap the size of the individual log files (in KiB).
max log size = 1000
# If you want Samba to only log through syslog then set the following
# parameter to 'yes'.
syslog only = yes
# We want Samba to log a minimum amount of information to syslog. Everything
# should go to /var/log/samba/log.{smbd,nmbd} instead. If you want to log
# through syslog you should set the following parameter to something higher.
syslog = 1
# Do something sensible when Samba crashes: mail the admin a backtrace
panic action = /usr/share/samba/panic-action %d
####### Authentication #######
# "security = user" is always a good idea. This will require a Unix account
# in this server for every user accessing the server. See
# /usr/share/doc/samba-doc/htmldocs/Samba3-HOWTO/ServerType.html
# in the samba-doc package for details.
security = user
#security = share
# You may wish to use password encryption. See the section on
# 'encrypt passwords' in the smb.conf(5) manpage before enabling.
encrypt passwords = true
# If you are using encrypted passwords, Samba will need to know what
# password database type you are using.
passdb backend = tdbsam
obey pam restrictions = yes
# This boolean parameter controls whether Samba attempts to sync the Unix
# password with the SMB password when the encrypted SMB password in the
# passdb is changed.
unix password sync = yes
# For Unix password sync to work on a Debian GNU/Linux system, the following
# parameters must be set (thanks to Ian Kahan <<kahan@informatik.tu-muenchen.de> for
# sending the correct chat script for the passwd program in Debian Sarge).
passwd program = /usr/bin/passwd %u
passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
# This boolean controls whether PAM will be used for password changes
# when requested by an SMB client instead of the program listed in
# 'passwd program'. The default is 'no'.
pam password change = yes
#======================= Share Definitions =======================
#[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.
# The following parameter makes sure that only "username" can connect
# to \\server\username
# This might need tweaking when using external authentication schemes
valid users = %S
[dingo_public]
writeable = yes
browseable = yes
path = /media/data/public_data
force directory mode = 0777
force create mode = 0666
public = yes
[homes]
comment = Home Directories
browseable = no
valid users = %S
writable = yes
create mode = 0600
directory mode = 0700
Ergebnis ist folgendes:
Unter Windows bekomm ich wenn ich nur auf den Server selber mit Windowstaste+R und dann "\\ip-des-servers\" zufreifen möchte eine Anmeldeabfrage, gleiches am Mac. Wenn ich jetzt in nen Homeverzeichnis möchte mit "\\ip-des-servers\user" kommt natürlich auch die Anmeldeabfrage, aber wenn ich da den passenden user und pw angeb komm ich auch nicht rein. Ich versteh da langsam nurnoch Bahnhof ...
|
Obreien
Anmeldungsdatum: 18. Mai 2011
Beiträge: 52
|
Hi, hast du auch für die Anmeldung der User, die entsprechende Datei (smbuser.conf)angelegt und auch den Pfad in der smb.conf eingetragen? Das war bei mir z.B. der Fehler, warum ich mich nicht anmelden konnte.
|
Max-Ulrich_Farber
Anmeldungsdatum: 23. Januar 2007
Beiträge: 8010
|
@Obreien:
hast du auch für die Anmeldung der User, die entsprechende Datei (smbuser.conf) angelegt und auch den Pfad in der smb.conf eingetragen?
Was ist das für eine Datei? Kenne ich nicht! @daviid;
aber wenn ich da den passenden user und pw angeb komm ich auch nicht rein
Du kommst nur in Dein eigenes Heimverzeichnis rein (bzw. in das des jeweils eingeloggten Benutzers) wegen valid users = %S . Warum hast Du denn die Optionen für [homes] doppelt in der smb.conf? Das geht nicht. Entweder Du kommentierst alle Zeilen der ersten kommentierten Fassung aus (mit Semikolon am Zeilenanfang), oder Du reaktivierst die kommentierte Fassung und entfernst die zweite.. Gruß - Max-Ulrich
|