iljitsch.com

topics: alles · BGP / IPv6 / more · settings · b&w · my business: inet⁶ consult · Twitter · Mastodon · LinkedIn · email · 🇺🇸 🇳🇱

Op deze pagina staan alle posts over alle onderwerpen. Archive for 2023.

Review: Sigma BC 16.16 STS CAD cycling computer

As I wrote earlier: recently, I lost another bike computer so I needed a new one. I decided to get a more recent version of the Sigma BC line that I've been using for the past decade: the Sigma BC 16.16 STS CAD. These seem to be on the way out now, being sold out almost everywhere. But no obvious replacement that isn't more expensive and more complex, so I'm glad I got to get one of the last ones.

Read the article - posted 2023-01-01

Local windmill in action

For the first time in a long while the Nieuwe Veenmolen, the local neighborhood windmill from 1654, is turning. Back in the day, it pumped away water to keep the area dry.

Permalink - posted 2023-01-30

Skyline #18 shot-on-film (Kodak Tri-X) edition

Image link - posted 2023-02-05

Skyline #19

Image link - posted 2023-02-14

Comparing digital and film resolution using MTF

I fell down a rabbit hole a while ago trying to come up with the definitive answer to the often-asked question "how can old movies be in HD/4K", which immediately leads to "how does film and digital resolution compare".

The answer to the first question is of course that film as a lot more resolution than standard definition TV, so just scanning the movies at a higher resolution will give you a sharper image than that old DVD or (shudder) VHS tape.

The problem with reasoning about film grain vs pixels or eyeballing images is that it's very imprecise. But we actually do have a tool that lets us compare digital vs film: the optical transfer function.

Integrated below a little tool with a slider to see for yourself where the tradeoffs are.

Read the article - posted 2023-03-29

My favorite pointing devices

Image link - posted 2023-05-13

Looking back on 50 years of Ethernet

On potaroo.net Geoff Huston wishes Happy 50th Birthday Ethernet.

Back in 2011 I wrote an Ars Technica feature about the history of Ethernet: Speed matters: How Ethernet went from 3Mbps to 100Gbps… and beyond.

Interesting to compare our different takes!

And of course Ethernet is still going strong. My oldest computers have the original 10 Mbps Ethernet adapters that I got almost 30 years ago, while my newest computer has 10 gigabit Ethernet, 1000 x faster.

Read the article - posted 2023-06-29

Verkiezingen komen er aan! #1

Een kleine drie weken geleden viel het kabinet Rutte-4. Sindsdien hebben premier Rutte en alle vice-premiers aangekondigd na de demissionaire periode de politiek te gaan verlaten. Twee lijsttrekkers van de verkiezingen van 2021 waren al vertrokken en nog eens drie hebben aangekondigd niet verder te gaan. We gaan de verkiezingen van 22 november dus tegemoet met een flink aantal verse lijsttrekkers.

Read the article - posted 2023-07-26

SDBox: a cheap SD card adapter for your Amiga

I was watching the videos on the BBC Master computer on the Adrian's Digital Basement Youtube channel. Adrian has cleaned up this old Acorn BBC Master, restored the keyboard to full functionality and then started to "Americanize" it by changing the power supply to use 120 V, and making the composite video NTSC rather PAL.

But what really peaked my interest is that he made a tiny little interface to hook up SD cards to the Master's user port. I think it only uses four wires. There's a very small circuit board, but that only has some resistors to adapt the user port's 5 V to the 3.3 V used by SD cards. Apparently, that's all the hardware you need for reading (and writing?) SD cards. Wow.

Could this also work on an Amiga?

Read the article - posted 2023-08-21

Skyline #20, regenboog-editie

Image link - posted 2023-08-27

SQLite: add a powerful database engine to any app

When I was 24, I decided to give up my job and go to college and study computer science. If I'd have known how many database classes that involved, maybe I would have reconsidered.

Back then, we had a big server that ran a RDBMS (relational database management system) that hundreds of students all used together. These systems were big, complex and expensive. (Oracle made its fortune selling RDBMSes.) MySQL and PostgresQL are somewhat more streamlined free and open source RDBMSes. Much better, but firewalling, user authentication and backups are still somewhat of a headache. But hey, if you need a database, you need a database.

Enter SQLite.

Read the article - posted 2023-09-04

Looking at SQLite Unicode behavior

In this post, I want to have a look at how SQLite interacts with Unicode. (Also see my post The (dark) magic of Unicode.) As explained here, SQLite doesn't have full Unicode support unless that support is explicitly included when SQLite is compiled.

So what does this mean in practice?

Read the article - posted 2023-09-05

Should the datacenter be in the middle?

The other day, I landed on this article: In Focus: Subsea Network Architecture: IXPs. The article takes some time to arrive at the point that undersea internet exchanges would be a good idea. The most eyecatching part is a variation on this image:

But should the datacenter and/or internet exhange in the middle between multiple users?

Read the article - posted 2023-09-07

Looking at MySQL Unicode behavior

https://en.wikipedia.org/wiki/European_ordering_rules

But as the transition from 8-bit characters to 16-bit characters was already well underway in the Windows world and in languages such as Java and Javascript,

# mysql --default_character_set=utf8mb4 muada Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A

Welcome to the MySQL monitor. Commands end with ; or g. Your MySQL connection id is 98 Server version: 8.0.34 MySQL Community Server - GPL

Copyright (c) 2000, 2023, Oracle and/or its affiliates.

Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners.

Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.

mysql> SHOW SESSION VARIABLES LIKE 'character_set%'; +--------------------------+--------------------------------+ | Variable_name | Value | +--------------------------+--------------------------------+ | character_set_client | utf8mb4 | | character_set_connection | utf8mb4 | | character_set_database | utf8mb4 | | character_set_filesystem | binary | | character_set_results | utf8mb4 | | character_set_server | utf8mb4 | | character_set_system | utf8mb3 | | character_sets_dir | /usr/share/mysql-8.0/charsets/ | +--------------------------+--------------------------------+

DUCET

https://www.unicode.org/reports/tr10/#Default_Unicode_Collation_Element_Table https://www.unicode.org/reports/tr10/

http://www.unicode.org/Public/UCA/latest/allkeys.txt

https://en.wikipedia.org/wiki/European_ordering_rules https://en.wikipedia.org/wiki/ISO/IEC_14651

mysql> insert into test (id, text) values (5, concat('Zo', char(12*16 + 3, 10*16 + 11 using utf8mb4))); Query OK, 1 row affected (0.00 sec)

mysql> insert into test (id, text) values (6, concat('Zoe', char(12*16 + 12, 8*16 + 8 using utf8mb4)));

mysql> insert into test (id, text) values (7, 'Zoe');

mysql> select * from test order by text collate utf8mb4_bin; +----+-------+ | id | text | +----+-------+ | 1 | ZOE | | 4 | ZoA | | 7 | Zoe | | 6 | Zoë | | 3 | Zoy | | 5 | Zoë | | 2 | zoe | +----+-------+ 7 rows in set (0.00 sec)

mysql> select *, weight_string(text collate utf8mb4_bin) as sortweight from test order by text colla +----+-------+----------------------------+ | id | text | sortweight | +----+-------+----------------------------+ | 1 | ZOE | 0x00005A00004F000045 | | 4 | ZoA | 0x00005A00006F000041 | | 7 | Zoe | 0x00005A00006F000065 | | 6 | Zoë | 0x00005A00006F000065000308 | | 3 | Zoy | 0x00005A00006F000079 | | 5 | Zoë | 0x00005A00006F0000EB | | 2 | zoe | 0x00007A00006F000065 | +----+-------+----------------------------+

mysql> select *, weight_string(text collate utf8mb4_0900_ai_ci) as sortweight from test order by text collate utf8mb4_0900_ai_ci; +----+-------+------------------------+ | id | text | sortweight | +----+-------+------------------------+ | 4 | ZoA | 0x1F211DDD1C47 | | 1 | ZOE | 0x1F211DDD1CAA | | 2 | zoe | 0x1F211DDD1CAA | | 5 | Zoë | 0x1F211DDD1CAA | | 6 | Zoë | 0x1F211DDD1CAA | | 7 | Zoe | 0x1F211DDD1CAA | | 3 | Zoy | 0x1F211DDD1F0B | +----+-------+------------------------+

mysql> select *, weight_string(text collate utf8mb4_0900_ai_ci) as sortweight from test order by text collate utf8mb4_0900_ai_ci desc; +----+-------+------------------------+ | id | text | sortweight | +----+-------+------------------------+ | 3 | Zoy | 0x1F211DDD1F0B | | 1 | ZOE | 0x1F211DDD1CAA | | 2 | zoe | 0x1F211DDD1CAA | | 5 | Zoë | 0x1F211DDD1CAA | | 6 | Zoë | 0x1F211DDD1CAA | | 7 | Zoe | 0x1F211DDD1CAA | | 4 | ZoA | 0x1F211DDD1C47 | +----+-------+------------------------+

mysql> select *, weight_string(text collate utf8mb4_0900_as_ci) as sortweight from test order by text collate utf8mb4_0900_as_ci; +----+-------+------------------------------------+ | id | text | sortweight | +----+-------+------------------------------------+ | 4 | ZoA | 0x1F211DDD1C470000002000200020 | | 1 | ZOE | 0x1F211DDD1CAA0000002000200020 | | 2 | zoe | 0x1F211DDD1CAA0000002000200020 | | 7 | Zoe | 0x1F211DDD1CAA0000002000200020 | | 5 | Zoë | 0x1F211DDD1CAA0000002000200020002B | | 6 | Zoë | 0x1F211DDD1CAA0000002000200020002B | | 3 | Zoy | 0x1F211DDD1F0B0000002000200020 | +----+-------+------------------------------------+

mysql> select *, weight_string(text collate utf8mb4_0900_as_cs) as sortweight from test order by text collate utf8mb4_0900_as_cs; +----+-------+--------------------------------------------------------+ | id | text | sortweight | +----+-------+--------------------------------------------------------+ | 4 | ZoA | 0x1F211DDD1C4700000020002000200000000800020008 | | 2 | zoe | 0x1F211DDD1CAA00000020002000200000000200020002 | | 7 | Zoe | 0x1F211DDD1CAA00000020002000200000000800020002 | | 1 | ZOE | 0x1F211DDD1CAA00000020002000200000000800080008 | | 5 | Zoë | 0x1F211DDD1CAA0000002000200020002B00000008000200020002 | | 6 | Zoë | 0x1F211DDD1CAA0000002000200020002B00000008000200020002 | | 3 | Zoy | 0x1F211DDD1F0B00000020002000200000000800020002 | +----+-------+--------------------------------------------------------+

ê

mysql> select *, weight_string(text collate utf8mb4_0900_bin) as sortweight from test where text = concat('Zo', char(12*16 + 3, 10*16 + 10 using utf8mb4)) collate utf8mb4_0900_bin; Empty set (0.00 sec)

mysql> select *, weight_string(text collate utf8mb4_0900_as_cs) as sortweight from test where text = concat('Zo', char(12*16 + 3, 10*16 + 10 using utf8mb4)) collate utf8mb4_0900_as_cs; Empty set (0.00 sec)

mysql> select *, weight_string(text collate utf8mb4_0900_ai_cs) as sortweight from test where text = concat('Zo', char(12*16 + 3, 10*16 + 10 using utf8mb4)) collate utf8mb4_0900_ai_cs; ERROR 1273 (HY000): Unknown collation: 'utf8mb4_0900_ai_cs' mysql> select *, weight_string(text collate utf8mb4_0900_ai_ci) as sortweight from test where text = concat('Zo', char(12*16 + 3, 10*16 + 10 using utf8mb4)) collate utf8mb4_0900_ai_ci; +----+-------+------------------------+ | id | text | sortweight | +----+-------+------------------------+ | 1 | ZOE | 0x1F211DDD1CAA | | 2 | zoe | 0x1F211DDD1CAA | | 5 | Zoë | 0x1F211DDD1CAA | | 6 | Zoë | 0x1F211DDD1CAA | | 7 | Zoe | 0x1F211DDD1CAA | +----+-------+------------------------+ 5 rows in set (0.00 sec)

mysql> select *, weight_string(text collate utf8mb4_0900_ai_ci) as sortweight from test where text = concat('Zo', char(12*16 + 3, 10*16 + 10 using utf8mb4)) collate utf8mb4_0900_ai_ci order by text utfmb4_0900_as_cs; ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'utfmb4_0900_as_cs' at line 1 mysql> select *, weight_string(text collate utf8mb4_0900_ai_ci) as sortweight from test where text = concat('Zo', char(12*16 + 3, 10*16 + 10 using utf8mb4)) collate utf8mb4_0900_ai_ci order by text collate utfmb4_0900_as_cs; ERROR 1273 (HY000): Unknown collation: 'utfmb4_0900_as_cs' mysql> select *, weight_string(text collate utf8mb4_0900_ai_ci) as sortweight from test where text = concat('Zo', char(12*16 + 3, 10*16 + 10 using utf8mb4)) collate utf8mb4_0900_ai_ci order by text collate utf8mb4_0900_as_cs; +----+-------+------------------------+ | id | text | sortweight | +----+-------+------------------------+ | 2 | zoe | 0x1F211DDD1CAA | | 7 | Zoe | 0x1F211DDD1CAA | | 1 | ZOE | 0x1F211DDD1CAA | | 5 | Zoë | 0x1F211DDD1CAA | | 6 | Zoë | 0x1F211DDD1CAA | +----+-------+------------------------+ 5 rows in set (0.00 sec)

