Samba-Server wird unter WIN nicht angezeigt

red-ultra

Lt. Junior Grade
Registriert
Apr. 2004
Beiträge
340
Hallo,

als Linux-Einsteiger probiere ich gerade einen File-Server unter Redhat9 einzurichten. Ich habe dazu einen Benutzer im System und einen Samba Benutzer erstellt und die smb.conf (siehe unten) erstellt.
Vom und zum Server kann ich erfolgreich pingen, Dienst ist auch im System aktiviert. Aber ich kann leider unter WINDOWS/Arbeitsgruppe den Linux-Rechner nicht sehen.

Was hab ich falsch gemacht?

Gruß
red-ultra




Code:
[global]
printing = bsd
printcap name = /etc/printcap
load printers = yes
guest account = nobody
invalid users = root

; fix its netbios name
netbios name = pantoufle
; this is the network to listen to
; (you don't need samba on the other network card since it manages the Internet
; connection!)
interfaces = 192.168.0.1/255.255.255.0

; security user implies that every user must have an unix account on this server
security = user

; The workgroup name to which the server belongs
workgroup = MSHEIMNETZ
; The server description, readable when displaying the details
; %h is the DNS name of the server and %v the samba version
server string = %h server (Samba %v)

; We use the samba log file, not only the syslog one
syslog only = no

; The less important information has to be written into syslog,
; the other information is found in /var/log/smb(nmb)/
syslog = 0;

; Let's tune!
socket options = IPTOS_LOWDELAY TCP_NODELAY \
SO_SNDBUF=4096 SO_RCVBUF=4096

; We use encrypted passwords. Careful,
; every W95 client must be patched with MS SMB
; security patch.
; NT4 must be patched with SP3 or higher...
; I can't remember as far as W3.11 is concerned:
; it probably doesn't support encrypted passwords:(
encrypt passwords = yes

; This server also works as a WINS server.
; WINS allows two networks using different IP ranges
; (for example 192.168.0.0/255.255.255.0 et 192.168.0.1/255.255.255.0)
; to see the shared resources in the "other" network,
; as soon as the gateway is active.
wins support = yes

; OS level. Since our server is the domain master, local logons, etc, it is
; "higher" than the NT server, if there is one!
os level = 34

; Domain management
domain master = yes
local master = yes
preferred master = yes

; Management of domain connections
domain logons = yes

; Which script to run when a client connects?
; %g corresponds to the primary group name this user is a member
logon script = %g.bat
; In which directory can we find the startup script files?
; %L is the netbios name of the samba server
logon path=\\%L\netlogon
; Where to store the users profiles?
; %U is the user's login
logon home=\\%L\%U\winprofile

; In which order check the resources to find
; the name of a machine?
; Note the broadcast at the end ... unlike windows
; sending broadcast on a regular basis.
name resolve order = lmhosts host wins bcast

; Must Samba be used as a DNS proxy?
dns proxy = no

; Preserve filenames and their case
preserve case = yes
short preserve case = yes

; Must we synchronize windows and linux passwords?
unix password sync = yes

; What to use for passwords synchronization
passwd program = /usr/bin/passwd %u
passwd chat = *Enter\snew\sUNIX\spassword:* \
%n\n *Retype\snew\sUNIX\spassword:* %n\n .

; Maximum size of the log file,
; prevents from saturating the /var directory:p
max log size = 1000

; We are a time server: good thing to synchronize
; the machines time a bit.
; We'll use this feature from the logon .bat file
time server = yes

; We specify where the netlogon is.
; It is only used at connecting time,
; thus we don't need to make it public.
[netlogon]
path = /home/netlogon/%g
public = no
writeable = no
browseable = no

; The Home directory for every user
[homes]
comment = Home Directories
browseable = no

; He can write, can't he!
read only = no

; The default unix creation umask
create mask = 0700

; For security purpose, the directory
; mask is set to 700 as well!
directory mask = 0700


; We share FTP, it's easier to have it in
; the network neigborhood than to run
; a specific program.
[ftp]
path = /home/ftp/pub
public = yes
printable = no
guest ok = yes

; The temporary directory
[tmp]
path = /tmp
public = yes
printable = no
guest ok = yes
writable = yes

; another special temporary directory
; for a user needing much space!
[bigtemp]
path = /home/bigtemp
public = yes
printable = no
guest ok = yes
valid users = erics
writable = yes
 
Erstmal: hast Du den Samba mit swat konfiguriert? Wenn nicht, lege ich Dir das unbedingt nahe.

Ansonsten glaube ich nicht, dass
Code:
interfaces = 192.168.0.1/255.255.255.0
funktioniert. Da müsste eher
Code:
interfaces = eth0
oder so stehen. Kannst Du aber auch weglassen, wenn sich nur ein Interface im Rechner befindet (localhost wird ignoriert).

Und: diese Beispiel-Konfiguration - und so eine hast Du bestimmt benutzt - sind zwar schön und gut, aber erstens sind da teilweise seltsame und verwirrende Optionen eingestellt und zweitens verliert man nach wenigen Änderungen den Überblick.

os level darfst Du ruhigen Gewissens auf Standard oder höher lassen, das tut nicht weh. Du könntest auch noch
Code:
wins support = yes
setzen, macht eigentlich immer Sinn, wenn der Server durchgängig läuft.

