Bug 22865 - Integration File und Print
Integration File und Print
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: Samba4
UCS 3.0
Other Linux
: P5 normal (vote)
: UCS 3.0 - RC
Assigned To: Arvid Requate
Stefan Gohmann
:
: 24488 (view as bug list)
Depends on: 24429
Blocks:
  Show dependency treegraph
 
Reported: 2011-06-28 06:44 CEST by Stefan Gohmann
Modified: 2011-12-13 15:50 CET (History)
1 user (show)

See Also:
What kind of report is it?: ---
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional):
Max CVSS v3 score:


Attachments
logs.tgz (72.98 KB, application/x-gtar)
2011-11-14 13:32 CET, Stefan Gohmann
Details
log.samba.bz2 (343.78 KB, application/x-bzip2)
2011-11-23 09:24 CET, Stefan Gohmann
Details
log.smbd.bz2 (41.18 KB, application/x-bzip2)
2011-11-23 09:25 CET, Stefan Gohmann
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Gohmann univentionstaff 2011-06-28 06:44:39 CEST
Die File- und Print-Dienste sind in Samba 4 noch nicht umgesetzt. Hier wird derzeit Upstream an einer Lösung gearbeitet.
Comment 1 Stefan Gohmann univentionstaff 2011-08-18 15:08:04 CEST
Anfang Oktober sollten wir den Upstream Status prüfen. Notfalls muss File und Print auf einem separaten Server laufen.
Comment 2 Arvid Requate univentionstaff 2011-10-12 15:28:01 CEST
* Das Samba4-Paket aus Bug 23929 bringt /usr/sbin/smbd mit. Dieser wird jetzt in /etc/samba/smb.conf über das Subfile 80univention-smb-service konfiguriert, falls samba4/service/smb den Defaultwert smbd hat. Der smbd wird in diesem Fall in /etc/init.d/samba4 mit gestartet/gestoppt.

* Per samba4/ntacl/backend lässt sich vorgeben, welches Backend für die NTACL verwendet wird: Bei der Defaulteinstellung 'native' speichern die Samba4-Tools die NTACL in Posix Extended Attributes des zugrunde liegenden Dateisystems. Die alternative Einstellung 'tdb' ist nur pro forma in der Konfiguration unterstützt, sie ist aktuell upstream nicht empfohlen, da das samba3/smbd VFS Modul acl_tdb nicht das NTACL-Format unterstützt, das die Samba4-Tools verwenden.

* Im Joinskript von univention-samba4 wird jetzt vor dem Provision/Join das Skript

 /usr/share/univention-samba4/scripts/mount_extfs_with_user_xattr.py

aufgerufen, dass über das Python-Modul univention.lib.fstab an alle ext3/ext4 Dateisystem-Definitionen in /etc/fstab die Option user_xattr hinzufügt und die Partitionen remountet, deren Eintrag verändert werden mussten. XFS sollte standardmäßig xattr unter stützen.

* Da sich im neuen samba4-Paket die samba-tool option 'acl nt' in 'ntacl geändert hat wurden die zwei Aufrufe im sysvol-sync.sh Skript angepasst.



Folgende Tests wurden bisher durchgeführt:

 1. NTACL auf Basis von Posix Extended Attributes:

#----------------
/usr/share/univention-samba4/scripts/set_sysvol_ntacl.py -v \
               /var/lib/samba/sysvol
apt-get install attr; getfattr -m '' -d /var/lib/samba/sysvol
/usr/share/univention-samba4/scripts/sysvol-sync.sh
#----------------

 2. Fileservice Access, Authentication und Authorization:

#----------------
echo 'put /etc/hosts h1' | smbclient //localhost/sysvol \
                -UAdministrator%univention
echo 'put /etc/hosts h2' | smbclient //localhost/sysvol \
                -Uuser2%univention
#----------------
Comment 3 Arvid Requate univentionstaff 2011-10-12 20:27:00 CEST
Die [home], [printers] und [print$] shares sind jetzt wieder aktiviert, alle Optionen aus univention-samba(3), die den smbd betreffen könnten sind jetzt wieder in de templates für smb.conf, sie sind durch samba4/service/smb=smbd eingeblendet.