mysql> mysql> mysql> mysql> mysql> select *, weight_string(text collate utf8mb4_0900_bin) as sortweight from test where text = concat('Zo', char(12*16 + 3, 10*16 + 11 using utf8mb4)) collate utf8mb4_0900_bin; +----+------+------------------------+ | id | text | sortweight | +----+------+------------------------+ | 5 | Zoë | 0x5A6FC3AB | +----+------+------------------------+ 1 row in set (0.00 sec)

mysql> select *, weight_string(text collate utf8mb4_0900_as_cs) as sortweight from test where text = concat('Zo', char(12*16 + 3, 10*16 + 11 using utf8mb4)) collate utf8mb4_0900_as_cs; +----+-------+--------------------------------------------------------+ | id | text | sortweight | +----+-------+--------------------------------------------------------+ | 5 | Zoë | 0x1F211DDD1CAA0000002000200020002B00000008000200020002 | | 6 | Zoë | 0x1F211DDD1CAA0000002000200020002B00000008000200020002 | +----+-------+--------------------------------------------------------+ 2 rows in set (0.00 sec)

mysql> select *, weight_string(text collate utf8mb4_0900_ai_cs) as sortweight from test where text = concat('Zo', char(12*16 + 3, 10*16 + 11 using utf8mb4)) collate utf8mb4_0900_ai_cs; ERROR 1273 (HY000): Unknown collation: 'utf8mb4_0900_ai_cs' mysql> mysql> mysql> mysql> mysql> select *, weight_string(text collate utf8mb4_0900_bin) as sortweight from test where text = concat('Zo', char(12*16 + 3, 10*16 + 11 using utf8mb4)) collate utf8mb4_0900_bin; +----+------+------------------------+ | id | text | sortweight | +----+------+------------------------+ | 5 | Zoë | 0x5A6FC3AB | +----+------+------------------------+ 1 row in set (0.00 sec)

mysql> select *, weight_string(text collate utf8mb4_0900_as_ci) as sortweight from test where text = concat('Zo', char(12*16 + 3, 10*16 + 11 using utf8mb4)) collate utf8mb4_0900_as_ci; +----+-------+------------------------------------+ | id | text | sortweight | +----+-------+------------------------------------+ | 5 | Zoë | 0x1F211DDD1CAA0000002000200020002B | | 6 | Zoë | 0x1F211DDD1CAA0000002000200020002B | +----+-------+------------------------------------+ 2 rows in set (0.00 sec)

mysql> select *, weight_string(text collate utf8mb4_0900_as_cs) as sortweight from test where text = concat('Zo', char(12*16 + 3, 10*16 + 11 using utf8mb4)) collate utf8mb4_0900_as_cs; +----+-------+--------------------------------------------------------+ | id | text | sortweight | +----+-------+--------------------------------------------------------+ | 5 | Zoë | 0x1F211DDD1CAA0000002000200020002B00000008000200020002 | | 6 | Zoë | 0x1F211DDD1CAA0000002000200020002B00000008000200020002 | +----+-------+--------------------------------------------------------+ 2 rows in set (0.00 sec)

mysql> select *, weight_string(text collate utf8mb4_0900_bin) as sortweight from test where text = 'zoe' collate utf8mb4_0900_bin; +----+------+------------------------+ | id | text | sortweight | +----+------+------------------------+ | 2 | zoe | 0x7A6F65 | +----+------+------------------------+ 1 row in set (0.00 sec)

mysql> select *, weight_string(text collate utf8mb4_0900_as_cs) as sortweight from test w here text = 'zoe' collate utf8mb4_0900_as_cs; +----+------+------------------------------------------------+ | id | text | sortweight | +----+------+------------------------------------------------+ | 2 | zoe | 0x1F211DDD1CAA00000020002000200000000200020002 | +----+------+------------------------------------------------+ 1 row in set (0.00 sec)