Swat aktivierst Du durch folgende Zeile in der inetd.conf:

Code:
swat stream tcp nowait root /usr/local/samba/sbin/swat

(Wenn samba dort installiert ist, ansonsten bitte den Pfad anpassen.)

Gruß
Morgoth
 
Zuletzt bearbeitet:
Morgoth schrieb:
Erstmal: hast Du den Samba mit swat konfiguriert? Wenn nicht, lege ich Dir das unbedingt nahe.

Ansonsten glaube ich nicht, dass
Code:
interfaces = 192.168.0.1/255.255.255.0
funktioniert. Da müsste eher
Code:
interfaces = eth0
oder so stehen. Kannst Du aber auch weglassen, wenn sich nur ein Interface im Rechner befindet (localhost wird ignoriert).

Und: diese Beispiel-Konfiguration - und so eine hast Du bestimmt benutzt - sind zwar schön und gut, aber erstens sind da teilweise seltsame und verwirrende Optionen eingestellt und zweitens verliert man nach wenigen Änderungen den Überblick.

os level darfst Du ruhigen Gewissens auf Standard oder höher lassen, das tut nicht weh. Du könntest auch noch
Code:
wins support = yes
setzen, macht eigentlich immer Sinn, wenn der Server durchgängig läuft.

Swat aktivierst Du durch folgende Zeile in der inetd.conf:

Code:
swat stream tcp nowait root /usr/local/samba/sbin/swat

(Wenn samba dort installiert ist, ansonsten bitte den Pfad anpassen.)

Gruß
Morgoth


Hallo,

nein ich habe Samba nich mit SWAT konfiguriert, weil SWAT nicht funktioniert. Ich habe hier einen Samba Ordner in /etc/samba mit mehreren Dateien u.a. auch die smb.conf. Ich weiß leider nicht ob dies der Installationsordner ist, den ich als alter Windows Hase kann da keine Installationsdateien erkennen.

Außerdem habe ich noch einen SWAT Ordner in /usr/share der aber anscheinend nicht mit Samba zusammenhängt. Ein Samba Ordner befindet sich dort nicht.

Die Dämonen (nmbd und smbd) habe ich auch nicht aktiviert, weil ich ehrlich gesagt nicht weiß wie ich das machen soll. Obwohl das öfters auf Seiten erklärt ist, wie man das standartmäßig konfiguriert.

Zur Beispielskonfiguration: Ich habe definitiv keine Ahnung wie ich so eine ganze Konfigurationsdatei selbst schreiben sollte, ich verstehe die Parameter, aber warum muss man das den alles selbst schreiben?

Wie muss ich den jetzt den Eintrag in xinetd.conf anpassen, um SWAT zu aktivieren? Muss das der Pfad von Samba sein, oder vom SWAT Ordner?

Code:
swat stream tcp nowait root /etc/samba/

Ist doch echt komisch, dass man die Dinge immer so kompliziert machen muss.

Aber danke schonmal für eure Hilfe.


Gruß

red-ultra
 
Swat wird von (x)inetd gestartet, wenn erforderlich. In der inetd.conf muss deshalb der Pfad zu der Datei swat angegeben werden. In der normalen Installation von Samba ist das eben /usr/local/samba/sbin/swat. Wie RedHat das gemacht hat, weiß ich nicht, musst Du gegebenenfalls anpassen.

Zugriff auf swat erhältst Du dann über den Browset mit localhost:901. Dann gibst Du noch als Benutzer root und das entsprechende Passwort an (um die smb.conf zu ändern brauchst Du eh root-Rechte) und schon kannst Du Samba ganz einfach konfigurieren.

Gruß
Morgoth
 
Also mein SWAT liegt anscheinend in /usr/share/swat (mit lang datein etc.) habe das umgeändert und in die xinetd.conf eingetragen. dann versucht den dienst neuzustarten.
habe komischerweise zwei inetd.'s
Einmal inetd < Order
und xinet.d Ordner

Wenn ich versuche über localhost draufzuzugreifen, kommt immer refused.
 
Probier mal den Befehl "testparm". Der überprüft deine smb.conf auf ihre Richtigkeit und gibt sie danach nochmal volständig auf dem Bildschrim aus.

Gruss,

der Gecko
 
red-ultra schrieb:
Also mein SWAT liegt anscheinend in /usr/share/swat (mit lang datein etc.)

Ne, ganz bestimmt nicht, das sind die Konfigurationsdateien von swat. Die eigentliche, für den inetd wichtige Datei liegt ganz bestimmt in ./samba/sbin

Der Pfad muss also ./samba/sbin/swat lauten (wobei der "." den prefix darstellt, in der Standardinstallation also /usr/local )

Probier es mal mit den Beispiel, das ich gegeben habe.

@ElGecko:

dann würde aber der nmdb/smbd gar nicht starten sondern mit ner Fehlermeldung aussteigen.

Gruß
Morgoth
 
Zuletzt bearbeitet:
Hatte aber auch schon das Phänomen, dass der Server gestartet ist, obwohl testparm mir paar Fehler gebracht hat. Weiss zwar auch nicht warum der darum trotzdem gestartet hat, aber naja.

Er solls mal probieren, vielleicht hat er "Glücke" und es zeigt ihm ein paar Fehler an.

Gruss,
der Gecko
 
Zurück
Oben