Zugriff auf //localhost/Administrator geht mit dieser Konfiguration.

Interessant ist, dass 'homes' nicht mehr in der Übersicht von 'smbclient -L' aufgeführt wird, anders als beim samba3 smbd (aus ucs 2.4-0).
Wenn man testweise 'browsable' für das share aktiviert, wird es wieder aufgeführt.

Zugriff auf das eigene Homeverzeichnis per //localhost/homes geht bisher nicht, auch nicht wenn das share 'browsable' konfiguriert ist.
Comment 4 Arvid Requate univentionstaff 2011-10-12 22:13:12 CEST
Die Printershares sind noch nicht erreichbar, weder per

smbclient -L noch per

rpcclient -UAdministrator%univention localhost -c enumprinters

Sysvol und netlogon lassen sich hingegen finden per

rpcclient -UAdministrator%univention localhost -c netshareenum
Comment 5 Stefan Gohmann univentionstaff 2011-10-13 07:08:32 CEST
Folgende Meldung tritt beim Update auf:

univention-samba4 (1.0.60-7.121.201110122004) wird eingerichtet ...
Multifile: /etc/samba/smb.conf
Traceback (most recent call last):
  File "<stdin>", line 52, in <module>
NameError: name 'samba4_service_smb' is not defined
Comment 6 Stefan Gohmann univentionstaff 2011-10-15 21:03:33 CEST
Das Listener Modul für die Shares sollte noch aus dem univention-samba Paket übernommen werden.
Comment 7 Arvid Requate univentionstaff 2011-10-17 17:53:00 CEST
Das Listener-Modul samba-shares ist jetzt übernommen und funktioniert. Ein Kurzer Test mit "Zugelassene Benutzer" und "Erzwungener Benutzer" hat funktioniert.

Da ext3 jetzt mit user_xattr gemountet wird, kann es sinnvoll sein, an einer Freigabe unter 'VFS-Objekt' zusätzlich acl_xattr anzugeben. Wie das mit dem klassischen "nt acl support" harmoniert, muss noch getestet werden.
Comment 8 Arvid Requate univentionstaff 2011-10-17 19:43:44 CEST
smbd ist jetzt gegen CUPS gebaut, dafür musste CUPS gegen heimdal-dev statt gegen libkrb5-dev gebaut werden. Leider zieht der smbd anscheinend die PCAP Daten noch nicht korrekt aus CUPS.
Comment 9 Arvid Requate univentionstaff 2011-11-02 18:00:06 CET
CUPS-Drucker werden jetzt auch als Samba-Shares angezeigt, selbst wenn im UDM nicht explizit ein Share-name angegeben wird. Das waren https://bugzilla.samba.org/show_bug.cgi?id=8553 un https://bugzilla.samba.org/show_bug.cgi?id=8554 .
Comment 10 Arvid Requate univentionstaff 2011-11-09 16:30:41 CET
*** Bug 24488 has been marked as a duplicate of this bug. ***
Comment 11 Arvid Requate univentionstaff 2011-11-09 16:52:21 CET
Der Patch für Samba Bug 8384 ("Windows XP clients seem to crash smbd process every once in a while") wurde übernommen, das Paket ist neu gebaut.
Comment 12 Stefan Gohmann univentionstaff 2011-11-14 13:31:25 CET
File-Zugriff war soweit erfolgreich.

* Zwei Domänen amd64 und i386

* Jeweils Windows XP und Windows 7

* Dateien auf Shares erstellt, geöffnet und gelöscht

* Excel Dateien erstellt und bearbeitet.


Print war nicht erfolgreich. Unter Windows 7 konnte ich den Drucker verbinden, unter Windows XP wird angezeigt, dass nicht ausreichend Berechtigungen vorhanden sind.
Comment 13 Stefan Gohmann univentionstaff 2011-11-14 13:32:43 CET
Created attachment 3793 [details]
logs.tgz

