[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

smbfs: uid- und gid-Optionen zeigen keine Wirkung beim Mounten



Hallo,

ich bin etwas verwirrt ueber das Verhalten von smbmount beim Mounten von Samba Shares.

Folgendes Scenario: Eine meiner Windows-Partitionen habe ich unter Linux ins FS eingebaunden (mit der gid "datadisk"):

~ > ll /mnt/datadisk/
drwxrwx---  11 root datadisk 32768 2004-09-06 12:04 Bilder
drwxrwx---   5 root datadisk 32768 2004-02-14 12:23 Games
drwxrwx---   2 root datadisk 32768 2004-02-14 11:35 Recycled
drwxrwx---   3 root datadisk 32768 2004-02-14 10:15 System Volume Information
drwxrwx---   3 root datadisk 32768 2004-09-20 18:27 temp

Diese Partition habe ich ueber Samba freigegeben:

[datadisk]
        comment = Datadisk-Freigabe
        path = /mnt/datadisk
        read only = No
        guest ok = Yes

Versuche ich nun, diese Freigabe zu mounten (zunaechst auf dem selben Rechner) funktioniert das zwar, die Optionen gid und uid werden aber ignoriert:

~ > mount -t smbfs -o uid=root,gid=samba,guest //ds9/datadisk test
~ > ll test
drwxrwx---  1 root datadisk 0 2004-09-06 12:04 Bilder
drwxrwx---  1 root datadisk 0 2004-02-14 11:23 Games
drwxrwx---  1 root datadisk 0 2004-02-14 10:35 Recycled
drwxrwx---  1 root datadisk 0 2004-02-14 09:15 System Volume Information
drwxrwx---  1 root datadisk 0 2004-09-20 18:27 temp

Eigentlich haette ich erwartet, dass die Gruppe fier diese Verzeichnisse "samba" ist.

~ > grep samba /etc/group
samba:x:1002:sarek

Aber auch, wenn ich mit der Option gid=1002 mounte, bleibt die Gruppe als "datadisk" gesetzt.

Ganz verrueckt wird es allerdings, wenn ich dieses Share auf einem anderen Rechner im Netz mounten will.

~ > ll test
drwxrwx---  1 root account 0 2004-09-06 12:04 Bilder
drwxrwx---  1 root account 0 2004-02-14 11:23 Games
drwxrwx---  1 root account 0 2004-02-14 10:35 Recycled
drwxrwx---  1 root account 0 2004-02-14 09:15 System Volume Information
drwxrwx---  1 root account 0 2004-09-20 18:27 temp

auf einem anderen Rechner kam es sogar vor, dass die zugewiesene Gruppe offenbar gar nicht existierte (jedenfalls wurde nur der numerische Wert) angezeigt:

~ > ll test
drwxrwx---  1 root 1004 0 2004-09-06 12:04 Bilder
drwxrwx---  1 root 1004 0 2004-02-14 11:23 Games
drwxrwx---  1 root 1004 0 2004-02-14 10:35 Recycled
drwxrwx---  1 root 1004 0 2004-02-14 09:15 System Volume Information
drwxrwx---  1 root 1004 0 2004-09-20 18:27 temp

Das Resultat ist: Ich kann das Share zwar mounten, wenn ich aber Pech habem und die zugewiesene Gruppe ganz kurios ist, kann ich mir das Verzeichnis bestenfalls anzeigen lassen vom Schreibzugriff mal ganz zu schweigen.

Kann sich/mir das jemand erklaeren?

Installierte Version von smbfs ist die aktuelle aus unstable:

ii  smbfs                         3.0.7-1

Ich bin mir ziemlich sicher, dass ich diese Probleme mit Samba 2.x damals nicht hatte.

Christian

P.S.

Hier zu Sicherheit noch mal der global-Block von dem Rechner, der die Partition freigibt:

[global]
        unix charset = UTF8
        workgroup = SPACEDOCK
        server string =
        interfaces = eth0
        bind interfaces only = Yes
        security = SHARE
        guest account = samba
        null passwords = Yes
        obey pam restrictions = Yes
        passwd program = /usr/bin/passwd %u
        passwd chat = *Enter\snew\sUNIX\spassword:* %n\n *Retype\snew\sUNIX\spassword:* %n\n .
        syslog = 0
        log file = /var/log/samba/log.%m
        max log size = 1000
        load printers = No
        printcap name = /etc/printcap.cups
        preferred master = Yes
        dns proxy = No
        ldap ssl = no
        panic action = /usr/share/samba/panic-action %d
        invalid users = root
        hosts allow = 192.168.
        printing = cups
        preserve case = No
        mangle case = Yes

--
To reply to this posting directly use the following address and
remove the 'NO-SPAM' part: Riedel.Christian.NO-SPAM@gmx.net



Reply to: