Monday, October 19, 2026

Crash! More machines? No, fewer. A new/old laptop with NetBSD 11.0

 Other than 1 homebrew machine I built and installed NetBSD, much of my experience is taking an old Windows machine and running BSD, or using Raspberry Pi units that aren't very portable. I found one laptop in a cleanout, but the battery would not kick in, and repairs weren't worth the hassle. Then I got a slightly less dinged machine and tried to put NetBSD 11.0 on it.

Sigh, stuck with an inability to partition the drive, I went to my local PC shop. They had not prior specific experience with NetBSD but were game enough to give it a go. Took a few days, and then they said it's ready. Here are notes on what worked, and what didn't during the first few days of my new used car, er, computer.

A critical test was whether the battery would work at all, given the machine age and peculiarities of power switching. Yes, the machine kept running without being plugged in (later I found out how short the battery life is).

The first fright was X Windows opening with a small black rectangle, and nothing else on screen. Never seen that before in decades of "startx" running. Not sure what happens, but there must be some kind of synch or init happening for up to a minute before ctwm shows a terminal, and xclock, and a process list. Whew.

Sadly, no recognition of internal wifi, so back to the USB dongle world. Slow but it works. 

I got the ByteBench package and will eventually run some speed tests. It's a 4-core/8-thread Intel machine, and 16GB, so totally adequate for what I do (QGIS is a maybe).

A few packages installed and everything generally worked as expected.

neofetch screen 

 

multimedia

VLC works, but I've lost the DLNA media servers. It worked on another NetBSD machine for a few months, and then I must have installed or deinstalled a package that pulled that function out from under. Drat. And sound seems to only come out the HDMI on the laptop, not on a secondary monitor. And the internal headphone jack is seen but not available to VLC.

Again, a USB dongle would work around this, if not the most elegant look.

Power 

The battery power is weak; once I added a template to Zabbix I could see how fast it drains. I think it's the battery, not the OS, that's weak.

 

The charge level dropped from 60% to 10% in about 2 hours. Again, used machine. Good news, the OS shut down gracefully when the power reached low tide, as the reboot didn't need to fsck.

I installed "okular" which I found to run slide shows from PDF and it worked fine; "gaupol" for creating sub-title files would start up but not show an MP4 video, just the text subscreen.

External monitors, both HDMI and VGA, work great, doubling the already decent screen size.

$ xrandr

Screen 0: minimum 8 x 8, current 1920 x 1080, maximum 32767 x 32767

eDP1 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 340mm x 190mm

1920x1080 60.02*+ 59.93 48.03

1680x1050 59.88

1400x1050 59.98

1600x900 60.00 59.95 59.82

1280x1024 60.02

1400x900 59.96 59.88

...

xscreensaver 

I put xscreensaver on, and ran a few test cycles. One saver would SEGV, others worked ok, until I was wakened by the fan noise when one app just hit the roof. I have found you can chart the screen saver impact on a machine by looking at the CPU temperature. The change cycle is 20 minutes or so; the most graphics-intensive (or inefficient code) cause heat spikes.


At one point I had a shell script that would annotate the strip chart with the xscreensaver code cycling info. Should dig that up. 

Partial dmesg output:

  

[     1.000000] NetBSD 11.0 (GENERIC) #0: Thu Jul 30 15:23:12 UTC 2026
[     1.000000] 	mkrepro@mkrepro.NetBSD.org:/usr/src/sys/arch/amd64/compile/GENERIC
[     1.000000] total memory = 16242 MB
[     1.000000] avail memory = 15682 MB
 good ... 
[     1.000004] cpu0: Intel(R) Core(TM) i5-8350U CPU @ 1.70GHz, id 0x806ea
[     1.000004] cpu0: node 0, package 0, core 0, smt 0
also good ...
[     1.000004] cpu7: Intel(R) Core(TM) i5-8350U CPU @ 1.70GHz, id 0x806ea
[     1.000004] cpu7: node 0, package 0, core 3, smt 1
... yes
[     1.044421] Atheros Communications product 003e (miscellaneous network, revision 0x32) at pci2 dev 0 function 0 not configured
... not so good.
[     1.044421] wm0: Ethernet address []
[     1.044421] wm0: 0x6a4080<FLASH,PCIE,ASF_FIRM,AMT,WOL,EEE>
[     1.044421] ihphy0 at wm0 phy 2: i217 10/100/1000 media interface, rev. 6
[     1.044421] ihphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 1000baseT-FDX, auto
... fine
[     2.284418] urtwn0: MAC/BB RTL8188EU, RF 6052 1T1R, address []
[     2.334418] urtwn0: 1 rx pipe, 2 tx pipes
... wifi USB dongle, whew
[  2444.159851] pckbport: command timeout
[  2454.328638] autoconfiguration error: pms_enable: command error 35
... (much later, not sure what this is from)  


Now just to wait until 11.1 comes out and makes this oldie even better.

 

Friday, September 25, 2026

The 3rd Degree in Baltimore's Grid System

 A few years ago, I had an artist friend draw 4 Baltimore City maps for a historic trail guide. The original versions date back to the 1960s and the streets and points of interest had shifted since.

3 degrees...


Almost noticeable at this scale:


A few years went by and I was asked for new trail maps. I have meanwhile learned enough about GIS to try my hand at it. The points of interest noted during earlier hikes I put into spreadsheets, then as Qgis layers. I could use OpenStreetMap as the base.

I have a scan of an 1896 City map, as well as a bunch of Omstead drawings ranging from the early 20th century forward. The former covers a couple square miles, from the harbor north to around North Avenue. A highlight is the Washington Monument in Mount Vernon, where the surrounding 4 park areas make a nice pattern to help geolocate specific places nearby.

I exported City streets and highways from the state GIS sources, using Turbo Overpass so I could limit the streets shown, in order to highlight certain locations. Some tuning of legends is needed so the street names appear.

I have used the QGis feature to georeference a map picture before, and maybe it's gotten easier, with practice, to have viable overlays of "then" and "now."

But. Baltimore's street grid was laid out, for many square blocks, on compass lined north - south or east - west alignments. Except that was then, and this is not then. Magnetic North has drifted 3 degrees within 100 years or so? Wow, was I surprised it was that much.

I probably first saw the drift zooming in on an apartment building that occupies part of one block, where the building seemed off kilter.

This view shows the grid perpendicular, hardly noticeable the compass rose setting to be.



This view has Magnetic north pointing to the top of the page. Streets are angled.




Hm.
Images from OpenStreetMap and OSMand. Credits thereto.

Back to QGIS. 3 degrees to port, or starboard? In other words, set to positive or negative 3? Turns out +3 works.






Friday, August 28, 2026

Relayering the onion for PDF reversal from ODG to Scribus

 You can make a layered PDF from a LibreOffice drawing, at least obliquely.

Exporting to PDF from LO does not capture the layers in the source as PDG 1.6 layers.

Opening with Scribus, then exporting to a layered PDF works. But. The layers go from left-to-right as top-to-bottom, rather than right-to-left. Later added layers end up on top, and if they are a scanned image, everything below gets masked.








Tip of the tam-o-shanter:




Original layer order in the Scribus-based PDF export:



BEFORE


Just a little line cut and pasts. Viola!


$ diff  the-madison-floorplan+poi-feet.fodg the-madison-floorplan+poi-feet-regrooved.fodg
726,729d725
<    <draw:layer draw:name="Main Halls + Rooms"/>
<    <draw:layer draw:name="Building Columns"/>
<    <draw:layer draw:name="Fire+Exit"/>
<    <draw:layer draw:name="Closets"/>
730a727,730
>    <draw:layer draw:name="Closets"/>
>    <draw:layer draw:name="Fire+Exit"/>
>    <draw:layer draw:name="Building Columns"/>
>    <draw:layer draw:name="Main Halls + Rooms"/>
1925c1925
< </office:document>
\ No newline at end of file
---
> </office:document>