log.samba und log.smbd
Comment 14 Arvid Requate univentionstaff 2011-11-15 16:25:42 CET
In meinem Test funktionierte der Zugriff von einem XP-Client aus.
Angepasst habe ich noch:

 * /etc/init.d/cups muss zur Zeit samba4 reload starten, damit die Drucker z.B. nach dem Booten vom smbd eingelesen werden (cups startet nach samba4..)

 * Der Code aus dem univention-samba Joinscript zum Anlegen der Druckertreiber-Verzeichnisse war noch nicht übernommen. Mit der Änderung funktionierte jetzt auch der Treiberupload von einem XP-Client aus sowie das Einbinden eines Druckers als normaler Benutzer, wenn ein Treiber serverseitig hinterlegt worden ist.
Comment 15 Stefan Gohmann univentionstaff 2011-11-23 09:21:53 CET
Es funktioniert weder von Windows XP, noch von Windows 7. Ich bekomme immer den Hinweis, das ich keine Berechtigung habe.

In dem Windows Fenster steht: "Verbinden mit  an Slave63". Dort fehlt der Druckername. Getestet habe ich auf einem DC Slave und Windows XP SP3. Printer Ausgabe von testparm:

[printers]
        comment = Drucker
        path = /tmp
        create mask = 0700
        printable = Yes
        browseable = No

[print$]
        comment = Printer Drivers
        path = /var/lib/samba/drivers
        write list = root, Administrator, @Printer-Admins
        read only = No

root@slave63:~# cat /etc/cups/printers.conf
# Printer configuration file for CUPS v1.4.4
# Written by cupsd
# DO NOT EDIT THIS FILE WHEN CUPSD IS RUNNING
<Printer HpTechnik>
AuthInfoRequired none
Info HpTechnik
MakeModel HP LaserJet p2015 Series hpijs pcl3, 3.10.6.15
DeviceURI socket://HPTechnik.knut.univention.de:9100
State Idle
StateTime 1321869096
Reason toner-low-report
Type 8425500
Filter application/vnd.cups-raw 0 -
Filter application/vnd.cups-postscript 100 foomatic-rip-hplip
Filter application/vnd.cups-pdf 0 foomatic-rip-hplip
Accepting Yes
Shared Yes
JobSheets none none
QuotaPeriod 0
PageLimit 0
KLimit 0
OpPolicy default
ErrorPolicy stop-printer
Attribute marker-colors none
Attribute marker-levels 0
Attribute marker-names Black Cartridge
Attribute marker-types toner
Attribute marker-change-time 1321869096
</Printer>
Comment 16 Stefan Gohmann univentionstaff 2011-11-23 09:24:46 CET
Created attachment 3865 [details]
log.samba.bz2

Debug Level 10
Comment 17 Stefan Gohmann univentionstaff 2011-11-23 09:25:07 CET
Created attachment 3866 [details]
log.smbd.bz2

Debug Level 10
Comment 18 Arvid Requate univentionstaff 2011-11-23 15:28:38 CET
Das funktioniert jetzt, nachdem zusätzlich auch der zweite Patch für https://bugzilla.samba.org/show_bug.cgi?id=8554 übernommen wurde.

Auf anraten von Stefan Metzmacher wurde auch der zweite git ammend Patch für Bug 24488 ("Windows XP clients seem to crash smbd process every once in a while") übernommen, da der erste das Problem nur unvollständig behebt (https://bugzilla.samba.org/show_bug.cgi?id=8384 ).

Paket ist für i386 und amd64 gebaut. Getestet wurde auf i386.
Comment 19 Stefan Gohmann univentionstaff 2011-11-23 18:42:42 CET
Ja, drucken funktioniert jetzt wie erwartet. Sowohl von XP, als auch von Windows 7.
Comment 20 Arvid Requate univentionstaff 2011-11-24 14:36:22 CET
Changelog ergänzt:

\item To offer file and print services in the Samba 4 configuration of \ucsUCS{},
an updated version of the \ucsName{smbd} process from the Samba3 code base is used
(\ucsBug{22865}).
Comment 21 Sönke Schwardt-Krummrich univentionstaff 2011-12-13 15:50:08 CET
UCS 3.0-0 wurde veröffentlicht. Sollte der hier beschriebene Bug mit einer
neueren Version von UCS erneut auftreten, so sollte dieser Bug dupliziert
werden: "Clone This Bug"