From 234e09358479cedc985579e125adc1f32497bf30 Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Tue, 30 Apr 2024 13:14:10 +0300 Subject: Update content for gemtext --- ...4-04-01-KISS-high-availability-with-OpenBSD.gmi | 26 +- gemfeed/atom.xml | 522 +++++++++++---------- index.gmi | 2 +- notes/influence-wihout-authority.gmi.tpl | 55 +++ uptime-stats.gmi | 2 +- 5 files changed, 333 insertions(+), 274 deletions(-) create mode 100644 notes/influence-wihout-authority.gmi.tpl diff --git a/gemfeed/2024-04-01-KISS-high-availability-with-OpenBSD.gmi b/gemfeed/2024-04-01-KISS-high-availability-with-OpenBSD.gmi index f4c33f9c..656cd33e 100644 --- a/gemfeed/2024-04-01-KISS-high-availability-with-OpenBSD.gmi +++ b/gemfeed/2024-04-01-KISS-high-availability-with-OpenBSD.gmi @@ -28,18 +28,20 @@ _____|_:_:_| (o)-(o) |_:_:_|--'`-. ,--. ksh under-water (((\'/ ``` ``` -Table of contents: - KISS high-availability with OpenBSD - My auto-failover requirements - My HA solution - Only OpenBSD base installation required - Fairly cheap and geo-redundant - Failover time and split-brain - Failover support for multiple protocols - Let's encrypt TLS certificates - Monitoring - Rex automation - More HA +Table of contents +================= + +KISS high-availability with OpenBSD + My auto-failover requirements + My HA solution + Only OpenBSD base installation required + Fairly cheap and geo-redundant + Failover time and split-brain + Failover support for multiple protocols + Let's encrypt TLS certificates + Monitoring + Rex automation + More HA ``` I have always wanted a highly available setup for my personal websites. I could have used off-the-shelf hosting solutions or hosted my sites in an AWS S3 bucket. I have used technologies like (in unsorted and slightly unrelated order) BGP, LVS/IPVS, ldirectord, Pacemaker, STONITH, scripted VIP failover via ARP, heartbeat, heartbeat2, Corosync, keepalived, DRBD, and commercial F5 Load Balancers for high availability at work. diff --git a/gemfeed/atom.xml b/gemfeed/atom.xml index d9f9521d..746bdd7b 100644 --- a/gemfeed/atom.xml +++ b/gemfeed/atom.xml @@ -1,6 +1,6 @@ - 2024-04-27T21:58:16+03:00 + 2024-04-30T13:13:33+03:00 foo.zone feed To be in the .zone! @@ -18,7 +18,7 @@ These are my personal takeaways after reading 'Slow Productivity - The lost Art of Accomplishment Without Burnout' by Cal Newport.
-

"Slow Productivity" book notes


+

"Slow Productivity" book notes



Published at 2024-04-27T14:18:51+03:00

@@ -42,7 +42,7 @@
"Slow productivity" does not mean being less productive. Cal Newport wants to point out that you can be much more productive with "slow productivity" than you would be without it. It is a different way of working than most of us are used to in the modern workplace, which is hyper-connected and always online.

-

Pseudo-productivity and Shallow work


+

Pseudo-productivity and Shallow work



People use visible activity instead of real productivity because it's easier to measure. This is called pseudo-productivity.
Pseudo-productivity is used as a proxy for real productivity. If you don't look busy, you are dismissed as lazy or lacking a work ethic.
@@ -51,7 +51,7 @@
Shallow work usually doesn't help you to accomplish big things. Always have the big picture in mind. Shallow work can't be entirely eliminated, but it can be managed—for example, plan dedicated time slots for certain types of shallow work.

-

Accomplishments without burnout


+

Accomplishments without burnout



The overall perception is that if you want to accomplish something, you must put yourself on the verge of burnout. Cal Newport writes about "The lost Art of Accomplishments without Burnouts", where you can accomplish big things without all the stress usually involved.

@@ -62,7 +62,7 @@
  • Work at a natural pace
  • Obsess over quality

  • -

    Do fewer things


    +

    Do fewer things



    There will always be more work. The faster you finish it, the quicker you will have something new on your plate.

    @@ -96,7 +96,7 @@
    Put tasks on autopilot (regular recurring tasks).

    -

    Work at a natural pace


    +

    Work at a natural pace



    We suffer from overambitious timelines, task lists, and business. Focus on what matters. Don't rush your most important work to achieve better results.

    @@ -112,7 +112,7 @@
    Schedule slow seasons (e.g., when on vacation). Disconnect in the slow season. Doing nothing will not satisfy your mind, though. You could read a book on your subject matter to counteract that.

    -

    Obsess over quality


    +

    Obsess over quality



    Obsess over quality even if you lose short-term opportunities by rejecting other projects. Quality demands you slow down. The two previous two principles (do fewer things and work at a natural pace) are mandatory for this principle to work:

    @@ -175,7 +175,7 @@ Art by Michael J. Penick (mod. by Paul B.)
    -

    KISS high-availability with OpenBSD


    +

    KISS high-availability with OpenBSD



    Published at 2024-03-30T22:12:56+02:00

    @@ -205,18 +205,20 @@ _____|_:_:_| (o)-(o) |_:_:_|--'`-. ,--. ksh under-water (((\'/
    -Table of contents:
    -    KISS high-availability with OpenBSD
    -        My auto-failover requirements
    -        My HA solution
    -            Only OpenBSD base installation required
    -            Fairly cheap and geo-redundant
    -            Failover time and split-brain
    -            Failover support for multiple protocols
    -            Let's encrypt TLS certificates
    -            Monitoring
    -            Rex automation
    -        More HA
    +Table of contents
    +=================
    +
    +KISS high-availability with OpenBSD
    +    My auto-failover requirements
    +    My HA solution
    +        Only OpenBSD base installation required
    +        Fairly cheap and geo-redundant
    +        Failover time and split-brain
    +        Failover support for multiple protocols
    +        Let's encrypt TLS certificates
    +        Monitoring
    +        Rex automation
    +    More HA
     

    I have always wanted a highly available setup for my personal websites. I could have used off-the-shelf hosting solutions or hosted my sites in an AWS S3 bucket. I have used technologies like (in unsorted and slightly unrelated order) BGP, LVS/IPVS, ldirectord, Pacemaker, STONITH, scripted VIP failover via ARP, heartbeat, heartbeat2, Corosync, keepalived, DRBD, and commercial F5 Load Balancers for high availability at work.
    @@ -227,7 +229,7 @@ Table of contents:
    PS: ASCII-art reflects an OpenBSD under-water world with all the tools available in the base system.

    -

    My auto-failover requirements


    +

    My auto-failover requirements



    • Be OpenBSD-based (I prefer OpenBSD because of the cleanliness and good documentation) and rely on as few external packages as possible.
    • @@ -240,9 +242,9 @@ Table of contents:
    • Have good monitoring in place so I know when a failover was performed and when something went wrong with the failover.
    • Don't configure everything manually. The configuration should be automated and reproducible.

    -

    My HA solution


    +

    My HA solution



    -

    Only OpenBSD base installation required


    +

    Only OpenBSD base installation required



    My HA solution for Web and Gemini is based on DNS (OpenBSD's nsd) and a simple shell script (OpenBSD's ksh and some little sed and awk and grep). All software used here is part of the OpenBSD base system and no external package needs to be installed - OpenBSD is a complete operating system.

    @@ -398,7 +400,7 @@ echo "Failover of zone $zone to $MASTER completed"
    dns-failover.ksh

    -

    Fairly cheap and geo-redundant


    +

    Fairly cheap and geo-redundant



    I am renting two small OpenBSD VMs: One at OpenBSD Amsterdam and the other at Hetzner Cloud. So, both VMs are hosted at another provider, in different IP subnets, and in different countries (the Netherlands and Germany).

    @@ -409,13 +411,13 @@ echo "Failover of zone $zone to $MASTER completed"
    A DNS-based failover is cheap, as there isn't any BGP or fancy load balancer to pay for. Small VMs also cost less than millions.

    -

    Failover time and split-brain


    +

    Failover time and split-brain



    A DNS failover doesn't happen immediately. I've configured a DNS TTL of 300 seconds, and the failover script checks once per minute whether to perform a failover or not. So, in total, a failover can take six minutes (not including other DNS caching servers somewhere in the interweb, but that's fine - eventually, all requests will resolve to the new master after a failover).

    A split-brain scenario between the old master and the new master might happen. That's OK, as my sites are static, and there's no database to synchronise other than HTML, CSS, and images when the site is updated.

    -

    Failover support for multiple protocols


    +

    Failover support for multiple protocols



    With the DNS failover, HTTP, HTTPS, and Gemini protocols are failovered. This works because all domain virtual hosts are configured on either VM's httpd (OpenBSD's HTTP server) and relayd (it's also part of OpenBSD and I use it to TLS offload the Gemini protocol). So, both VMs accept requests for all the hosts. It's just a matter of the DNS entries, which VM receives the requests.

    @@ -426,7 +428,7 @@ echo "Failover of zone $zone to $MASTER completed"
    On DNS failover, master and standby swap roles without config changes other than the DNS entries. That's KISS (keep it simple and stupid)!

    -

    Let's encrypt TLS certificates


    +

    Let's encrypt TLS certificates



    All my hosts use TLS certificates from Let's Encrypt. The ACME automation for requesting and keeping the certificates valid (up to date) requires that the host requesting a certificate from Let's Encrypt is also the host using that certificate.

    @@ -463,7 +465,7 @@ http://www.gnu.org/software/src-highlite --> https://man.OpenBSD.org/acme-client.1
    Let's Encrypt with OpenBSD and Rex

    -

    Monitoring


    +

    Monitoring



    CRON is sending me an E-Mail whenever a failover is performed (or whenever a failover failed). Furthermore, I am monitoring my DNS servers and hosts through Gogios, the monitoring system I have developed.

    @@ -472,7 +474,7 @@ http://www.gnu.org/software/src-highlite -->
    Gogios, as I developed it by myself, isn't part of the OpenBSD base system.

    -

    Rex automation


    +

    Rex automation



    I use Rexify, a friendly configuration management system that allows automatic deployment and configuration.

    @@ -481,7 +483,7 @@ http://www.gnu.org/software/src-highlite -->
    Rex isn't part of the OpenBSD base system, but I didn't need to install any external software on OpenBSD either as Rex is invoked from my Laptop!

    -

    More HA


    +

    More HA



    Other high-available services running on my OpenBSD VMs are my MTAs for mail forwarding (OpenSMTPD - also part of the OpenBSD base system) and the authoritative DNS servers (nsd) for all my domains. No particular HA setup is required, though, as the protocols (SMTP and DNS) already take care of the failover to the next available host!

    @@ -519,7 +521,7 @@ http://www.gnu.org/software/src-highlite --> I am an ideas person. I find myself frequently somewhere on the streets with an idea in my head but no paper journal noting it down.
    -

    A fine Fyne Android app for quickly logging ideas programmed in Go


    +

    A fine Fyne Android app for quickly logging ideas programmed in Go



    Published at 2024-03-03T00:07:21+02:00

    @@ -551,7 +553,7 @@ http://www.gnu.org/software/src-highlite -->
    My Android apps will never be polished, but they will get the job done, and this is precisely how I want them to be. Minimalistic but functional. I could spend more time polishing Quick logger, but my Quick logger app then may be the same as any other notes app out there (complicated or bloated).

    -

    All easy-peasy?


    +

    All easy-peasy?



    I did have some issues with the app logo for Android, though. Android always showed the default app icon and not my custom icon whenever I used a custom AndroidManifest.xml for custom app storage permissions. Without a custom AndroidAmnifest.xml the app icon would be displayed under Android, but then the app would not have the MANAGE_EXTERNAL_STORAGE permission, which is required for Quick logger to write to a custom directory. I found a workaround, which I commented on here at Github:

    @@ -768,7 +770,7 @@ http://www.gnu.org/software/src-highlite --> HKISSFISHKISSFISHKISSFISHKISSFISH KISS
    -

    One reason why I love OpenBSD


    +

    One reason why I love OpenBSD



    Published at 2024-01-13T22:55:33+02:00

    @@ -849,7 +851,7 @@ $ doas reboot # Just in case, reboot one more timeThis is the third part of my Site Reliability Engineering (SRE) series. I am currently employed as a Site Reliability Engineer and will try to share what SRE is about in this blog series.
    -

    Site Reliability Engineering - Part 3: On-Call Culture and the Human Aspect


    +

    Site Reliability Engineering - Part 3: On-Call Culture and the Human Aspect



    Published at 2024-01-09T18:35:48+02:00

    @@ -885,7 +887,7 @@ $ doas reboot # Just in case, reboot one more time
    -

    On-Call Culture and the Human Aspect: Prioritising Well-being in the Realm of Reliability


    +

    On-Call Culture and the Human Aspect: Prioritising Well-being in the Realm of Reliability



    Site Reliability Engineering is synonymous with ensuring system reliability, but the human factor is an often-underestimated part of this discipline. Ensuring an healthy on-call culture is as critical as any technical solution. The well-being of the engineers is an important factor.

    @@ -921,7 +923,7 @@ $ doas reboot # Just in case, reboot one more timeThis is the third blog post about my Bash Golf series. This series is random Bash tips, tricks, and weirdnesses I have encountered over time.
    -

    Bash Golf Part 3


    +

    Bash Golf Part 3



    Published at 2023-12-10T11:35:54+02:00

    @@ -942,7 +944,7 @@ jgs^^^^^^^`^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 2022-01-01 Bash Golf Part 2
    2023-12-10 Bash Golf Part 3 (You are currently reading this)

    -

    FUNCNAME


    +

    FUNCNAME



    FUNCNAME is an array you are looking for a way to dynamically determine the name of the current function (which could be considered the callee in the context of its own execution), you can use the special variable FUNCNAME. This is an array variable that contains the names of all shell functions currently in the execution call stack. The element FUNCNAME[0] holds the name of the currently executing function, FUNCNAME[1] the name of the function that called that, and so on.

    @@ -982,7 +984,7 @@ http://www.gnu.org/software/src-highlite --> INFO|20231210-082732|123002|at_home_friday_evening|One Peperoni Pizza, please
    -

    :(){ :|:& };:


    +

    :(){ :|:& };:



    This one may be widely known already, but I am including it here as I found a cute image illustrating it. But to break :(){ :|:& };: down:

    @@ -1005,7 +1007,7 @@ INFO|20231210- Bash fork bomb

    -

    Inner functions


    +

    Inner functions



    Bash defines variables as it is interpreting the code. The same applies to function declarations. Let's consider this code:

    @@ -1074,7 +1076,7 @@ Wintel inside! Wintel inside!
    -

    Exporting functions


    +

    Exporting functions



    Have you ever wondered how to execute a shell function in parallel through xargs? The problem is that this won't work:

    @@ -1164,7 +1166,7 @@ http://www.gnu.org/software/src-highlite -->
    ... because some_other_function isn't exported! You will also need to add an export -f some_other_function!

    -

    Dynamic variables with local


    +

    Dynamic variables with local



    You may know that local is how to declare local variables in a function. Most don't know that those variables actually have dynamic scope. Let's consider the following example:

    @@ -1204,7 +1206,7 @@ foo What happened? The variable foo (declared with local) is available in the function it was declared in and in all other functions down the call stack! We can even modify the value of foo, and the change will be visible up the call stack. It's not a global variable; on the last line, echo "$foo" echoes the global variable content.


    -

    if conditionals


    +

    if conditionals



    Consider all variants here more or less equivalent:

    @@ -1255,7 +1257,7 @@ ok4a ok4b
    -

    Multi-line comments


    +

    Multi-line comments



    You all know how to comment. Put a # in front of it. You could use multiple single-line comments or abuse heredocs and redirect it to the : no-op command to emulate multi-line comments.

    @@ -1279,7 +1281,7 @@ COMMENT
    I will not demonstrate the execution of this script, as it won't print anything! It's obviously not the most pretty way of commenting on your code, but it could sometimes be handy!

    -

    Don't change it while it's executed


    +

    Don't change it while it's executed



    Consider this script:

    @@ -1338,7 +1340,7 @@ echo baz This is the second part of my Site Reliability Engineering (SRE) series. I am currently employed as a Site Reliability Engineer and will try to share what SRE is about in this blog series.
    -

    Site Reliability Engineering - Part 2: Operational Balance in SRE


    +

    Site Reliability Engineering - Part 2: Operational Balance in SRE



    Published at 2023-11-19T00:18:18+03:00

    @@ -1363,7 +1365,7 @@ echo baz ⠀⠀⠀⠀⠀⠀⠴⠶⠿⠿⠿⠿⠿⠿⠿⠿⠿⠿⠿⠿⠿⠿⠶⠦⠀⠀
    -

    Operational Balance in SRE: Finding the Equilibrium in Reliability and Velocity


    +

    Operational Balance in SRE: Finding the Equilibrium in Reliability and Velocity



    Site Reliability Engineering has established itself as more than just a set of best practices or methodologies. Instead, it stands as a beacon of operational excellence, which guides engineering teams through the turbulent waters of modern software development and system management.

    @@ -1403,7 +1405,7 @@ echo baz These are my personal takeaways after reading 'Mind Management' by David Kadavy. Note that the book contains much more knowledge wisdom and that these notes only contain points I personally found worth writing down. This is mainly for my own use, but you might find it helpful too.
    -

    "Mind Management" book notes


    +

    "Mind Management" book notes



    Published at 2023-11-11T22:21:47+02:00

    @@ -1427,11 +1429,11 @@ echo baz
  • The point of diminishing returns
  • The point of negative return

  • -

    Empty slots in the calendar


    +

    Empty slots in the calendar



    If we do more things in less time and use all possible slots, speed read, etc., we are more productive. But in reality, that's not the entire truth. You also exchange one thing against everything else.... You cut out too much from your actual life.

    -

    When you safe time...


    +

    When you safe time...



    ...keep it.

    @@ -1440,7 +1442,7 @@ echo baz
  • Creative thinking needs space. It will pay dividends tomorrow.
  • You will be rewarded with the "Eureka effect" - a sudden new insight.

  • -

    Follow your mood


    +

    Follow your mood



    Ask yourself: what is my mood now? We never have the energy to do anything, so the better strategy is to follow your current mode and energy. E.g.:

    @@ -1448,7 +1450,7 @@ echo baz
  • Didn't sleep enough today? Then, do simple, non-demanding tasks at work
  • Had a great sleep, and there is even time before work starts? Pull in a workout...

  • -

    Boosting creativity


    +

    Boosting creativity



    The morning without coffee is a gift for creativity, but you often get distracted. Minimize distractions, too. I have no window to stare out but a plain blank wall.

    @@ -1458,7 +1460,7 @@ echo baz
  • Don't race with time but walk alongside it as rough time lines.
  • Don't judge every day after the harvest, but the seed you lay

  • -

    The right mood for the task at hand


    +

    The right mood for the task at hand



    We need to try many different combinations. Limiting ourselves and trying too hard makes us frustrated and burn out. Creativity requires many iterations.

    @@ -1472,7 +1474,7 @@ echo baz
    It gives you pleasure and is in a good mood. This increases creativity if you do what you want to do.

    -

    Creativity hacks


    +

    Creativity hacks



    • Coffee can cause anxiety.
    • @@ -1483,7 +1485,7 @@ echo baz
    • Go to open spaces for creativity.
    • Go to closed spaces for polishing.

    -

    Planning and strategizing


    +

    Planning and strategizing



    Minds work better in sprints and not in marathons. Have a weekly plan, not a daily one.

    @@ -1496,7 +1498,7 @@ echo baz
    You could schedule exploratory tasks when you are under grief. Sound systems should create slack for creativity. Plan only for a few minutes.

    -

    Fake it until you make it.


    +

    Fake it until you make it.



    • E.g. act calm if you want to be calm.
    • @@ -1531,7 +1533,7 @@ echo baz Once in a while, I share photos on the inter-web with either family and friends or on my The Irregular Ninja photo site. One hobby of mine is photography (even though I don't have enough time for it - so I am primarily a point-and-shoot photographer).
      -

      KISS static web photo albums with photoalbum.sh


      +

      KISS static web photo albums with photoalbum.sh



      Published at 2023-10-29T22:25:04+02:00

      @@ -1552,7 +1554,7 @@ echo baz '._____________________________________________.'
      -

      Motivation


      +

      Motivation



      Once in a while, I share photos on the inter-web with either family and friends or on my The Irregular Ninja photo site. One hobby of mine is photography (even though I don't have enough time for it - so I am primarily a point-and-shoot photographer).

      @@ -1560,11 +1562,11 @@ echo baz
      I value KISS (keep it simple and stupid) and simplicity. All that's required for a web photo album is some simple HTML and spice it up with CSS. No need for JavaScript, no need for a complex dynamic website.

      -

      Introducing photoalbum.sh


      +

      Introducing photoalbum.sh



      photoalbum.sh is a minimal Bash (Bourne Again Shell) script for Unix-like operating systems (such as Linux) to generate static web photo albums. The resulting static photo album is pure HTML+CSS (without any JavaScript!). It is specially designed to be as simple as possible.

      -

      Installation


      +

      Installation



      Installation is straightforward. All required is a recent version of GNU Bash, GNU Make, Git and ImageMagick. On Fedora, the dependencies are installed with:

      @@ -1607,7 +1609,7 @@ cp ./src/photoalbum.default.conf /etc/default/photoalbum This is Photoalbum Version 0.5.1
      -

      Setting it up


      +

      Setting it up



      Now, it's time to set up the Irregular Ninja static web photo album (or any other web photo album you may be setting up!)! Create a directory (here: irregular.ninja for the Irregular Ninja Photo site - or any oter sub-directory reflecting your album's name), and inside of that directory, create an incoming directory. The incoming directory. Copy all photos to be part of the album there.

      @@ -1720,7 +1722,7 @@ http://www.gnu.org/software/src-highlite -->
      So I changed the album title, adjusted some image and thumbnail dimensions, and I want all images to be randomly shuffled every time the album is generated! I also have all my photos in my Nextcloud Photo directory and don't want to copy them to the local incoming directory. Also, a tarball containing the whole album as a download isn't provided.

      -

      Generating the static photo album


      +

      Generating the static photo album



      Let's generate it. Depending on the image sizes and count, the following step may take a while.

      @@ -1783,15 +1785,15 @@ blurs html index.html photos thumbs
      PS: There's also a server-side synchronisation script mirroring the same content to another server for high availability reasons (out of scope for this blog post).

      -

      Cleaning it up


      +

      Cleaning it up



      A simple make clean will clean up the ./dist directory and all other (if any) temp files created.

      -

      HTML templates


      +

      HTML templates



      Poke around in this source directory. You will find a bunch of Bash-HTML template files. You could tweak them to your liking.

      -

      Conclusion


      +

      Conclusion



      A decent looking (in my opinion, at least) in less than 500 (273 as of this writing, to be precise) lines of Bash code and with minimal dependencies; what more do you want? How many LOCs would this be in Raku with the same functionality (can it be sub-100?).

      @@ -1829,7 +1831,7 @@ blurs html index.html photos thumbs Hey there. As I am pretty busy this month personally (I am now on Paternity Leave) and as I still want to post once monthly, the blog post of this month will only be some DTail usage examples. They're from the DTail documentation, but not all readers of my blog may be aware of those!
      -

      DTail usage examples


      +

      DTail usage examples



      Published at 2023-09-25T14:57:42+03:00

      @@ -1863,7 +1865,7 @@ blurs html index.html photos thumbs
    • Use dmap to aggregate logs and other text files already written
    • dserver is the DTail server, where all the clients can connect to

    -

    Following logs


    +

    Following logs



    The following example demonstrates how to follow logs of several servers at once. The server list is provided as a flat text file. The example filters all records containing the string INFO. Any other Go compatible regular expression can also be used instead of INFO.

    @@ -1887,7 +1889,7 @@ http://www.gnu.org/software/src-highlite -->
    % dtail --servers serverlist.txt --grep INFO "/var/log/dserver/*.log"
     

    -

    Aggregating logs


    +

    Aggregating logs



    To run ad-hoc map-reduce aggregations on newly written log lines you must add a query. The following example follows all remote log lines and prints out every few seconds the result to standard output.

    @@ -1944,7 +1946,7 @@ http://www.gnu.org/software/src-highlite --> --query 'from STATS select ... outfile append result.csv'
    -

    How to use dcat


    +

    How to use dcat



    The following example demonstrates how to cat files (display the full content of the files) on several servers at once.

    @@ -1968,7 +1970,7 @@ http://www.gnu.org/software/src-highlite -->
    % dcat --servers serverlist.txt /etc/hostname
     

    -

    How to use dgrep


    +

    How to use dgrep



    The following example demonstrates how to grep files (display only the lines which match a given regular expression) of multiple servers at once. In this example, we look after some entries in /etc/passwd. This time, we don't provide the server list via an file but rather via a comma separated list directly on the command line. We also explore the -before, -after and -max flags (see animation).

    @@ -1987,7 +1989,7 @@ http://www.gnu.org/software/src-highlite -->
    Hint: -regex is an alias for -grep.

    -

    How to use dmap


    +

    How to use dmap



    To run a map-reduce aggregation over logs written in the past, the dmap command can be used. The following example aggregates all map-reduce fields dmap will print interim results every few seconds. You can also write the result to an CSV file by adding outfile result.csv to the query.

    @@ -2005,7 +2007,7 @@ http://www.gnu.org/software/src-highlite -->
    DMap example

    -

    How to use the DTail serverless mode


    +

    How to use the DTail serverless mode



    Until now, all examples so far required to have remote server(s) to connect to. That makes sense, as after all DTail is a *distributed* tool. However, there are circumstances where you don't really need to connect to a server remotely. For example, you already have a login shell open to the server an all what you want is to run some queries directly on local log files.

    @@ -2013,7 +2015,7 @@ http://www.gnu.org/software/src-highlite -->
    All commands shown so far also work in a serverless mode. All what needs to be done is to omit a server list. The DTail client then starts in serverless mode.

    -

    Serverless map-reduce query


    +

    Serverless map-reduce query



    The following dmap example is the same as the previously shown one, but the difference is that it operates on a local log file directly:

    @@ -2048,7 +2050,7 @@ http://www.gnu.org/software/src-highlite --> lifetimeConnections group by $hostname order by max($cgocalls)'
    -

    Aggregating CSV files


    +

    Aggregating CSV files



    In essence, this works exactly like aggregating logs. All files operated on must be valid CSV files and the first line of the CSV must be the header. E.g.:

    @@ -2070,7 +2072,7 @@ Einstein,Albert
    DMap can also be used to query and aggregate CSV files from remote servers.

    -

    Other serverless commands


    +

    Other serverless commands



    The serverless mode works transparently with all other DTail commands. Here are some examples:

    @@ -2149,7 +2151,7 @@ http://www.gnu.org/software/src-highlite --> The universe of Site Reliability Engineering (SRE) is like an intricate tapestry woven with diverse technology, culture, and personal grit threads. Site Reliability Engineering is one of the most demanding jobs. With all the facets, it's impossible to get bored. There is always a new challenge to master, and there is always a new technology to tinker with. It's not just technical; it's also about communication, collaboration and teamwork. I am currently employed as a Site Reliability Engineer and will try to share what SRE is about in this blog series.
    -

    Site Reliability Engineering - Part 1: SRE and Organizational Culture


    +

    Site Reliability Engineering - Part 1: SRE and Organizational Culture



    Published at 2023-08-18T22:43:47+03:00

    @@ -2181,7 +2183,7 @@ DC on fire: ░░░░░░░░░░▒▒░░░░░░░░░░░░░░░░░░░░░░░░▒▒░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░▒▒░░░░░░░░░░░░░░░░░░
    -

    SRE and Organizational Culture: Navigating the Nexus


    +

    SRE and Organizational Culture: Navigating the Nexus



    At the heart of SRE lies the proactive mindset of "prevention over cure." Traditional IT models focused predominantly on reactive solutions, but SRE mandates a shift towards foresight. By adopting Service Level Indicators (SLIs) and Service Level Objectives (SLOs), teams are equipped with clear metrics and goals that guide them toward ensuring reliability and user satisfaction. They reflect an organisational culture prioritising user experience and constant system alignment with user needs.

    @@ -2223,7 +2225,7 @@ DC on fire: I proudly announce that I've released Gemtexter version `2.1.0`. What is Gemtexter? It's my minimalist static site generator for Gemini Gemtext, HTML and Markdown, written in GNU Bash.
    -

    Gemtexter 2.1.0 - Let's Gemtext again³


    +

    Gemtexter 2.1.0 - Let's Gemtext again³



    Published at 2023-07-21T10:19:31+03:00

    @@ -2244,17 +2246,17 @@ DC on fire:
    https://codeberg.org/snonux/gemtexter

    -

    Why Bash?


    +

    Why Bash?



    This project is too complex for a Bash script. Writing it in Bash was to try out how maintainable a "larger" Bash script could be. It's still pretty maintainable and helps me try new Bash tricks here and then!

    Let's list what's new!

    -

    Switch to GPL3 license


    +

    Switch to GPL3 license



    Many (almost all) of the tools and commands (GNU Bash, GMU Sed, GNU Date, GNU Grep, GNU Source Highlight) used by Gemtexter are licensed under the GPL anyway. So why not use the same? This was an easy switch, as I was the only code contributor so far!

    -

    Source code highlighting support


    +

    Source code highlighting support



    The HTML output now supports source code highlighting, which is pretty neat if your site is about programming. The requirement is to have the source-highlight command, which is GNU Source Highlight, to be installed. Once done, you can annotate a bare block with the language to be highlighted. E.g.:

    @@ -2279,11 +2281,11 @@ http://www.gnu.org/software/src-highlite -->
    Please run source-highlight --lang-list for a list of all supported languages.

    -

    HTML exact variant


    +

    HTML exact variant



    Gemtexter is there to convert your Gemini Capsule into other formats, such as HTML and Markdown. An HTML exact variant can now be enabled in the gemtexter.conf by adding the line declare -rx HTML_VARIANT=exact. The HTML/CSS output changed to reflect a more exact Gemtext appearance and to respect the same spacing as you would see in the Geminispace.

    -

    Use of Hack webfont by default


    +

    Use of Hack webfont by default



    The Hack web font is a typeface designed explicitly for source code. It's a derivative of the Bitstream Vera and DejaVu Mono lineage, but it features many improvements and refinements that make it better suited to reading and writing code.

    @@ -2291,7 +2293,7 @@ http://www.gnu.org/software/src-highlite -->
    Hack is open-source and freely available for use and modification under the MIT License.

    -

    HTML Mastodon verification support


    +

    HTML Mastodon verification support



    The following link explains how URL verification works in Mastodon:

    @@ -2321,7 +2323,7 @@ http://www.gnu.org/software/src-highlite -->
    <a href='https://fosstodon.org/@snonux' rel='me'>Me at Mastodon</a>
     

    -

    More


    +

    More



    Additionally, there were a couple of bug fixes, refactorings and overall improvements in the documentation made.

    @@ -2351,7 +2353,7 @@ http://www.gnu.org/software/src-highlite --> These notes are of two books by 'John Sommez' I found helpful. I also added some of my own keypoints to it. These notes are mainly for my own use, but you might find them helpful, too.
    -

    "Software Developmers Career Guide and Soft Skills" book notes


    +

    "Software Developmers Career Guide and Soft Skills" book notes



    Published at 2023-07-17T04:56:20+03:00

    @@ -2369,9 +2371,9 @@ http://www.gnu.org/software/src-highlite --> '''
    -

    Improve


    +

    Improve



    -

    Always learn new things


    +

    Always learn new things



    When you learn something new, e.g. a programming language, first gather an overview, learn from multiple sources, play around and learn by doing and not consuming and form your own questions. Don't read too much upfront. A large amount of time is spent in learning technical skills which were never use. You want to have a practical set of skills you are actually using. You need to know 20 percent to get out 80 percent of the results.

    @@ -2389,11 +2391,11 @@ http://www.gnu.org/software/src-highlite -->
    Boot camps: The advantage of a boot camp is to pragmatically learn things fast. We almost always overestimate what we can do in a day. Especially during boot camps. Connect to others during the boot camps

    -

    Set goals


    +

    Set goals



    Your own goals are important but the manager also looks at how the team performs and how someone can help the team perform better. Check whether you are on track with your goals every 2 weeks in order to avoid surprises for the annual review. Make concrete goals for next review. Track and document your progress. Invest in your education. Make your goals known. If you want something, then ask for it. Nobody but you knows what you want.

    -

    Ratings


    +

    Ratings



    That's a trap: If you have to rate yourself, that's a trap. That never works in an unbiased way. Rate yourself always the best way but rate your weakest part as high as possible minus one point. Rate yourself as good as you can otherwise. Nobody is putting for fun a gun on his own head.

    @@ -2401,7 +2403,7 @@ http://www.gnu.org/software/src-highlite -->
  • Don't do peer rating, it can fire back on you. What if the colleague becomes your new boss?
  • Cooperate rankings are unfortunately HR guidelines and politics and only mirror a little your actual performance.

  • -

    Promotions


    +

    Promotions



    The most valuable employees are the ones who make themselves obsolete and automate all away. Keep a safety net of 3 to 6 months of finances. Safe at least 10 percent of your earnings. Also, if you make money it does not mean that you have to spent more money. Is a new car better than a used car which both can bring you from A to B? Liability vs assets.

    @@ -2414,7 +2416,7 @@ http://www.gnu.org/software/src-highlite -->
  • If you want a raise be specific how much and know to back your demands. Don't make a thread and no ultimatums.
  • Best way for a promotion is to switch jobs. You can even switch back with a better salary.

  • -

    Finish things


    +

    Finish things



    Hard work is necessary for accomplish results. However, work smarter not harder. Furthermore, working smart is not a substitute for working hard. Work both, hard and smart.

    @@ -2429,7 +2431,7 @@ http://www.gnu.org/software/src-highlite -->
    Defeat is finally give up. Failure is the road to success, embrace it. Failure does not define you but how you respond to it. Events don't make your unhappy, but how you react to events do.

    -

    Expand the empire


    +

    Expand the empire



    The larger your empire is, the larger your circle of influence is. The larger the circle of influence is, the more opportunities you have.

    @@ -2440,7 +2442,7 @@ http://www.gnu.org/software/src-highlite -->
    Become visible, keep track that you accomplishments. E.g. write a weekly summary. Do presentations, be seen. Learn new things and share your learnings. Be the problem solver and not the blamer.

    -

    Be pragmatic and also manage your time


    +

    Be pragmatic and also manage your time



    Make use of time boxing via the Pomodoro technique: Set a target of rounds and track the rounds. That give you exact focused work time. That's really the trick. For example set a goal of 6 daily pomodores.

    @@ -2450,7 +2452,7 @@ http://www.gnu.org/software/src-highlite -->
    You should feel good of the work done even if you don't finished the task. You will feel good about pomodoro wise even you don't finish the task on hand yet. Helps you to enjoy time off more. Working longer may not sell anything.

    -

    The quota system


    +

    The quota system



    Defined quota of things done. E.g. N runs per week or M Blog posts per month or O pomodoros per week. This helps with consistency. Truly commit to these quotas. Failure is not an option. Start with small commitments. Don't commit to something you can't fulfill otherwise you set yourself up for failure.

    @@ -2459,7 +2461,7 @@ http://www.gnu.org/software/src-highlite -->
  • Internal motivation is more important over external motivation. Check out Daniels book drive.
  • Multitasking: Batching is effective. E.g. emails twice daily at pre-set times..

  • -

    Don't waste time


    +

    Don't waste time



    The biggest time waster is TV watching. The TV is programming you. It's insane that Americans watch so much TV as they work full time. Schedule one show at a time and watch it when you want to watch it. Most movies are crap anyways. The good movies will come to you as people will talk about them.

    @@ -2468,7 +2470,7 @@ http://www.gnu.org/software/src-highlite -->
  • Meetings can waste time as well. Simply don't go to them. Try to cancel meeting if it can be dealt with via email.
  • Enjoying things is not a waste of time. E.g. you could still play a game once in a while. It is important not to cut away all you enjoy from your life.

  • -

    Habits


    +

    Habits



    Try to have as many good habits as possible. Start with easy habits, and make them a little bit more challenging over time. Set ankers and rewards. Over time the routines will become habits naturally.

    @@ -2478,7 +2480,7 @@ http://www.gnu.org/software/src-highlite -->
  • We don't have control over our habits but our own routines.
  • Routines help to form the habits, though.

  • -

    Work-life balance


    +

    Work-life balance



    Avoid overwork hours. That's not as beneficial as you might think and comes only with very small rewards. Invest rather in yourself and not in your employer.

    @@ -2490,7 +2492,7 @@ http://www.gnu.org/software/src-highlite -->
    Use your most productive hours to work on you. Make that your priority. Take care of yourself a priority (E.g. do workouts or learn a new language). You can always workout 2 or 1 hour per day, but will you pay the price?

    -

    Mental health


    +

    Mental health



    • Friendships and positive thinking help to have and maintain better health, longer Life, better productivity and increased happiness.
    • @@ -2501,7 +2503,7 @@ http://www.gnu.org/software/src-highlite -->
      In most cases burnout is just an illusion. If you don't have motivation push through the wall. People usually don't pass the wall as they feel they are burned out. After pushing through the wall you will have the most fun, for example you will be able playing the guitar greatly.

      -

      Physical health


      +

      Physical health



      Utilise a standing desk and treadmill (you could walk and type at the same time). Increase the incline in order to burn more calories. Even on the standing desk you burn more calories than sitting. When you use pomodoro then you can use the small breaks for push-ups (maybe won't do as good when you are in a fasted state).

      @@ -2513,7 +2515,7 @@ http://www.gnu.org/software/src-highlite -->

    Intermittent fasting is an effective method to maintain weight and health. But it does not mean that you can only eat junk food in the feeding windows. Also, diet and nutrition is the most important for health and fitness. They make it also easier to stay focused and positive.

    -

    No drama


    +

    No drama



    Avoid drama at work. Where are humans there is drama. You can decide where to spent your energy in. But don't avoid conflict. Conflict is healthy in any kind of relationship. Be tactful and state your opinion. The goal is to find the best solution to the problem.

    @@ -2529,13 +2531,13 @@ http://www.gnu.org/software/src-highlite -->
    You have to learn how to work in a team. Be honest but tactful. It's not too be the loudest but about selling your ideas. Don't argue otherwise you won't sell anything. Be persuasive by finding the common ground. Or lead the colleagues to your idea and don't sell it upfront. Communicate clearly.

    -

    Personal brand


    +

    Personal brand



    • Invest your value outside the company. Build your personal brand. Show how valuable you are, also to other companies. Become an asset.
    • Invest in your education. Make your goals known. If you want something ask for it (see also the sections about goals in this document).

    -

    Market yourself


    +

    Market yourself



    • The best way to market yourself is to make you usable.
    • @@ -2548,11 +2550,11 @@ http://www.gnu.org/software/src-highlite -->
    • Have an elevator pitch: "buetow.org - Having fun with computers!"
    • Have social media accounts, especially the ones which are more tech related.

    -

    Networking


    +

    Networking



    Ask people so they talk about themselves. They are not really interested in you. Use meetup.com to find groups you are interested and build up the network over time. Don't drink on social networking events even when others do. Talking to other people at events only has upsides. Just saying "hi" and introducing yourself is enough. What worse can happen? If the person rejects you so what, life goes on. Ask open questions and no "yes" and "no" questions. E.g.: "What is your story, why are you here?".

    -

    Public speaking


    +

    Public speaking



    Before your talk go on stage 10 minutes in advance. Introduce yourself to the front row people. During the talk they will smile at you and encourage you during your talk.

    @@ -2562,9 +2564,9 @@ http://www.gnu.org/software/src-highlite -->
    Just do it. Just go to conferences. Even if you are not speaking. Sell your boss what you would learn and "this and that" and you would present the learnings to the team afterwards.

    -

    New job


    +

    New job



    -

    For the interview


    +

    For the interview



    • Build up a network before the interview. E.g., follow and comment blogs. Or go to meet-ups and conferences. Join user groups.
    • @@ -2573,7 +2575,7 @@ http://www.gnu.org/software/src-highlite -->

    If you are specialized then there is a better chance to get a fitting job. No one will hire a general lawyer if there are specialized lawyers available. Even if you are specialized, you will have a wide range of skills (T-shape knowledge).

    -

    Find the right type of company


    +

    Find the right type of company



    Not all companies are equal. They have individual cultures and guidelines.

    @@ -2585,7 +2587,7 @@ http://www.gnu.org/software/src-highlite -->
    Work in a tech. company if you want to work on/with cutting edge technologies.

    -

    Apply for the new