FODG is your friend!

AFTER


Sunday, August 9, 2026

QGIS 4.0 to 4.2.0 to 4.2.1 in July heat with NetBSD 11.0 hot off the digital press

 Around the first of Jul 2026 I was building QGIS 3 or 4 on 3 NetBSD systems, 1 fast, 2 slow, in order to check that each worked with PostgreSQL 14, 16 or 18, respectively. It mostly worked, albeit as slow as molasses in winters of yore.

To do the builds requires pkgsrc source code, as the pre-packaged versions are only built with version 16 database driver/library support.

CPU temperature + Processor load 24 hours+

On the 6th, I reworked the Bengies drive-in geocache and tent map.


The Bengies Drive-In

On the bigger system, 4.0 QGIS

QGIS 4 splash screen

Next thing I know, 4.2.0 is sitting in work-in-progress to I backed up and restarted the build.





Very nice, and worked about the same as the 4.0.

4.2.0 About Screen


I tried the Authentication option briefly, didn't get screen shots, and then. poof again, 2026Q2 pkgsrc became available after bulk builds, NetBSD 11.0 was released after a BETA and 6 or more Release Candidates.


By 31-July, a geospatial PDF:






When I finished 11.0 upgrades and wiped pkgsrc for a clean slate, there came one more work-in-progress version, 4.2.1.

Or "final".

QGIS 4.2.1 on NetBSD 11.0



Monday, July 20, 2026

QGIS 3x3 on NetBSD 10/11 + PostgreSQL 14/16/18

 

Started making QGIS version 3.44.8 early June 2026 on NetBSD processors

jump ahead:

$ ps auxww | head -2

USER        PID %CPU %MEM      VSZ    RSS TTY    STAT STARTED     TIME COMMAND

root      24310 93.3  1.1   427668 355252 pts/6  O+   12:18AM  0:02.14 /usr/pkg/gcc12/libexec/gcc/x86_64--netbsd/12.4.0/cc1plus -quiet -I /usr/pkgsrc/wip/qgis/work/QGIS-final-4_0_3/cmake-pkgsrc-build/src/core/qgis_core_autogen/include

Wed Jun 10 00:25:37 UTC 2026

$ TZ=EST date

Tue Jun  9 19:25:45 EST 2026

=> Checking file-check results for qgis-3.44.8
=> Creating binary package /usr/pkgsrc/geography/qgis/work/.packages/qgis-3.44.8.tgz


/// pkg_delete postgresql18-client qgis-3.44.8  py313-psycopg2-2.9.11


$ pkgin  show-deps "qgis" | grep -i client
        postgresql16-client>=16.0nb1


https://pkgsrc.se/wip/qgis

Version history: (Expand)

    (2026-06-02) Updated to version: qgis-4.0.3
    (2026-05-10) Updated to version: qgis-4.0.2.18
    (2026-03-09) Updated to version: qgis-4.0.0.0
    (2026-02-22) Updated to version: qgis-3.99.3
    (2026-02-21) Updated to version: qgis-3.99.2

FREEBSD ~~~

foobar:/etc # pkg search qgis
qgis-3.44.11                   Free and Open Source Geographic Information System
qgis-ltr-3.40.15_1             Free and Open Source Geographic Information System

something bollixed. Back to NetBSD.
~~~

amd64-12-core
$ ls -ltr /usr/pkgsrc/packages/All/qg*
-rw-r--r--  1 root  wheel  123201876 Jun  9 17:15 /usr/pkgsrc/packages/All/qgis-3.44.8.tgz
-rw-r--r--  2 root  wheel  124614138 Jun 26 16:10 /usr/pkgsrc/packages/All/qgis-3.44.11.tgz
-rw-r--r--  2 root  wheel  127333035 Jul 13 11:34 /usr/pkgsrc/packages/All/qgis-4.0.3.tgz
-rw-r--r--  2 root  wheel  131910253 Jul 15 23:27 /usr/pkgsrc/packages/All/qgis-4.2.0.tgz