mysql> select *, weight_string(text collate utf8mb4_0900_as_ci) as sortweight from test where text = 'zoe' collate utf8mb4_0900_as_ci; +----+------+--------------------------------+ | id | text | sortweight | +----+------+--------------------------------+ | 1 | ZOE | 0x1F211DDD1CAA0000002000200020 | | 2 | zoe | 0x1F211DDD1CAA0000002000200020 | | 7 | Zoe | 0x1F211DDD1CAA0000002000200020 | +----+------+--------------------------------+ 3 rows in set (0.00 sec)

mysql> select *, weight_string(text collate utf8mb4_0900_ai_ci) as sortweight from test where text = 'zoe' collate utf8mb4_0900_ai_ci; +----+-------+------------------------+ | id | text | sortweight | +----+-------+------------------------+ | 1 | ZOE | 0x1F211DDD1CAA | | 2 | zoe | 0x1F211DDD1CAA | | 5 | Zoë | 0x1F211DDD1CAA | | 6 | Zoë | 0x1F211DDD1CAA | | 7 | Zoe | 0x1F211DDD1CAA | +----+-------+------------------------+

mysql> show collation like '%utf8mb4_uni%'; +------------------------+---------+-----+---------+----------+---------+---------------+ | Collation | Charset | Id | Default | Compiled | Sortlen | Pad_attribute | +------------------------+---------+-----+---------+----------+---------+---------------+ | utf8mb4_unicode_520_ci | utf8mb4 | 246 | | Yes | 8 | PAD SPACE | | utf8mb4_unicode_ci | utf8mb4 | 224 | | Yes | 8 | PAD SPACE | +------------------------+---------+-----+---------+----------+---------+---------------+

mysql> show collation like '%utf8mb4_0900%'; +--------------------+---------+-----+---------+----------+---------+---------------+ | Collation | Charset | Id | Default | Compiled | Sortlen | Pad_attribute | +--------------------+---------+-----+---------+----------+---------+---------------+ | utf8mb4_0900_ai_ci | utf8mb4 | 255 | Yes | Yes | 0 | NO PAD | | utf8mb4_0900_as_ci | utf8mb4 | 305 | | Yes | 0 | NO PAD | | utf8mb4_0900_as_cs | utf8mb4 | 278 | | Yes | 0 | NO PAD | | utf8mb4_0900_bin | utf8mb4 | 309 | | Yes | 1 | NO PAD | +--------------------+---------+-----+---------+----------+---------+---------------+

Permalink - posted 2023-09-16

MySQL Unicode weirdness

After looking at the SQLite Unicode behavior, it's now time to do the same for MySQL. Coincidentally, I'm currently migrating some old databases that were created in the very early 2000s to a more modern environment. I think those old databases were from the MySQL 3.x days, before MySQL gained any sort of Unicode support. Those old tables are thus still in the latin1 (ISO 8859-1) character set.

But I encountered some MySQL/Unicode weirdness...

Read the article - posted 2023-09-21

Myhthbusters

20 years ago today, the TV show Mythbusters aired its first regular episode on the Discovery Channel, after three earlier pilot episodes. And soon after, I had found a new favorite TV show.

Read the article - posted 2023-09-23

BGP handling of obscure errors

I read Ben Cartwright Cox' (extensive) blog post Grave flaws in BGP Error handling and then saw his talk about the same topic at NLNOG on Youtube.

Here's the story.

Read the article - posted 2023-10-02

→ Enforcing First AS in BGP

The BGP RFCs state that external BGP peers should insert their own AS into the AS PATH advertised to eBGP peers. Some peers strip their AS, generally for commercial gain. Juniper and Cisco have opposite default behaviors for handling this. Make sure you set bgp enforce-first-as on Juniper routers. Caveats apply.

The annoying part here is that you want to disable this check for internet exchange route servers, but keep it enabled for everything else for security reasons. But that's not universally possible, as on some routers this is a global setting, rather than a per-neighbor one.

Read the article - posted 2023-10-08

→ The beauty of finished software

Finished software is software that’s not expected to change, and that’s a feature! You can rely on it to do some real work.

We need more of this.

But: how do you write software that will keep working for decades to come? Certainly don't look at Apple for this, they keep changing their CPU architectures every decade or so and after a transition period, the old stuff is dead.

Could WebAssembly be the solution? This is a pretty fast binary format that almost any programming language can be compiled to.

Read the article - posted 2023-11-01

Skyline #21, winter is coming...!

Image link - posted 2023-11-30

Skyline #22, shortest day of the year edition

Image link - posted 2023-12-22

Search for:

Archives: 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024