1 <!DOCTYPE html PUBLIC
"-//W3C//DTD XHTML 1.0 Strict//EN"
2 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
5 <title>Petter Reinholdtsen: entries from July
2010</title>
6 <link rel=
"stylesheet" type=
"text/css" media=
"screen" href=
"http://people.skolelinux.org/pere/blog/style.css">
7 <link rel=
"alternate" title=
"RSS Feed" href=
"07.rss" type=
"application/rss+xml">
14 <a href=
"http://people.skolelinux.org/pere/blog/">Petter Reinholdtsen
</a>
20 <p>Entries from July
2010.
</p>
25 <a href=
"http://people.skolelinux.org/pere/blog/Caching_password__user_and_group_on_a_roaming_Debian_laptop.html">Caching password, user and group on a roaming Debian laptop
</a>
33 <p>For a laptop, centralized user directories and password checking is
34 a bit troubling. Laptops are typically used also when not connected
35 to the network, and it is vital for a user to be able to log in or
36 unlock the screen saver also when a central server is unavailable.
37 This is possible by caching passwords and directory information (user
38 and group attributes) locally, and the packages to do so are available
39 in Debian. Here follow two recipes to set this up in Debian/Squeeze.
40 It is also possible to set up in Debian/Lenny, but require more manual
41 setup there because pam-auth-update is missing in Lenny.
</p>
43 <h2>LDAP/Kerberos + nscd + libpam-ccreds + libpam-mklocaluser/pam_mkhomedir
</h2>
45 This is the traditional method with a twist. The password caching is
46 provided by libpam-ccreds (version
10-
4 or later is needed on
47 Squeeze), and the directory caching is done by nscd. The directory
48 lookup and password checking is done using LDAP. If one want to use
49 Kerberos for password checking the libpam-ldapd package can be
50 replaced with libpam-krb5 or libpam-heimdal. If one is happy having a
51 local home directory with the path listed in LDAP, one can use the
52 pam_mkhomedir module from pam-modules to make this happen instead of
53 using libpam-mklocaluser. A setup for pam-auth-update to enable
54 pam_mkhomedir will have to be written until a fix for
55 <a href=
"http://bugs.debian.org/568577">bug #
568577</a> is in the
56 archive. Because I believe it is a bad idea to have local home
57 directories using misleading paths like /site/server/partition/, I
58 prefer to create a local user with the home directory in /home/. This
59 is done using the libpam-mklocaluser package.
</p>
61 <p>These packages need to be installed and configured
</p>
64 libnss-ldapd libpam-ldapd nscd libpam-ccreds libpam-mklocaluser
67 <p>The ldapd packages will ask for LDAP connection information, and
68 one have to fill in the values that fits ones own site. Make sure the
69 PAM part uses encrypted connections, to make sure the password is not
70 sent in clear text to the LDAP server. I've been unable to get TLS
71 certificate checking for a self signed certificate working, which make
72 LDAP authentication unsafe for Debian Edu (nslcd is not checking if it
73 is talking to the correct LDAP server), and very much welcome feedback
74 on how to get this working.
</p>
76 <p>Because nscd do not have a default configuration fit for offline
77 caching until
<a href=
"http://bugs.debian.org/485282">bug #
485282</a>
78 is fixed, this configuration should be used instead of the one
79 currently in /etc/nscd.conf. The changes are in the fields
80 reload-count and positive-time-to-live, and is based on the
81 instructions I found in the
82 <a href=
"http://www.flyn.org/laptopldap/">LDAP for Mobile Laptops
</a>
83 instructions by Flyn Computing.
</p>
87 reload-count unlimited
90 enable-cache passwd yes
91 positive-time-to-live passwd
2592000
92 negative-time-to-live passwd
20
93 suggested-size passwd
211
94 check-files passwd yes
97 max-db-size passwd
33554432
98 auto-propagate passwd yes
100 enable-cache group yes
101 positive-time-to-live group
2592000
102 negative-time-to-live group
20
103 suggested-size group
211
104 check-files group yes
107 max-db-size group
33554432
108 auto-propagate group yes
110 enable-cache hosts no
111 positive-time-to-live hosts
2592000
112 negative-time-to-live hosts
20
113 suggested-size hosts
211
114 check-files hosts yes
117 max-db-size hosts
33554432
119 enable-cache services yes
120 positive-time-to-live services
2592000
121 negative-time-to-live services
20
122 suggested-size services
211
123 check-files services yes
124 persistent services yes
126 max-db-size services
33554432
129 <p>While we wait for a mechanism to update /etc/nsswitch.conf
130 automatically like the one provided in
131 <a href=
"http://bugs.debian.org/496915">bug #
496915</a>, the file
132 content need to be manually replaced to ensure LDAP is used as the
133 directory service on the machine. /etc/nsswitch.conf should normally
140 hosts: files mdns4_minimal [NOTFOUND=return] dns mdns4
149 <p>The important parts are that ldap is listed last for passwd, group,
150 shadow and netgroup.
</p>
152 <p>With these changes in place, any user in LDAP will be able to log
153 in locally on the machine using for example kdm, get a local home
154 directory created and have the password as well as user and group
157 <h2>LDAP/Kerberos + nss-updatedb + libpam-ccreds +
158 libpam-mklocaluser/pam_mkhomedir
</h2>
160 <p>Because nscd have had its share of problems, and seem to have
161 problems doing proper caching, I've seen suggestions and recipes to
162 use nss-updatedb to copy parts of the LDAP database locally when the
163 LDAP database is available. I have not tested such setup, because I
166 <h2>LDAP/Kerberos + sssd + libpam-mklocaluser
</h2>
168 <p>A more flexible and robust setup than the nscd combination
169 mentioned earlier that has shown up recently, is the
170 <a href=
"https://fedorahosted.org/sssd/">sssd
</a> package from Redhat.
171 It is part of the
<a href=
"http://www.freeipa.org/">FreeIPA
</A> project
172 to provide a Active Directory like directory service for Linux
173 machines. The sssd system combines the caching of passwords and user
174 information into one package, and remove the need for nscd and
175 libpam-ccreds. It support LDAP and Kerberos, but not NIS. Version
176 1.2 do not support netgroups, but it is said that it will support this
177 in version
1.5 expected to show up later in
2010. Because the
178 <a href=
"http://packages.qa.debian.org/s/sssd.html">sssd package
</a>
179 was missing in Debian, I ended up co-maintaining it with Werner, and
180 version
1.2 is now in testing.
182 <p>These packages need to be installed and configured to get the
183 roaming setup I want
</p>
186 libpam-sss libnss-sss libpam-mklocaluser
189 The complete setup of sssd is done by editing/creating
190 <tt>/etc/sssd/sssd.conf
</tt>.
194 config_file_version =
2
195 reconnection_retries =
3
203 reconnection_retries =
3
206 reconnection_retries =
3
210 cache_credentials = true
214 chpass_provider = ldap
216 ldap_uri = ldap://ldap
217 ldap_search_base = dc=skole,dc=skolelinux,dc=no
218 ldap_tls_reqcert = never
219 ldap_tls_cacert = /etc/ssl/certs/ca-certificates.crt
222 <p>I got the same problem here with certificate checking. Had to set
223 "ldap_tls_reqcert = never" to get it working.
</p>
225 <p>With the libnss-sss package in testing at the moment, the
226 nsswitch.conf file is update automatically, so there is no need to
227 modify it manually.
</p>
229 <p>If you want to help out with implementing this for Debian Edu,
230 please contact us on debian-edu@lists.debian.org.
</p>
237 Tags:
<a href=
"http://people.skolelinux.org/pere/blog/tags/debian edu">debian edu
</a>,
<a href=
"http://people.skolelinux.org/pere/blog/tags/english">english
</a>,
<a href=
"http://people.skolelinux.org/pere/blog/tags/ldap">ldap
</a>,
<a href=
"http://people.skolelinux.org/pere/blog/tags/nuug">nuug
</a>.
241 <div class=
"padding"></div>
245 <a href=
"http://people.skolelinux.org/pere/blog/Lenny__Squeeze_upgrades__apt_vs_aptitude_with_the_Gnome_desktop.html">Lenny-
>Squeeze upgrades, apt vs aptitude with the Gnome desktop
</a>
253 <p>Here is a short update on my
<a
254 href=
"http://people.skolelinux.org/~pere/debian-upgrade-testing/">my
255 Debian Lenny-
>Squeeze upgrade testing
</a>. Here is a summary of the
256 difference for Gnome when it is upgraded by apt-get and aptitude. I'm
257 not reporting the status for KDE, because the upgrade crashes when
258 aptitude try because of missing conflicts
259 (
<a href=
"http://bugs.debian.org/584861">#
584861</a> and
260 <a href=
"http://bugs.debian.org/585716">#
585716</a>).
</p>
262 <p>At the end of the upgrade test script, dpkg -l is executed to get a
263 complete list of the installed packages. Based on this I see these
264 differences when I did a test run today. As usual, I do not really
265 know what the correct set of packages would be, but thought it best to
266 publish the difference.
</p>
268 <p>Installed using apt-get, missing with aptitude
</p>
271 at-spi cpp-
4.3 finger gnome-spell gstreamer0.10-gnomevfs
272 libatspi1.0-
0 libcupsys2 libeel2-data libgail-common libgdl-
1-common
273 libgnomeprint2.2-data libgnomeprintui2.2-common libgnomevfs2-bin
274 libgtksourceview-common libpt-
1.10.10-plugins-alsa
275 libpt-
1.10.10-plugins-v4l libservlet2.4-java libxalan2-java
276 libxerces2-java openoffice.org-writer2latex openssl-blacklist p7zip
277 python-
4suite-xml python-eggtrayicon python-gtkhtml2
278 python-gtkmozembed svgalibg1 xserver-xephyr zip
281 <p>Installed using apt-get, removed with aptitude
</p>
284 bluez-utils dhcdbd djvulibre-desktop epiphany-gecko
285 gnome-app-install gnome-mount gnome-vfs-obexftp gnome-volume-manager
286 libao2 libavahi-compat-libdnssd1 libavahi-core5 libbind9-
50
287 libbluetooth2 libcamel1.2-
11 libcdio7 libcucul0 libcurl3
288 libdirectfb-
1.0-
0 libdvdread3 libedata-cal1.2-
6 libedataserver1.2-
9
289 libeel2-
2.20 libepc-
1.0-
1 libepc-ui-
1.0-
1 libexchange-storage1.2-
3
290 libfaad0 libgd2-noxpm libgda3-
3 libgda3-common libggz2 libggzcore9
291 libggzmod4 libgksu1.2-
0 libgksuui1.0-
1 libgmyth0 libgnome-desktop-
2
292 libgnome-pilot2 libgnomecups1.0-
1 libgnomeprint2.2-
0
293 libgnomeprintui2.2-
0 libgpod3 libgraphviz4 libgtkhtml2-
0
294 libgtksourceview1.0-
0 libgucharmap6 libhesiod0 libicu38 libisccc50
295 libisccfg50 libiw29 libkpathsea4 libltdl3 liblwres50 libmagick++
10
296 libmagick10 libmalaga7 libmtp7 libmysqlclient15off libnautilus-burn4
297 libneon27 libnm-glib0 libnm-util0 libopal-
2.2 libosp5
298 libparted1.8-
10 libpisock9 libpisync1 libpoppler-glib3 libpoppler3
299 libpt-
1.10.10 libraw1394-
8 libsensors3 libsmbios2 libsoup2.2-
8
300 libssh2-
1 libsuitesparse-
3.1.0 libswfdec-
0.6-
90 libtalloc1
301 libtotem-plparser10 libtrackerclient0 libvoikko1 libxalan2-java-gcj
302 libxerces2-java-gcj libxklavier12 libxtrap6 libxxf86misc1 libzephyr3
303 mysql-common swfdec-gnome totem-gstreamer wodim
306 <p>Installed using aptitude, missing with apt-get
</p>
309 gnome gnome-desktop-environment hamster-applet python-gnomeapplet
310 python-gnomekeyring python-wnck rhythmbox-plugins xorg
311 xserver-xorg-input-all xserver-xorg-input-evdev
312 xserver-xorg-input-kbd xserver-xorg-input-mouse
313 xserver-xorg-input-synaptics xserver-xorg-video-all
314 xserver-xorg-video-apm xserver-xorg-video-ark xserver-xorg-video-ati
315 xserver-xorg-video-chips xserver-xorg-video-cirrus
316 xserver-xorg-video-dummy xserver-xorg-video-fbdev
317 xserver-xorg-video-glint xserver-xorg-video-i128
318 xserver-xorg-video-i740 xserver-xorg-video-mach64
319 xserver-xorg-video-mga xserver-xorg-video-neomagic
320 xserver-xorg-video-nouveau xserver-xorg-video-nv
321 xserver-xorg-video-r128 xserver-xorg-video-radeon
322 xserver-xorg-video-radeonhd xserver-xorg-video-rendition
323 xserver-xorg-video-s3 xserver-xorg-video-s3virge
324 xserver-xorg-video-savage xserver-xorg-video-siliconmotion
325 xserver-xorg-video-sis xserver-xorg-video-sisusb
326 xserver-xorg-video-tdfx xserver-xorg-video-tga
327 xserver-xorg-video-trident xserver-xorg-video-tseng
328 xserver-xorg-video-vesa xserver-xorg-video-vmware
329 xserver-xorg-video-voodoo
332 <p>Installed using aptitude, removed with apt-get
</p>
335 deskbar-applet xserver-xorg xserver-xorg-core
336 xserver-xorg-input-wacom xserver-xorg-video-intel
337 xserver-xorg-video-openchrome
340 <p>I was told on IRC that the xorg-xserver package was
341 <a href=
"http://git.debian.org/?p=pkg-xorg/xserver/xorg-server.git;a=commit;h=9c8080d06c457932d3bfec021c69ac000aa60120">changed
342 in git
</a> today to try to get apt-get to not remove xorg completely.
343 No idea when it hits Squeeze, but when it does I hope it will reduce
344 the difference somewhat.
351 Tags:
<a href=
"http://people.skolelinux.org/pere/blog/tags/debian">debian
</a>,
<a href=
"http://people.skolelinux.org/pere/blog/tags/debian edu">debian edu
</a>,
<a href=
"http://people.skolelinux.org/pere/blog/tags/english">english
</a>.
355 <div class=
"padding"></div>
359 <a href=
"http://people.skolelinux.org/pere/blog/MS_Word_kr__ller_det_til_for_politiet_.html">MS Word krøller det til for politiet?
</a>
367 <p>De siste dagene har Aftenposten
368 <a href=
"http://www.aftenposten.no/nyheter/iriks/article3718597.ece">fortalt
</a>
369 <a href=
"http://www.aftenposten.no/nyheter/iriks/article3724249.ece">hvordan
</a>
370 politet har brukt skriveverktøy som ikke håndterer arabisk tekst og
371 tekst som skal skrives fra høyre mot venstre når de har laget
372 løpeseddel for å be om informasjon fra publikum. Resultatet har vært
373 en uleselig arabisk-bit på løpeseddelen. Feilen har oppstått når
374 teksten har blitt "kopiert inn i programvare som ikke har støtte for
375 språk som skrives fra høyre mot venstre", og jeg er ganske sikker på
376 at det er snakk om Microsoft Office i dette tilfellet. Er det slik at
377 MS Office i norsk språkdrakt ikke har støtte for tekst som skal
378 skrives fra høyre mot venstre? Jeg tror alle utgaver av
379 OpenOffice.org har slik støtte, og det er jo ikke veldig vanskelig å
380 la slik støtte finnes i alle utgaver av et program hvis støtten først
381 er utviklet. Aftenpostens melding får meg til å undre om problemet
382 ville vært unngått hvis politiet brukte OpenOffice.org i stedet for MS
385 <p>Mon tro om det er flere eksempler på at MS Office har ødelagt for
386 offentlig myndighet?
</p>
393 Tags:
<a href=
"http://people.skolelinux.org/pere/blog/tags/norsk">norsk
</a>.
397 <div class=
"padding"></div>
399 <p style=
"text-align: right;"><a href=
"07.rss"><img src=
"http://people.skolelinux.org/pere/blog/xml.gif" alt=
"RSS Feed" width=
"36" height=
"14"></a></p>
411 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2010/01/">January (
2)
</a></li>
413 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2010/02/">February (
1)
</a></li>
415 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2010/03/">March (
3)
</a></li>
417 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2010/04/">April (
3)
</a></li>
419 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2010/05/">May (
9)
</a></li>
421 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2010/06/">June (
14)
</a></li>
423 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2010/07/">July (
3)
</a></li>
430 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2009/01/">January (
8)
</a></li>
432 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2009/02/">February (
8)
</a></li>
434 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2009/03/">March (
12)
</a></li>
436 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2009/04/">April (
10)
</a></li>
438 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2009/05/">May (
9)
</a></li>
440 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2009/06/">June (
3)
</a></li>
442 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2009/07/">July (
4)
</a></li>
444 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2009/08/">August (
3)
</a></li>
446 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2009/09/">September (
1)
</a></li>
448 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2009/10/">October (
2)
</a></li>
450 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2009/11/">November (
3)
</a></li>
452 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2009/12/">December (
3)
</a></li>
459 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2008/11/">November (
5)
</a></li>
461 <li><a href=
"http://people.skolelinux.org/pere/blog/archive/2008/12/">December (
7)
</a></li>
472 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/3d-printer">3d-printer (
11)
</a></li>
474 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/amiga">amiga (
1)
</a></li>
476 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/aros">aros (
1)
</a></li>
478 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/bootsystem">bootsystem (
10)
</a></li>
480 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/debian">debian (
30)
</a></li>
482 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/debian edu">debian edu (
30)
</a></li>
484 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/english">english (
43)
</a></li>
486 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/fiksgatami">fiksgatami (
1)
</a></li>
488 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/fildeling">fildeling (
7)
</a></li>
490 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/kart">kart (
2)
</a></li>
492 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/ldap">ldap (
4)
</a></li>
494 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/lenker">lenker (
1)
</a></li>
496 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/ltsp">ltsp (
1)
</a></li>
498 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/multimedia">multimedia (
5)
</a></li>
500 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/norsk">norsk (
70)
</a></li>
502 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/nuug">nuug (
80)
</a></li>
504 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/opphavsrett">opphavsrett (
13)
</a></li>
506 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/personvern">personvern (
13)
</a></li>
508 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/reprap">reprap (
10)
</a></li>
510 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/rss">rss (
1)
</a></li>
512 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/sikkerhet">sikkerhet (
9)
</a></li>
514 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/sitesummary">sitesummary (
3)
</a></li>
516 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/standard">standard (
13)
</a></li>
518 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/stavekontroll">stavekontroll (
1)
</a></li>
520 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/video">video (
10)
</a></li>
522 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/vitenskap">vitenskap (
1)
</a></li>
524 <li><a href=
"http://people.skolelinux.org/pere/blog/tags/web">web (
6)
</a></li>