amd64-4-core
5.3$ ls -l /root/pkg-local/qg*
-rw-r--r--  1 root  wheel  127333035 Jul 13 20:02 /root/pkg-local/qgis-4.0.3.tgz

amd64-2-core
[     1.000004] cpu0 at mainbus0 apid 0
[     1.000004] cpu0: Use lfence to serialize rdtsc
[     1.000004] cpu0: Intel(R) Core(TM)2 Duo CPU     L9400  @ 1.86GHz, id 0x1067a
[     1.000004] cpu0: node 0, package 0, core 0, smt 0
[     1.000004] cpu1 at mainbus0 apid 1
[     1.000004] cpu1: Intel(R) Core(TM)2 Duo CPU     L9400  @ 1.86GHz, id 0x1067a
[     1.000004] cpu1: node 0, package 0, core 1, smt 0
[     1.000004] acpi0 at mainbus0: Intel ACPICA 20221020



2 core had faults, see:

RuntimeError: NumPy was built with baseline optimizations:
(X86_V2) but your machine doesn't support:
(X86_V2).

Pictures and exhibitions

Kept track of long compile times (~18 hours) on the slowest machine, as well as faster, looking at CPU temperature and process load (distributed across 1 or many "cores").

[
mastodon cc me
https://assets.chaos.social/media_attachments/files/116/846/959/384/561/931/original/96c70f8d89d6e49f.png

Go Speed Racer Go!


Pre 3-way build side quest:


Initial launch 4.0.3 June 2026


-rw-r--r--  1 jim  jim 20978 Jun 10 12:46 GIS/spots-rooms-q4.qgz



Side quest:

QGIS 3.44 on the machine I chose did not build, so the check with PG SQL 14 was inadequate. I changed the SQL version on that machine to 18, and it runs with the broken CPU message disabling various plugins (yet to be found).

This is the override of the database version when building from source, not installing pre-fabs.

$ pwd
/usr/pkgsrc/mk

$ diff pg*
28,30c28
< # PGSQL_VERSION_DEFAULT?=             16
< # Fri Jun 26 04:32:43 UTC 2026
< PGSQL_VERSION_DEFAULT?=               18
---
> PGSQL_VERSION_DEFAULT?=               16


Screengrab needs to be built from scratch; what I previously did with an X capture app has fallen into disrepair. At least xli still works.

$ ls -l `which qgis`
-rwxr-xr-x  1 root  wheel     390320 Jul  3 12:43 /usr/pkg/bin/qgis

-rw-r--r--  1 root  wheel  124615383 Jul  3 12:45 ./pkg-local/qgis-3.44.11.tgz

$ psql --version
psql (PostgreSQL) 18.4


Post 3-way build side quest of 3x3, going to 4:

Back to the fast machine and the newest (l+g). The work-in-progress version went from 4.0.3 to 4.2.0. Wow, quick change!

Build time ~8 hours with or without fumbles. Needs to be redone with a clean slate and only 2026Q4 pkgsrc to get things level. But it starts and connects to databases as it should.

$ time qgis --version
QGIS 4.2.0-Belém do Pará 'Belém do Pará' (exported)

real    0m2.522s
user    0m2.458s
sys     0m0.039s







Quick duck back to 3.44.11



Comparison table of the 12-core with 4.2.0 and the 2-core with 3.44.11.



Sidebar issue with Python caused the active plugins to be empty on the 2-core, but otherwise they are pretty much the same beyond QGIS itself and the Qt version going from 5 to 6.

Neither system shows a value for SFCGAL or GeographicLib. Not sure what impact that has.

Working on a list of projects for QGIS 4.2, including waypoints of Historic Trails, paths in the woods, and geocaching at the Bengies Drive-In Theatre.

Wednesday, June 17, 2026

Forward with QGIS 4 and NetBSD 11 and more

 A week ago, based on a tip from Greg T, I build QGIS 4.0 on a NetBSD 10.1 system. It worked, after arranging the work-in-progress snapshot.

Peripherally, I got into gdal (for georeferenced PDFs), postgis (with PostgreSQL 18), and fence-posting of PGSQL 14 through 18 as allowed by the pkgsrc tools and all.


I put the problems first, instead of the splash screen showing the build worked; this showed it work-worked.

Splash - QGIS 4.0 starting banner, with an auth fail flag.


To show the build time (as opposed to package download/install time), I used Zabbix charts of CPU time and/or temperature.

First is the fastest machine I have, compiling QGIS 3 followed by 4. A few hours each. Ish.


Sidebar in the future about single-threaded builds, as I have a collection of antique laptops that I've kept out of the hopper by installing BSD on them with new SSDs. 2 or 4 core, plus one "tower" that has a laptop-type board inside (HP made money doing that).

The glitch for using other than one PGSQL versions I found was the packaged build use 16 (as of this writing), but the pkgsrc make process allows one (and only one) of 14 through 18. For some reason I've got even number versions running, not on purpose, just the time I jumped into the pool for some app/reason.

A bigger test/build/test cycle is brewing, with the rough starting time after 2026 Q2 packages are distributed in a few weeks. Meanwhile I built 3.4.8 on a system with PostgreSQL 14 server. 18 to 24 hours on this box.

===> Extracting for qgis-3.44.8

=> Full dependency postgresql14-client>=14.17nb2: found postgresql14-client-14.23

I like this chart as Zabbix allows dashboards with arbitrary charts to go on the same page. Easier than trying to line up 2 Y-axes unless they are on the same scale (like classic 1/5/15 minute processor loads).

Issues above (and beyond)

  • First encounter with an authorization message. Doesn't stop use, but it's unfamiliar territory.
  • Building a current work-in-progress sub-tree broke apps on my main machine, maybe not the version 4.0.
  • One core dump in the short time I ran 4.0.
  • I had/have outdated pkgsrc trees, getting up to date with 2026 Q1 then Q2.
  • Wishful thinking I could cross-build an aarch64 QGIS 4.0 as a Pi 4 may take as long to build as an old Intel (unsure)
  • Geo-referenced PDF exports depend on the gdal library; Greg imported a change prior to freeze that I have yet to try.
  • PostGIS works with version 18 now.
  • The PKGSRC.se site has some new data, some old data on their pages. Images at the end. #ToDo
  • The QGIS.org site shows build steps for FreeBSD and OpenBSD, not NetBSD. (Whom do I know?)
  • pkg_admin version?
  • The NetBSD wiki and pkgsrc docs could explain more how to/why to use a PGSQL version with QGIS or any other DB app.
    • e.g 

https://wiki.netbsd.org/pkgsrc/how_to_install_a_postgresql_server/
Last edited 5 years and 9 months ago
...
The recommended way is to install the prebuilt postgresql binaries.
The PostgreSQL Server depends on the postgreSQL Client.

? road less traveled way - how to use a version other than default ?

cd geography/qgis
set version ?
"make install"

PHP and PostgreSQL
You may wish to install the postgres Module for PHP, e.g. for PHP 7.0 use:
# pkg_add -v php70-pgsql

3$ pkgin se php".*"-pgsql
php56-pgsql-5.6.40nb1  PHP extension for PostgreSQL databases
php74-pgsql-7.4.33nb1  PHP extension for PostgreSQL databases
php82-pgsql-8.2.31nb1  PHP extension for PostgreSQL databases
php83-pgsql-8.3.31nb1  PHP extension for PostgreSQL databases
php84-pgsql-8.4.20nb1  PHP extension for PostgreSQL databases
php85-pgsql-8.5.7nb1  PHP extension for PostgreSQL databases

add Python example:

$ pkgin se psyco
py311-psycopg2-2.9.11  PostgreSQL database adapter for Python
py312-psycopg2-2.9.11  PostgreSQL database adapter for Python
py313-psycopg2-2.9.11 = PostgreSQL database adapter for Python
py314-psycopg2-2.9.11  PostgreSQL database adapter for Python

import psycopg2


add Perl via DBI/DBD:

$ pkgin se p5-dbd-postgresql
p5-DBD-postgresql-3.14.2nb5  Perl DBI/DBD driver for PostgreSQL databases

use DBI qw(:sql_types);
use DBD::Pg qw(:pg_types);

export PGUSER=scott
export PGDATABASE=emp
export PGHOST=dept

? Read the manual ?

https://www.netbsd.org/docs/pkgsrc/pkgsrc.html

pgsql.buildlink3.mk will accept any of the Postgres versions in the variable PGSQL_VERSIONS_ACCEPTED and default to the version PGSQL_VERSION_DEFAULT. See the file for more information.

Explain default version "middle of the road" at a point in time for more users than other versions (subject to debate) not "most recent" version of PostreSQL.


https://pkgsrc.se/wip/qgis


https://pkgsrc.se/geography/qgis

Others in scope:

https://pkgsrc.se/geography/gdal-lib

https://pkgsrc.se/databases/py-psycopg2


Wednesday, June 10, 2026

Delaminating the Onion, OGR style

 After I learned about geospatial PDF documents with layers of GIS "goo" embedded I've tried out maps and similar graphics for events and travel. New challenge--having a layered PDF for a theater stage floor plan. The idea came when I found first one, then a different paper drawing, detailed but lacking those "mechanical drawing" features such as a title block, date, scale, source, things like that.

New version, showing 3 of 8 layers


The old drawings could have come from Corel Draw for all I know.


I wanted to use LibreOffice Draw if possible, to create a layered PDF, as I've learned how to do most of what I could do with MS Visio. The above image is the fix for dimensions in Imperial units that show up as "10.01 feet" for unknown reasons. Truncating to 1 decimal place makes it better as "10.0 feet."

Here's one with a rounding error, and also a scaling error as the scale "rod" should be 10 feet, not 9 and a half-ish.

The ODG, seat numbers and scan layers were supposed to have boxes to check if that layer was included in the view. 

But no, while the LibreOffice drawing can manage internal layer juggling, writing a PDF with defined layers does not work.

https://bugs.documentfoundation.org/show_bug.cgi?id=138142

Bug 138142 - "Draw should have an option to export to PDF keeping separate layers"

A workaround posted here:

https://graphicdesign.stackexchange.com/questions/169487/how-to-export-a-drawing-odg-file-from-libreoffice-25-8-to-a-multi-layered-pdf-f 

Load the ODG file into Scribus, then export to a layered PDF. It works, but only to a degree, as the layers get shuffled and renamed.

Extra layers can be added in Scribus, so I chose to do the measured baselines (aisles etc.) in ODG and the icing of title blocks and guides for lining out skewed scanned of paper drawings in Scribus.

I've also added an SVG layer from Inkscape.

Looking at an imported JPEG is awful from Scribus. But the PDF looks fine.

Layers and more


Almost had an issue with "back-loading" a Scribus file on Windows 1.6, after creating a document in NetBSD with 1.7. So I'll use the higher version and save as" a lower if anyone needs to look for themselves.



The scans ended up slightly different in shape, added to the task of alignment.

 

Embellishing with seat designs and numbers in Inkscape turned out to be a bigger task than imagined. For one thing, the web site has a dark theme, but printing the images for human note-taking needs a light theme, as these are.

The seat counts differ between the two, I finally noticed also.