1 <?xml version=
"1.0" encoding=
"utf-8"?>
2 <rss version='
2.0' xmlns:lj='http://www.livejournal.org/rss/lj/
1.0/' xmlns:
atom=
"http://www.w3.org/2005/Atom">
4 <title>Petter Reinholdtsen
</title>
5 <description></description>
6 <link>http://people.skolelinux.org/pere/blog/
</link>
7 <atom:link href=
"http://people.skolelinux.org/pere/blog/index.rss" rel=
"self" type=
"application/rss+xml" />
10 <title>From English wiki to translated PDF and epub via Docbook
</title>
11 <link>http://people.skolelinux.org/pere/blog/From_English_wiki_to_translated_PDF_and_epub_via_Docbook.html
</link>
12 <guid isPermaLink=
"true">http://people.skolelinux.org/pere/blog/From_English_wiki_to_translated_PDF_and_epub_via_Docbook.html
</guid>
13 <pubDate>Tue,
17 Jun
2014 11:
30:
00 +
0200</pubDate>
14 <description><p
>The
<a href=
"http://www.skolelinux.org/
">Debian Edu / Skolelinux
15 project
</a
> provide an instruction manual for teachers, system
16 administrators and other users that contain useful tips for setting up
17 and maintaining a Debian Edu installation. This text is about how the
18 text processing of this manual is handled in the project.
</p
>
20 <p
>One goal of the project is to provide information in the native
21 language of its users, and for this we need to handle translations.
22 But we also want to make sure each language contain the same
23 information, so for this we need a good way to keep the translations
24 in sync. And we want it to be easy for our users to improve the
25 documentation, avoiding the need to learn special formats or tools to
26 contribute, and the obvious way to do this is to make it possible to
27 edit the documentation using a web browser. We also want it to be
28 easy for translators to keep the translation up to date, and give them
29 help in figuring out what need to be translated. Here is the list of
30 tools and the process we have found trying to reach all these
33 <p
>We maintain the authoritative source of our manual in the
34 <a href=
"https://wiki.debian.org/DebianEdu/Documentation/Wheezy/
">Debian
35 wiki
</a
>, as several wiki pages written in English. It consist of one
36 front page with references to the different chapters, several pages
37 for each chapter, and finally one
"collection page
" gluing all the
38 chapters together into one large web page (aka
39 <a href=
"https://wiki.debian.org/DebianEdu/Documentation/Wheezy/AllInOne
">the
40 AllInOne page
</a
>). The AllInOne page is the one used for further
41 processing and translations. Thanks to the fact that the
42 <a href=
"http://moinmo.in/
">MoinMoin
</a
> installation on
43 wiki.debian.org support exporting pages in
44 <a href=
"http://www.docbook.org/
">the Docbook format
</a
>, we can fetch
45 the list of pages to export using the raw version of the AllInOne
46 page, loop over each of them to generate a Docbook XML version of the
47 manual. This process also download images and transform image
48 references to use the locally downloaded images. The generated
49 Docbook XML files are slightly broken, so some post-processing is done
50 using the
<tt
>documentation/scripts/get_manual
</tt
> program, and the
51 result is a nice Docbook XML file (debian-edu-wheezy-manual.xml) and
52 a handfull of images. The XML file can now be used to generate PDF, HTML
53 and epub versions of the English manual. This is the basic step of
54 our process, making PDF (using dblatex), HTML (using xsltproc) and
55 epub (using dbtoepub) version from Docbook XML, and the resulting files
56 are placed in the debian-edu-doc-en binary package.
</p
>
58 <p
>But English documentation is not enough for us. We want translated
59 documentation too, and we want to make it easy for translators to
60 track the English original. For this we use the
61 <a href=
"http://packages.qa.debian.org/p/poxml.html
">poxml
</a
> package,
62 which allow us to transform the English Docbook XML file into a
63 translation file (a .pot file), usable with the normal gettext based
64 translation tools used by those translating free software. The pot
65 file is used to create and maintain translation files (several .po
66 files), which the translations update with the native language
67 translations of all titles, paragraphs and blocks of text in the
68 original. The next step is combining the original English Docbook XML
69 and the translation file (say debian-edu-wheezy-manual.nb.po), to
70 create a translated Docbook XML file (in this case
71 debian-edu-wheezy-manual.nb.xml). This translated (or partly
72 translated, if the translation is not complete) Docbook XML file can
73 then be used like the original to create a PDF, HTML and epub version
74 of the documentation.
</p
>
76 <p
>The translators use different tools to edit the .po files. We
78 <a href=
"http://www.kde.org/applications/development/lokalize/
">lokalize
</a
>,
79 while some use emacs and vi, others can use web based editors like
80 <a href=
"http://pootle.translatehouse.org/
">Poodle
</a
> or
81 <a href=
"https://www.transifex.com/
">Transifex
</a
>. All we care about
82 is where the .po file end up, in our git repository. Updated
83 translations can either be committed directly to git, or submitted as
84 <a href=
"https://bugs.debian.org/src:debian-edu-doc
">bug reports
85 against the debian-edu-doc package
</a
>.
</p
>
87 <p
>One challenge is images, which both might need to be translated (if
88 they show translated user applications), and are needed in different
89 formats when creating PDF and HTML versions (epub is a HTML version in
90 this regard). For this we transform the original PNG images to the
91 needed density and format during build, and have a way to provide
92 translated images by storing translated versions in
93 images/$LANGUAGECODE/. I am a bit unsure about the details here. The
94 package maintainers know more.
</p
>
96 <p
>If you wonder what the result look like, we provide
97 <a href=
"http://maintainer.skolelinux.org/debian-edu-doc/
">the content
98 of the documentation packages on the web
</a
>. See for example the
99 <a href=
"http://maintainer.skolelinux.org/debian-edu-doc/it/debian-edu-wheezy-manual.pdf
">Italian
100 PDF version
</a
> or the
101 <a href=
"http://maintainer.skolelinux.org/debian-edu-doc/de/debian-edu-wheezy-manual.html
">German
102 HTML version
</a
>. We do not yet build the epub version by default,
103 but perhaps it will be done in the future.
</p
>
105 <p
>To learn more, check out
106 <a href=
"http://packages.qa.debian.org/d/debian-edu-doc.html
">the
107 debian-edu-doc package
</a
>,
108 <a href=
"https://wiki.debian.org/DebianEdu/Documentation/Wheezy/
">the
109 manual on the wiki
</a
> and
110 <a href=
"https://wiki.debian.org/DebianEdu/Documentation/Wheezy/Translations
">the
111 translation instructions
</a
> in the manual.
</p
>
116 <title>Hvordan enkelt laste ned filmer fra NRK med den
"nye
" løsningen
</title>
117 <link>http://people.skolelinux.org/pere/blog/Hvordan_enkelt_laste_ned_filmer_fra_NRK_med_den__nye__l_sningen.html
</link>
118 <guid isPermaLink=
"true">http://people.skolelinux.org/pere/blog/Hvordan_enkelt_laste_ned_filmer_fra_NRK_med_den__nye__l_sningen.html
</guid>
119 <pubDate>Mon,
16 Jun
2014 19:
20:
00 +
0200</pubDate>
120 <description><p
>Jeg har fortsatt behov for å kunne laste ned innslag fra NRKs
121 nettsted av og til for å se senere når jeg ikke er på nett, men
122 <a href=
"http://people.skolelinux.org/pere/blog/Hvordan_enkelt_laste_ned_filmer_fra_NRK.html
">min
123 oppskrift fra
2011</a
> sluttet å fungere da NRK byttet
124 avspillermetode. I dag fikk jeg endelig lett etter oppdatert løsning,
125 og jeg er veldig glad for å fortelle at den enkleste måten å laste ned
126 innslag er å bruke siste versjon
2014.06.07 av
127 <a href=
"http://rg3.github.io/youtube-dl/
">youtube-dl
</a
>. Støtten i
128 youtube-dl
<a href=
"https://github.com/rg3/youtube-dl/issues/
2980">kom
129 inn for
23 dager siden
</a
> og
130 <a href=
"http://packages.qa.debian.org/y/youtube-dl.html
">versjonen i
131 Debian
</a
> fungerer fint også som backport til Debian Wheezy. Det er
132 et lite problem, det håndterer kun URLer med små bokstaver, men hvis
133 en har en URL med store bokstaver kan en bare gjøre alle store om til
134 små bokstaver for å få youtube-dl til å laste ned. Rapporterte
136 <a href=
"https://github.com/rg3/youtube-dl/issues/
2980">problemet til
137 utviklerne
</a
>, og antar de får fikset det snart.
</p
>
139 <p
>Dermed er alt klart til å laste ned dokumentarene om
140 <a href=
"http://tv.nrk.no/program/KOID23005014/usas-hemmelige-avlytting
">USAs
141 hemmelige avlytting
</a
> og
142 <a href=
"http://tv.nrk.no/program/KOID23005114/selskapene-bak-usas-avlytting
">Selskapene
143 bak USAs avlytting
</a
>, i tillegg til
144 <a href=
"http://tv.nrk.no/program/KOID20005814/et-moete-med-edward-snowden
">intervjuet
145 med Edward Snowden gjort av den tyske tv-kanalen ARD
</a
>. Anbefaler
146 alle å se disse, sammen med
147 <a href=
"http://media.ccc.de/browse/congress/
2013/
30C3_-_5713_-_en_-_saal_2_-_201312301130_-_to_protect_and_infect_part_2_-_jacob.html
">foredraget
148 til Jacob Appelbaum på siste CCC-konferanse
</a
>, for å forstå mer om
149 hvordan overvåkningen av borgerne brer om seg.
</p
>
151 <p
>Takk til gode venner på foreningen NUUGs IRC-kanal
152 <a href=
"irc://irc.freenode.net/%
23nuug
">#nuug på irc.freenode.net
</a
>
153 for tipsene som fikk meg i mål
</a
>.
</p
>
155 <p
><strong
>Oppdatering
2014-
06-
17</strong
>: Etter at jeg publiserte
156 denne, ble jeg tipset om bloggposten
157 "<a href=
"http://ingvar.blog.redpill-linpro.com/
2012/
05/
31/downloading-hd-content-from-tv-nrk-no/
">Downloading
158 HD content from tv.nrk.no
</a
>" av Ingvar Hagelund, som har alternativ
159 implementasjon og tips for å lage mkv-fil med undertekstene inkludert.
160 Kanskje den passer bedre for deg? I tillegg ble feilen i youtube-dl
161 ble fikset litt senere ut på dagen i går, samt at youtube-dl fikk
162 støtte for å laste ned undertitler. Takk til Anders Einar Hilden for
163 god innsats og youtube-dl-utviklerne for rask respons.
</p
>
168 <title>Free software car computer solution?
</title>
169 <link>http://people.skolelinux.org/pere/blog/Free_software_car_computer_solution_.html
</link>
170 <guid isPermaLink=
"true">http://people.skolelinux.org/pere/blog/Free_software_car_computer_solution_.html
</guid>
171 <pubDate>Thu,
29 May
2014 18:
45:
00 +
0200</pubDate>
172 <description><p
>Dear lazyweb. I
'm planning to set up a small Raspberry Pi computer
173 in my car, connected to
174 <a href=
"http://www.dx.com/p/
400a-
4-
0-tft-lcd-digital-monitor-for-vehicle-parking-reverse-camera-
1440x272-
12v-dc-
57776">a
175 small screen
</a
> next to the rear mirror. I plan to hook it up with a
176 GPS and a USB wifi card too. The idea is to get my own
177 "<a href=
"http://en.wikipedia.org/wiki/Carputer
">Carputer
</a
>". But I
178 wonder if someone already created a good free software solution for
179 such car computer.
</p
>
181 <p
>This is my current wish list for such system:
</p
>
185 <li
>Work on Raspberry Pi.
</li
>
187 <li
>Show current speed limit based on location, and warn if going too
188 fast (for example using color codes yellow and red on the screen,
189 or make a sound). This could be done either using either data from
190 <a href=
"http://www.openstreetmap.org/
">Openstreetmap
</a
> or OCR
191 info gathered from a dashboard camera.
</li
>
193 <li
>Track automatic toll road passes and their cost, show total spent
194 and make it possible to calculate toll costs for planned
197 <li
>Collect GPX tracks for use with OpenStreetMap.
</li
>
199 <li
>Automatically detect and use any wireless connection to connect
200 to home server. Try IP over DNS
201 (
<a href=
"http://dev.kryo.se/iodine/
">iodine
</a
>) or ICMP
202 (
<a href=
"http://code.gerade.org/hans/
">Hans
</a
>) if direct
203 connection do not work.
</li
>
205 <li
>Set up mesh network to talk to other cars with the same system,
206 or some standard car mesh protocol.
</li
>
208 <li
>Warn when approaching speed cameras and speed camera ranges
209 (speed calculated between two cameras).
</li
>
211 <li
>Suport dashboard/front facing camera to discover speed limits and
212 run OCR to track registration number of passing cars.
</li
>
216 <p
>If you know of any free software car computer system supporting
217 some or all of these features, please let me know.
</p
>
222 <title>Half the Coverity issues in Gnash fixed in the next release
</title>
223 <link>http://people.skolelinux.org/pere/blog/Half_the_Coverity_issues_in_Gnash_fixed_in_the_next_release.html
</link>
224 <guid isPermaLink=
"true">http://people.skolelinux.org/pere/blog/Half_the_Coverity_issues_in_Gnash_fixed_in_the_next_release.html
</guid>
225 <pubDate>Tue,
29 Apr
2014 14:
20:
00 +
0200</pubDate>
226 <description><p
>I
've been following
<a href=
"http://www.getgnash.org/
">the Gnash
227 project
</a
> for quite a while now. It is a free software
228 implementation of Adobe Flash, both a standalone player and a browser
229 plugin. Gnash implement support for the AVM1 format (and not the
230 newer AVM2 format - see
231 <a href=
"http://lightspark.github.io/
">Lightspark
</a
> for that one),
232 allowing several flash based sites to work. Thanks to the friendly
233 developers at Youtube, it also work with Youtube videos, because the
234 Javascript code at Youtube detect Gnash and serve a AVM1 player to
235 those users. :) Would be great if someone found time to implement AVM2
236 support, but it has not happened yet. If you install both Lightspark
237 and Gnash, Lightspark will invoke Gnash if it find a AVM1 flash file,
238 so you can get both handled as free software. Unfortunately,
239 Lightspark so far only implement a small subset of AVM2, and many
240 sites do not work yet.
</p
>
242 <p
>A few months ago, I started looking at
243 <a href=
"http://scan.coverity.com/
">Coverity
</a
>, the static source
244 checker used to find heaps and heaps of bugs in free software (thanks
245 to the donation of a scanning service to free software projects by the
246 company developing this non-free code checker), and Gnash was one of
247 the projects I decided to check out. Coverity is able to find lock
248 errors, memory errors, dead code and more. A few days ago they even
249 extended it to also be able to find the heartbleed bug in OpenSSL.
250 There are heaps of checks being done on the instrumented code, and the
251 amount of bogus warnings is quite low compared to the other static
252 code checkers I have tested over the years.
</p
>
254 <p
>Since a few weeks ago, I
've been working with the other Gnash
255 developers squashing bugs discovered by Coverity. I was quite happy
256 today when I checked the current status and saw that of the
777 issues
257 detected so far,
374 are marked as fixed. This make me confident that
258 the next Gnash release will be more stable and more dependable than
259 the previous one. Most of the reported issues were and are in the
260 test suite, but it also found a few in the rest of the code.
</p
>
262 <p
>If you want to help out, you find us on
263 <a href=
"https://lists.gnu.org/mailman/listinfo/gnash-dev
">the
264 gnash-dev mailing list
</a
> and on
265 <a href=
"irc://irc.freenode.net/#gnash
">the #gnash channel on
266 irc.freenode.net IRC server
</a
>.
</p
>
271 <title>Install hardware dependent packages using tasksel (Isenkram
0.7)
</title>
272 <link>http://people.skolelinux.org/pere/blog/Install_hardware_dependent_packages_using_tasksel__Isenkram_0_7_.html
</link>
273 <guid isPermaLink=
"true">http://people.skolelinux.org/pere/blog/Install_hardware_dependent_packages_using_tasksel__Isenkram_0_7_.html
</guid>
274 <pubDate>Wed,
23 Apr
2014 14:
50:
00 +
0200</pubDate>
275 <description><p
>It would be nice if it was easier in Debian to get all the hardware
276 related packages relevant for the computer installed automatically.
277 So I implemented one, using
278 <a href=
"http://packages.qa.debian.org/isenkram
">my Isenkram
279 package
</a
>. To use it, install the tasksel and isenkram packages and
280 run tasksel as user root. You should be presented with a new option,
281 "Hardware specific packages (autodetected by isenkram)
". When you
282 select it, tasksel will install the packages isenkram claim is fit for
283 the current hardware, hot pluggable or not.
<p
>
285 <p
>The implementation is in two files, one is the tasksel menu entry
286 description, and the other is the script used to extract the list of
287 packages to install. The first part is in
288 <tt
>/usr/share/tasksel/descs/isenkram.desc
</tt
> and look like
291 <p
><blockquote
><pre
>
294 Description: Hardware specific packages (autodetected by isenkram)
295 Based on the detected hardware various hardware specific packages are
297 Test-new-install: mark show
299 Packages: for-current-hardware
300 </pre
></blockquote
></p
>
302 <p
>The second part is in
303 <tt
>/usr/lib/tasksel/packages/for-current-hardware
</tt
> and look like
306 <p
><blockquote
><pre
>
311 isenkram-autoinstall-firmware -l
313 </pre
></blockquote
></p
>
315 <p
>All in all, a very short and simple implementation making it
316 trivial to install the hardware dependent package we all may want to
317 have installed on our machines. I
've not been able to find a way to
318 get tasksel to tell you exactly which packages it plan to install
319 before doing the installation. So if you are curious or careful,
320 check the output from the isenkram-* command line tools first.
</p
>
322 <p
>The information about which packages are handling which hardware is
323 fetched either from the isenkram package itself in
324 /usr/share/isenkram/, from git.debian.org or from the APT package
325 database (using the Modaliases header). The APT package database
326 parsing have caused a nasty resource leak in the isenkram daemon (bugs
327 <a href=
"http://bugs.debian.org/
719837">#
719837</a
> and
328 <a href=
"http://bugs.debian.org/
730704">#
730704</a
>). The cause is in
329 the python-apt code (bug
330 <a href=
"http://bugs.debian.org/
745487">#
745487</a
>), but using a
331 workaround I was able to get rid of the file descriptor leak and
332 reduce the memory leak from ~
30 MiB per hardware detection down to
333 around
2 MiB per hardware detection. It should make the desktop
334 daemon a lot more useful. The fix is in version
0.7 uploaded to
335 unstable today.
</p
>
337 <p
>I believe the current way of mapping hardware to packages in
338 Isenkram is is a good draft, but in the future I expect isenkram to
339 use the AppStream data source for this. A proposal for getting proper
340 AppStream support into Debian is floating around as
341 <a href=
"https://wiki.debian.org/DEP-
11">DEP-
11</a
>, and
342 <a href=
"https://wiki.debian.org/SummerOfCode2014/Projects#SummerOfCode2014.2FProjects
.2FAppStreamDEP11Implementation.AppStream
.2FDEP-
11_for_the_Debian_Archive
">GSoC
343 project
</a
> will take place this summer to improve the situation. I
344 look forward to seeing the result, and welcome patches for isenkram to
345 start using the information when it is ready.
</p
>
347 <p
>If you want your package to map to some specific hardware, either
348 add a
"Xb-Modaliases
" header to your control file like I did in
349 <a href=
"http://packages.qa.debian.org/pymissile
">the pymissile
350 package
</a
> or submit a bug report with the details to the isenkram
352 <a href=
"http://people.skolelinux.org/pere/blog/tags/isenkram/
">all my
353 blog posts tagged isenkram
</a
> for details on the notation. I expect
354 the information will be migrated to AppStream eventually, but for the
355 moment I got no better place to store it.
</p
>
360 <title>FreedomBox milestone - all packages now in Debian Sid
</title>
361 <link>http://people.skolelinux.org/pere/blog/FreedomBox_milestone___all_packages_now_in_Debian_Sid.html
</link>
362 <guid isPermaLink=
"true">http://people.skolelinux.org/pere/blog/FreedomBox_milestone___all_packages_now_in_Debian_Sid.html
</guid>
363 <pubDate>Tue,
15 Apr
2014 22:
10:
00 +
0200</pubDate>
364 <description><p
>The
<a href=
"https://wiki.debian.org/FreedomBox
">Freedombox
365 project
</a
> is working on providing the software and hardware to make
366 it easy for non-technical people to host their data and communication
367 at home, and being able to communicate with their friends and family
368 encrypted and away from prying eyes. It is still going strong, and
369 today a major mile stone was reached.
</p
>
371 <p
>Today, the last of the packages currently used by the project to
372 created the system images were accepted into Debian Unstable. It was
373 the freedombox-setup package, which is used to configure the images
374 during build and on the first boot. Now all one need to get going is
375 the build code from the freedom-maker git repository and packages from
376 Debian. And once the freedombox-setup package enter testing, we can
377 build everything directly from Debian. :)
</p
>
379 <p
>Some key packages used by Freedombox are
380 <a href=
"http://packages.qa.debian.org/freedombox-setup
">freedombox-setup
</a
>,
381 <a href=
"http://packages.qa.debian.org/plinth
">plinth
</a
>,
382 <a href=
"http://packages.qa.debian.org/pagekite
">pagekite
</a
>,
383 <a href=
"http://packages.qa.debian.org/tor
">tor
</a
>,
384 <a href=
"http://packages.qa.debian.org/privoxy
">privoxy
</a
>,
385 <a href=
"http://packages.qa.debian.org/owncloud
">owncloud
</a
> and
386 <a href=
"http://packages.qa.debian.org/dnsmasq
">dnsmasq
</a
>. There
387 are plans to integrate more packages into the setup. User
388 documentation is maintained on the Debian wiki. Please
389 <a href=
"https://wiki.debian.org/FreedomBox/Manual/Jessie
">check out
390 the manual
</a
> and help us improve it.
</p
>
392 <p
>To test for yourself and create boot images with the FreedomBox
393 setup, run this on a Debian machine using a user with sudo rights to
394 become root:
</p
>
397 sudo apt-get install git vmdebootstrap mercurial python-docutils \
398 mktorrent extlinux virtualbox qemu-user-static binfmt-support \
400 git clone http://anonscm.debian.org/git/freedombox/freedom-maker.git \
402 make -C freedom-maker dreamplug-image raspberry-image virtualbox-image
403 </pre
></p
>
405 <p
>Root access is needed to run debootstrap and mount loopback
406 devices. See the README in the freedom-maker git repo for more
407 details on the build. If you do not want all three images, trim the
408 make line. Note that the virtualbox-image target is not really
409 virtualbox specific. It create a x86 image usable in kvm, qemu,
410 vmware and any other x86 virtual machine environment. You might need
411 the version of vmdebootstrap in Jessie to get the build working, as it
412 include fixes for a race condition with kpartx.
</p
>
414 <p
>If you instead want to install using a Debian CD and the preseed
415 method, boot a Debian Wheezy ISO and use this boot argument to load
416 the preseed values:
</p
>
419 url=
<a href=
"http://www.reinholdtsen.name/freedombox/preseed-jessie.dat
">http://www.reinholdtsen.name/freedombox/preseed-jessie.dat
</a
>
420 </pre
></p
>
422 <p
>I have not tested it myself the last few weeks, so I do not know if
423 it still work.
</p
>
425 <p
>If you wonder how to help, one task you could look at is using
426 systemd as the boot system. It will become the default for Linux in
427 Jessie, so we need to make sure it is usable on the Freedombox. I did
428 a simple test a few weeks ago, and noticed dnsmasq failed to start
429 during boot when using systemd. I suspect there are other problems
430 too. :) To detect problems, there is a test suite included, which can
431 be run from the plinth web interface.
</p
>
433 <p
>Give it a go and let us know how it goes on the mailing list, and help
434 us get the new release published. :) Please join us on
435 <a href=
"irc://irc.debian.org:
6667/%
23freedombox
">IRC (#freedombox on
436 irc.debian.org)
</a
> and
437 <a href=
"http://lists.alioth.debian.org/mailman/listinfo/freedombox-discuss
">the
438 mailing list
</a
> if you want to help make this vision come true.
</p
>
443 <title>Språkkoder for POSIX locale i Norge
</title>
444 <link>http://people.skolelinux.org/pere/blog/Spr_kkoder_for_POSIX_locale_i_Norge.html
</link>
445 <guid isPermaLink=
"true">http://people.skolelinux.org/pere/blog/Spr_kkoder_for_POSIX_locale_i_Norge.html
</guid>
446 <pubDate>Fri,
11 Apr
2014 21:
30:
00 +
0200</pubDate>
447 <description><p
>For
12 år siden, skrev jeg et lite notat om
448 <a href=
"http://i18n.skolelinux.no/localekoder.txt
">bruk av språkkoder
449 i Norge
</a
>. Jeg ble nettopp minnet på dette da jeg fikk spørsmål om
450 notatet fortsatt var aktuelt, og tenkte det var greit å repetere hva
451 som fortsatt gjelder. Det jeg skrev da er fortsatt like aktuelt.
</p
>
453 <p
>Når en velger språk i programmer på unix, så velger en blant mange
454 språkkoder. For språk i Norge anbefales følgende språkkoder (anbefalt
455 locale i parantes):
</p
>
458 <dt
>nb (nb_NO)
</dt
><dd
>Bokmål i Norge
</dd
>
459 <dt
>nn (nn_NO)
</dt
><dd
>Nynorsk i Norge
</dd
>
460 <dt
>se (se_NO)
</dt
><dd
>Nordsamisk i Norge
</dd
>
461 </dl
></p
>
463 <p
>Alle programmer som bruker andre koder bør endres.
</p
>
465 <p
>Språkkoden bør brukes når .po-filer navngis og installeres. Dette
466 er ikke det samme som locale-koden. For Norsk Bokmål, så bør filene
467 være navngitt nb.po, mens locale (LANG) bør være nb_NO.
</p
>
469 <p
>Hvis vi ikke får standardisert de kodene i alle programmene med
470 norske oversettelser, så er det umulig å gi LANG-variablen ett innhold
471 som fungerer for alle programmer.
</p
>
473 <p
>Språkkodene er de offisielle kodene fra ISO
639, og bruken av dem i
474 forbindelse med POSIX localer er standardisert i RFC
3066 og ISO
475 15897. Denne anbefalingen er i tråd med de angitte standardene.
</p
>
477 <p
>Følgende koder er eller har vært i bruk som locale-verdier for
478 "norske
" språk. Disse bør unngås, og erstattes når de oppdages:
</p
>
480 <p
><table
>
481 <tr
><td
>norwegian
</td
><td
>-
> nb_NO
</td
></tr
>
482 <tr
><td
>bokmål
</td
><td
>-
> nb_NO
</td
></tr
>
483 <tr
><td
>bokmal
</td
><td
>-
> nb_NO
</td
></tr
>
484 <tr
><td
>nynorsk
</td
><td
>-
> nn_NO
</td
></tr
>
485 <tr
><td
>no
</td
><td
>-
> nb_NO
</td
></tr
>
486 <tr
><td
>no_NO
</td
><td
>-
> nb_NO
</td
></tr
>
487 <tr
><td
>no_NY
</td
><td
>-
> nn_NO
</td
></tr
>
488 <tr
><td
>sme_NO
</td
><td
>-
> se_NO
</td
></tr
>
489 </table
></p
>
491 <p
>Merk at når det gjelder de samiske språkene, at se_NO i praksis
492 henviser til nordsamisk i Norge, mens f.eks. smj_NO henviser til
493 lulesamisk. Dette notatet er dog ikke ment å gi råd rundt samiske
495 <a href=
"http://www.divvun.no/
">Divvun-prosjektet
</a
> en bedre
498 <p
><strong
>Referanser:
</strong
></p
>
502 <li
><a href=
"http://www.rfc-base.org/rfc-
3066.html
">RFC
3066 - Tags
503 for the Identification of Languages
</a
> (Erstatter RFC
1766)
</li
>
505 <li
><a href=
"http://www.loc.gov/standards/iso639-
2/langcodes.html
">ISO
506 639</a
> - Codes for the Representation of Names of Languages
</li
>
508 <li
><a href=
"http://std.dkuug.dk/jtc1/sc22/wg20/docs/n897-
14652w25.pdf
">ISO
509 DTR
14652</a
> - locale-standard Specification method for cultural
510 conventions
</li
>
512 <li
><a href=
"http://std.dkuug.dk/jtc1/sc22/wg20/docs/n610.pdf
">ISO
513 15897: Registration procedures for cultural elements (cultural
515 <a href=
"http://std.dkuug.dk/jtc1/sc22/wg20/docs/n849-
15897wd6.pdf
">(nytt
516 draft)
</a
></li
>
518 <li
><a href=
"http://std.dkuug.dk/jtc1/sc22/wg20/
">ISO/IEC
519 JTC1/SC22/WG20
</a
> - Gruppen for i18n-standardisering i ISO
</li
>
526 <title>S3QL, a locally mounted cloud file system - nice free software
</title>
527 <link>http://people.skolelinux.org/pere/blog/S3QL__a_locally_mounted_cloud_file_system___nice_free_software.html
</link>
528 <guid isPermaLink=
"true">http://people.skolelinux.org/pere/blog/S3QL__a_locally_mounted_cloud_file_system___nice_free_software.html
</guid>
529 <pubDate>Wed,
9 Apr
2014 11:
30:
00 +
0200</pubDate>
530 <description><p
>For a while now, I have been looking for a sensible offsite backup
531 solution for use at home. My requirements are simple, it must be
532 cheap and locally encrypted (in other words, I keep the encryption
533 keys, the storage provider do not have access to my private files).
534 One idea me and my friends had many years ago, before the cloud
535 storage providers showed up, was to use Google mail as storage,
536 writing a Linux block device storing blocks as emails in the mail
537 service provided by Google, and thus get heaps of free space. On top
538 of this one can add encryption, RAID and volume management to have
539 lots of (fairly slow, I admit that) cheap and encrypted storage. But
540 I never found time to implement such system. But the last few weeks I
541 have looked at a system called
542 <a href=
"https://bitbucket.org/nikratio/s3ql/
">S3QL
</a
>, a locally
543 mounted network backed file system with the features I need.
</p
>
545 <p
>S3QL is a fuse file system with a local cache and cloud storage,
546 handling several different storage providers, any with Amazon S3,
547 Google Drive or OpenStack API. There are heaps of such storage
548 providers. S3QL can also use a local directory as storage, which
549 combined with sshfs allow for file storage on any ssh server. S3QL
550 include support for encryption, compression, de-duplication, snapshots
551 and immutable file systems, allowing me to mount the remote storage as
552 a local mount point, look at and use the files as if they were local,
553 while the content is stored in the cloud as well. This allow me to
554 have a backup that should survive fire. The file system can not be
555 shared between several machines at the same time, as only one can
556 mount it at the time, but any machine with the encryption key and
557 access to the storage service can mount it if it is unmounted.
</p
>
559 <p
>It is simple to use. I
'm using it on Debian Wheezy, where the
560 package is included already. So to get started, run
<tt
>apt-get
561 install s3ql
</tt
>. Next, pick a storage provider. I ended up picking
562 Greenqloud, after reading their nice recipe on
563 <a href=
"https://greenqloud.zendesk.com/entries/
44611757-How-To-Use-S3QL-to-mount-a-StorageQloud-bucket-on-Debian-Wheezy
">how
564 to use S3QL with their Amazon S3 service
</a
>, because I trust the laws
565 in Iceland more than those in USA when it come to keeping my personal
566 data safe and private, and thus would rather spend money on a company
567 in Iceland. Another nice recipe is available from the article
568 <a href=
"http://www.admin-magazine.com/HPC/Articles/HPC-Cloud-Storage
">S3QL
569 Filesystem for HPC Storage
</a
> by Jeff Layton in the HPC section of
570 Admin magazine. When the provider is picked, figure out how to get
571 the API key needed to connect to the storage API. With Greencloud,
572 the key did not show up until I had added payment details to my
575 <p
>Armed with the API access details, it is time to create the file
576 system. First, create a new bucket in the cloud. This bucket is the
577 file system storage area. I picked a bucket name reflecting the
578 machine that was going to store data there, but any name will do.
579 I
'll refer to it as
<tt
>bucket-name
</tt
> below. In addition, one need
580 the API login and password, and a locally created password. Store it
581 all in ~root/.s3ql/authinfo2 like this:
583 <p
><blockquote
><pre
>
585 storage-url: s3c://s.greenqloud.com:
443/bucket-name
586 backend-login: API-login
587 backend-password: API-password
588 fs-passphrase: local-password
589 </pre
></blockquote
></p
>
591 <p
>I create my local passphrase using
<tt
>pwget
50</tt
> or similar,
592 but any sensible way to create a fairly random password should do it.
593 Armed with these details, it is now time to run mkfs, entering the API
594 details and password to create it:
</p
>
596 <p
><blockquote
><pre
>
597 # mkdir -m
700 /var/lib/s3ql-cache
598 # mkfs.s3ql --cachedir /var/lib/s3ql-cache --authfile /root/.s3ql/authinfo2 \
599 --ssl s3c://s.greenqloud.com:
443/bucket-name
601 Enter backend password:
602 Before using S3QL, make sure to read the user
's guide, especially
603 the
'Important Rules to Avoid Loosing Data
' section.
604 Enter encryption password:
605 Confirm encryption password:
606 Generating random encryption key...
607 Creating metadata tables...
617 Compressing and uploading metadata...
618 Wrote
0.00 MB of compressed metadata.
619 #
</pre
></blockquote
></p
>
621 <p
>The next step is mounting the file system to make the storage available.
623 <p
><blockquote
><pre
>
624 # mount.s3ql --cachedir /var/lib/s3ql-cache --authfile /root/.s3ql/authinfo2 \
625 --ssl --allow-root s3c://s.greenqloud.com:
443/bucket-name /s3ql
626 Using
4 upload threads.
627 Downloading and decompressing metadata...
637 Mounting filesystem...
639 Filesystem Size Used Avail Use% Mounted on
640 s3c://s.greenqloud.com:
443/bucket-name
1.0T
0 1.0T
0% /s3ql
642 </pre
></blockquote
></p
>
644 <p
>The file system is now ready for use. I use rsync to store my
645 backups in it, and as the metadata used by rsync is downloaded at
646 mount time, no network traffic (and storage cost) is triggered by
647 running rsync. To unmount, one should not use the normal umount
648 command, as this will not flush the cache to the cloud storage, but
649 instead running the umount.s3ql command like this:
651 <p
><blockquote
><pre
>
654 </pre
></blockquote
></p
>
656 <p
>There is a fsck command available to check the file system and
657 correct any problems detected. This can be used if the local server
658 crashes while the file system is mounted, to reset the
"already
659 mounted
" flag. This is what it look like when processing a working
660 file system:
</p
>
662 <p
><blockquote
><pre
>
663 # fsck.s3ql --force --ssl s3c://s.greenqloud.com:
443/bucket-name
664 Using cached metadata.
665 File system seems clean, checking anyway.
666 Checking DB integrity...
667 Creating temporary extra indices...
668 Checking lost+found...
669 Checking cached objects...
670 Checking names (refcounts)...
671 Checking contents (names)...
672 Checking contents (inodes)...
673 Checking contents (parent inodes)...
674 Checking objects (reference counts)...
675 Checking objects (backend)...
676 ..processed
5000 objects so far..
677 ..processed
10000 objects so far..
678 ..processed
15000 objects so far..
679 Checking objects (sizes)...
680 Checking blocks (referenced objects)...
681 Checking blocks (refcounts)...
682 Checking inode-block mapping (blocks)...
683 Checking inode-block mapping (inodes)...
684 Checking inodes (refcounts)...
685 Checking inodes (sizes)...
686 Checking extended attributes (names)...
687 Checking extended attributes (inodes)...
688 Checking symlinks (inodes)...
689 Checking directory reachability...
690 Checking unix conventions...
691 Checking referential integrity...
692 Dropping temporary indices...
693 Backing up old metadata...
703 Compressing and uploading metadata...
704 Wrote
0.89 MB of compressed metadata.
706 </pre
></blockquote
></p
>
708 <p
>Thanks to the cache, working on files that fit in the cache is very
709 quick, about the same speed as local file access. Uploading large
710 amount of data is to me limited by the bandwidth out of and into my
711 house. Uploading
685 MiB with a
100 MiB cache gave me
305 kiB/s,
712 which is very close to my upload speed, and downloading the same
713 Debian installation ISO gave me
610 kiB/s, close to my download speed.
714 Both were measured using
<tt
>dd
</tt
>. So for me, the bottleneck is my
715 network, not the file system code. I do not know what a good cache
716 size would be, but suspect that the cache should e larger than your
717 working set.
</p
>
719 <p
>I mentioned that only one machine can mount the file system at the
720 time. If another machine try, it is told that the file system is
723 <p
><blockquote
><pre
>
724 # mount.s3ql --cachedir /var/lib/s3ql-cache --authfile /root/.s3ql/authinfo2 \
725 --ssl --allow-root s3c://s.greenqloud.com:
443/bucket-name /s3ql
726 Using
8 upload threads.
727 Backend reports that fs is still mounted elsewhere, aborting.
729 </pre
></blockquote
></p
>
731 <p
>The file content is uploaded when the cache is full, while the
732 metadata is uploaded once every
24 hour by default. To ensure the
733 file system content is flushed to the cloud, one can either umount the
734 file system, or ask S3QL to flush the cache and metadata using
737 <p
><blockquote
><pre
>
738 # s3qlctrl upload-meta /s3ql
739 # s3qlctrl flushcache /s3ql
741 </pre
></blockquote
></p
>
743 <p
>If you are curious about how much space your data uses in the
744 cloud, and how much compression and deduplication cut down on the
745 storage usage, you can use s3qlstat on the mounted file system to get
748 <p
><blockquote
><pre
>
750 Directory entries:
9141
753 Total data size:
22049.38 MB
754 After de-duplication:
21955.46 MB (
99.57% of total)
755 After compression:
21877.28 MB (
99.22% of total,
99.64% of de-duplicated)
756 Database size:
2.39 MB (uncompressed)
757 (some values do not take into account not-yet-uploaded dirty blocks in cache)
759 </pre
></blockquote
></p
>
761 <p
>I mentioned earlier that there are several possible suppliers of
762 storage. I did not try to locate them all, but am aware of at least
763 <a href=
"https://www.greenqloud.com/
">Greenqloud
</a
>,
764 <a href=
"http://drive.google.com/
">Google Drive
</a
>,
765 <a href=
"http://aws.amazon.com/s3/
">Amazon S3 web serivces
</a
>,
766 <a href=
"http://www.rackspace.com/
">Rackspace
</a
> and
767 <a href=
"http://crowncloud.net/
">Crowncloud
</A
>. The latter even
768 accept payment in Bitcoin. Pick one that suit your need. Some of
769 them provide several GiB of free storage, but the prize models are
770 quite different and you will have to figure out what suits you
773 <p
>While researching this blog post, I had a look at research papers
774 and posters discussing the S3QL file system. There are several, which
775 told me that the file system is getting a critical check by the
776 science community and increased my confidence in using it. One nice
778 "<a href=
"http://www.lanl.gov/orgs/adtsc/publications/science_highlights_2013/docs/pg68_69.pdf
">An
779 Innovative Parallel Cloud Storage System using OpenStack’s SwiftObject
780 Store and Transformative Parallel I/O Approach
</a
>" by Hsing-Bung
781 Chen, Benjamin McClelland, David Sherrill, Alfred Torrez, Parks Fields
782 and Pamela Smith. Please have a look.
</p
>
784 <p
>Given my problems with different file systems earlier, I decided to
785 check out the mounted S3QL file system to see if it would be usable as
786 a home directory (in other word, that it provided POSIX semantics when
787 it come to locking and umask handling etc). Running
788 <a href=
"http://people.skolelinux.org/pere/blog/Testing_if_a_file_system_can_be_used_for_home_directories___.html
">my
789 test code to check file system semantics
</a
>, I was happy to discover that
790 no error was found. So the file system can be used for home
791 directories, if one chooses to do so.
</p
>
793 <p
>If you do not want a locally file system, and want something that
794 work without the Linux fuse file system, I would like to mention the
795 <a href=
"http://www.tarsnap.com/
">Tarsnap service
</a
>, which also
796 provide locally encrypted backup using a command line client. It have
797 a nicer access control system, where one can split out read and write
798 access, allowing some systems to write to the backup and others to
799 only read from it.
</p
>
801 <p
>As usual, if you use Bitcoin and want to show your support of my
802 activities, please send Bitcoin donations to my address
803 <b
><a href=
"bitcoin:
15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b
&label=PetterReinholdtsenBlog
">15oWEoG9dUPovwmUL9KWAnYRtNJEkP1u1b
</a
></b
>.
</p
>
808 <title>EU-domstolen bekreftet i dag at datalagringsdirektivet er ulovlig
</title>
809 <link>http://people.skolelinux.org/pere/blog/EU_domstolen_bekreftet_i_dag_at_datalagringsdirektivet_er_ulovlig.html
</link>
810 <guid isPermaLink=
"true">http://people.skolelinux.org/pere/blog/EU_domstolen_bekreftet_i_dag_at_datalagringsdirektivet_er_ulovlig.html
</guid>
811 <pubDate>Tue,
8 Apr
2014 11:
30:
00 +
0200</pubDate>
812 <description><p
>I dag kom endelig avgjørelsen fra EU-domstolen om
813 datalagringsdirektivet, som ikke overraskende ble dømt ulovlig og i
814 strid med borgernes grunnleggende rettigheter. Hvis du lurer på hva
815 datalagringsdirektivet er for noe, så er det
816 <a href=
"http://tv.nrk.no/program/koid75005313/tema-dine-digitale-spor-datalagringsdirektivet
">en
817 flott dokumentar tilgjengelig hos NRK
</a
> som jeg tidligere
818 <a href=
"http://people.skolelinux.org/pere/blog/Dokumentaren_om_Datalagringsdirektivet_sendes_endelig_p__NRK.html
">har
819 anbefalt
</a
> alle å se.
</p
>
821 <p
>Her er et liten knippe nyhetsoppslag om saken, og jeg regner med at
822 det kommer flere ut over dagen. Flere kan finnes
823 <a href=
"http://www.mylder.no/?drill=datalagringsdirektivet
&intern=
1">via
824 mylder
</a
>.
</p
>
828 <li
><a href=
"http://e24.no/digital/eu-domstolen-datalagringsdirektivet-er-ugyldig/
22879592">EU-domstolen:
829 Datalagringsdirektivet er ugyldig
</a
> - e24.no
2014-
04-
08
831 <li
><a href=
"http://www.aftenposten.no/nyheter/iriks/EU-domstolen-Datalagringsdirektivet-er-ulovlig-
7529032.html
">EU-domstolen:
832 Datalagringsdirektivet er ulovlig
</a
> - aftenposten.no
2014-
04-
08
834 <li
><a href=
"http://www.aftenposten.no/nyheter/iriks/politikk/Krever-DLD-stopp-i-Norge-
7530086.html
">Krever
835 DLD-stopp i Norge
</a
> - aftenposten.no
2014-
04-
08
837 <li
><a href=
"http://www.p4.no/story.aspx?id=
566431">Apenes: - En
838 gledens dag
</a
> - p4.no
2014-
04-
08
840 <li
><a href=
"http://www.nrk.no/norge/_-datalagringsdirektivet-er-ugyldig-
1.11655929">EU-domstolen:
841 – Datalagringsdirektivet er ugyldig
</a
> - nrk.no
2014-
04-
08</li
>
843 <li
><a href=
"http://www.vg.no/nyheter/utenriks/data-og-nett/eu-domstolen-datalagringsdirektivet-er-ugyldig/a/
10130280/
">EU-domstolen:
844 Datalagringsdirektivet er ugyldig
</a
> - vg.no
2014-
04-
08</li
>
846 <li
><a href=
"http://www.dagbladet.no/
2014/
04/
08/nyheter/innenriks/datalagringsdirektivet/personvern/
32711646/
">-
847 Vi bør skrote hele datalagringsdirektivet
</a
> - dagbladet.no
848 2014-
04-
08</li
>
850 <li
><a href=
"http://www.digi.no/
928137/eu-domstolen-dld-er-ugyldig
">EU-domstolen:
851 DLD er ugyldig
</a
> - digi.no
2014-
04-
08</li
>
853 <li
><a href=
"http://www.irishtimes.com/business/sectors/technology/european-court-declares-data-retention-directive-invalid-
1.1754150">European
854 court declares data retention directive invalid
</a
> - irishtimes.com
855 2014-
04-
08</li
>
857 <li
><a href=
"http://www.reuters.com/article/
2014/
04/
08/us-eu-data-ruling-idUSBREA370F020140408?feedType=RSS
">EU
858 court rules against requirement to keep data of telecom users
</a
> -
859 reuters.com
2014-
04-
08</li
>
864 <p
>Jeg synes det er veldig fint at nok en stemme slår fast at
865 totalitær overvåkning av befolkningen er uakseptabelt, men det er
866 fortsatt like viktig å beskytte privatsfæren som før, da de
867 teknologiske mulighetene fortsatt finnes og utnyttes, og jeg tror
868 innsats i prosjekter som
869 <a href=
"https://wiki.debian.org/FreedomBox
">Freedombox
</a
> og
870 <a href=
"http://www.dugnadsnett.no/
">Dugnadsnett
</a
> er viktigere enn
873 <p
><strong
>Update
2014-
04-
08 12:
10</strong
>: Kronerullingen for å
874 stoppe datalagringsdirektivet i Norge gjøres hos foreningen
875 <a href=
"http://www.digitaltpersonvern.no/
">Digitalt Personvern
</a
>,
876 som har samlet inn
843 215,- så langt men trenger nok mye mer hvis
878 ikke Høyre og Arbeiderpartiet bytter mening i saken. Det var
879 <a href=
"http://www.holderdeord.no/parliament-issues/
48650">kun
880 partinene Høyre og Arbeiderpartiet
</a
> som stemte for
881 Datalagringsdirektivet, og en av dem må bytte mening for at det skal
882 bli flertall mot i Stortinget. Se mer om saken
883 <a href=
"http://www.holderdeord.no/issues/
69-innfore-datalagringsdirektivet
">Holder
884 de ord
</a
>.
</p
>
889 <title>ReactOS Windows clone - nice free software
</title>
890 <link>http://people.skolelinux.org/pere/blog/ReactOS_Windows_clone___nice_free_software.html
</link>
891 <guid isPermaLink=
"true">http://people.skolelinux.org/pere/blog/ReactOS_Windows_clone___nice_free_software.html
</guid>
892 <pubDate>Tue,
1 Apr
2014 12:
10:
00 +
0200</pubDate>
893 <description><p
>Microsoft have announced that Windows XP reaches its end of life
894 2014-
04-
08, in
7 days. But there are heaps of machines still running
895 Windows XP, and depending on Windows XP to run their applications, and
896 upgrading will be expensive, both when it comes to money and when it
897 comes to the amount of effort needed to migrate from Windows XP to a
898 new operating system. Some obvious options (buy new a Windows
899 machine, buy a MacOSX machine, install Linux on the existing machine)
900 are already well known and covered elsewhere. Most of them involve
901 leaving the user applications installed on Windows XP behind and
902 trying out replacements or updated versions. In this blog post I want
903 to mention one strange bird that allow people to keep the hardware and
904 the existing Windows XP applications and run them on a free software
905 operating system that is Windows XP compatible.
</p
>
907 <p
><a href=
"http://www.reactos.org/
">ReactOS
</a
> is a free software
908 operating system (GNU GPL licensed) working on providing a operating
909 system that is binary compatible with Windows, able to run windows
910 programs directly and to use Windows drivers for hardware directly.
911 The project goal is for Windows user to keep their existing machines,
912 drivers and software, and gain the advantages from user a operating
913 system without usage limitations caused by non-free licensing. It is
914 a Windows clone running directly on the hardware, so quite different
915 from the approach taken by
<a href=
"http://www.winehq.org/
">the Wine
916 project
</a
>, which make it possible to run Windows binaries on
919 <p
>The ReactOS project share code with the Wine project, so most
920 shared libraries available on Windows are already implemented already.
921 There is also a software manager like the one we are used to on Linux,
922 allowing the user to install free software applications with a simple
923 click directly from the Internet. Check out the
924 <a href=
"http://www.reactos.org/screenshots
">screen shots on the
925 project web site
</a
> for an idea what it look like (it looks just like
926 Windows before metro).
</p
>
928 <p
>I do not use ReactOS myself, preferring Linux and Unix like
929 operating systems. I
've tested it, and it work fine in a virt-manager
930 virtual machine. The browser, minesweeper, notepad etc is working
931 fine as far as I can tell. Unfortunately, my main test application
932 is the software included on a CD with the Lego Mindstorms NXT, which
933 seem to install just fine from CD but fail to leave any binaries on
934 the disk after the installation. So no luck with that test software.
935 No idea why, but hope someone else figure out and fix the problem.
936 I
've tried the ReactOS Live ISO on a physical machine, and it seemed
937 to work just fine. If you like Windows and want to keep running your
938 old Windows binaries, check it out by
939 <a href=
"http://www.reactos.org/download
">downloading
</a
> the
940 installation CD, the live CD or the preinstalled virtual machine