• Willkommen im Linux Club - dem deutschsprachigen Supportforum für GNU/Linux. Registriere dich kostenlos, um alle Inhalte zu sehen und Fragen zu stellen.

[gelöst] - Wie bekomme ich Zugriff auf "root"?

nils99

Newbie
Hallo,
wenn ich in der Netzwerkumgebung von Windows auf dem Samba Server zugreife, dann kommt zunächst eine Passwortabfrage. Nach dem erfolgreichen Login sehe ich die Ordnerstruktur des Homeverzeichnis des Users. Welche Einstellung muss ich in der smb.conf ändern, damit ich Zugriff auf die komplette Struktur von Linux (also root) bekomme? Meine smb.conf hat folgenden Quellcode:



#
# /etc/samba/smb.conf ist the main samba configuration file. Cf. the
# manual page of smb.conf and the included documantation in
# /usr/share/doc/packages/samba in order to understand the options
# listed here and many more features.
#
# Lines in this example which starts with ; and # are ignored comment
# ones. # indicates a comment and ; a deactivated example line.
#
# We suggest to use the command 'testparm' after any changes you made.
#
# Copyright (c) 1999 - 2001 SuSE GmbH Nuernberg, Germany.
#
# Please send bugfixes or comments to feedback@suse.de.
#
[global]
workgroup = ARBEITSGRUPPE
os level = 2

security = user
encrypt passwords = YES
guest account = Nobody
map to guest = Bad User
# This tells samba to use the file smbusers for user mapping.
; username map = /etc/samba/smbusers

# This tells samba to write log files per machine.
; log file = /var/log/samba/%m
# This sets an alternate log level. Default is 2.
; log level = 3

# Uncomment the following, if you want to use an existing NT-Server to
# authenticate users, but don't forget that you also have to create them
# locally!
; security = server
; password server = 192.168.1.10

printing = LPRNG
printcap name = /etc/printcap
load printers = Yes

# These settings are a suggestion for a local network. Cf. section
# 'socket options' in the man page of smb.conf and socket(7).
socket options = SO_KEEPALIVE IPTOS_LOWDELAY TCP_NODELAY

# Uncomment this, if you want to integrate your server
# into an existing net e.g. with NT-WS to prevent nettraffic
; local master = No

# Please uncomment the following entry and replace the ip number and
# netmask with the values of your network interface configuration.
; interfaces = eth0

# If you want Samba to act as a wins server, please set
# 'wins support' to yes.
wins support = No

# If you want Samba to use an existing wins server, please uncomment the
# following line and replace the dummy with the wins server's ip number.
; wins server = 192.168.1.1

# Set these two parameters to your DOS code page and appropriate UNIX
# character set. These values are for west European languages (Latin-9)
# UNIX character and MS-DOS Latin 1 code page.
character set = ISO8859-15
client code page = 850

# This is a simple measure against Nimba Worm. Cf. README.Win32-Viruses
veto files = /*.eml/*.nws/riched20.dll/*.{*}/

# Do you wan't samba to act as a logon-server for your windows 95/98
# clients, so uncomment the following:
; domain logons = Yes
; domain master = Yes
# For a specific logon script per user
; logon script = %U.bat
# For a specific logon script per machine
; logon script = %m.bat

# Where to store the logon scripts.
;[netlogon]
; comment = Network Logon Service
; path = /var/lib/samba/netlogon

# Where profiles of Windows 9x systems are stored.
# First example for a centralized place.
; logon home = \\%L\profiles\%U
# Second example for a subdirectory of the users home.
; logon home = \\%L\%U\profile
# Where profiles of Windows NT systems are stored.
; logon path = \\%L\profiles\%U

# Extra share for profiles. Default is the home of the user.
;[profiles]
; comment = Network Profiles Service
; path = /var/lib/samba/profiles
; browseable = No

[homes]
comment = Home Directories
read only = No
create mask = 0640
directory mask = 0750
browseable = No

# The following share gives all users access to the Server's CD drive,
# assuming it is mounted under /media/cdrom. To enable this share,
# please remove the semicolons before the lines
;[cdrom]
; comment = Linux CD-ROM
; path = /media/cdrom
; locking = No

[printers]
comment = All Printers
path = /var/tmp
create mask = 0600
printable = Yes
browseable = No

edit mod.: 24.12.05 auf gelöst gesetzt
 

Yehudi

Guru
lege einen "Share" an indem Du nur ein "/" setzt ( ohne Anführungsstriche) Allerdings wäre es fraglich, ob es Sinn macht, denn als root eingelogt zu sein, ist immer gefährlich.
 
OP
N

nils99

Newbie
Danke für die schnelle Hilfe, es hat geklappt!

Code:

[share]
; comment = Testebene
; path = /


Leider habe ich auf KEINEN Ordner Schreibrechte, obwohl ich verschiedene Testordner die Rechte 777 vergeben habe. Muss ich in der smb.conf noch einen Parameter setzen, damit ich Schreibrechte bekomme?

Angemeldet bin ich als root.
 
OP
N

nils99

Newbie
Ich habe den Code erweitert in:

[share]
; comment = Testebene
; path = /
; read only = No


Ich habe immer noch keine Schreibrechte :-(
 
OP
N

nils99

Newbie
Ich habe den Code nochmal erweitert:

create mask = 0640
directory mask = 0750
browseable = No

Zusätzlich habe ich den Samba nochmal neu gestartet. Jetzt gehts!


Vielen Dank für eure schnelle Hilfe!
 

zero0109

Hacker
Also ob du schreiben darfst, hat weder etwas mit den masks noch mit browsealble zu tun. Es ist allerdings wichtig, dass du nach jeder Änderung den smbd neustartest.

[share]
; comment = Testebene
; path = /
; read only = No
Außerdem verstehe ich nicht, wieso du immer diese Kommentarzeichen vor den Code setzt. Dadurch bewirken deine Änderungen nämlich nichts.
 

Yehudi

Guru
zero0109 schrieb:
Also ob du schreiben darfst, hat weder etwas mit den masks noch mit browsealble zu tun. Es ist allerdings wichtig, dass du nach jeder Änderung den smbd neustartest.

Das ist nicht ganz korrekt, denn die smb.conf wird mindestens in einem Abstand von 90 sec oder wie selber eingestellt neu eingelesen. Bereits angemeldete Clients erhalten die neuen Infos der smb.conf erst durch erneutes anmelden.
 

zero0109

Hacker
Jo, da hast du recht, aber ich hab vor einiger Zeit (ich denke das war noch Samba 2.x) die Erfahrung gemacht, dass falls in der Datei ein Fehler vorliegt, der smbd die alte Version weiterverwendet.
 
Oben