EXT4 error loading journal after power cut

Feb 28 09:15:15 nuc kernel: JBD2: journal reset failed
Feb 28 09:15:15 nuc kernel: EXT4-fs (sdc1): error loading journal

The above was in journalctl when mount command failed.

So tried fsck

$ sudo fsck /dev/sdc1
fsck from util-linux 2.39.3
e2fsck 1.47.0 (5-Feb-2023)
/dev/sdc1: recovering journal
/dev/sdc1 has gone 66 days without being checked, check forced.
Pass 1: Checking inodes, blocks, and sizes
Inode 118489333 extent tree (at level 2) could be narrower.  Optimize<y>? yes

Inode 118489579 extent tree (at level 1) could be narrower.  Optimize<y>? yes
Inode 118489629 extent tree (at level 2) could be narrower.  Optimize<y>? yes
Inode 118489674 extent tree (at level 1) could be narrower.  Optimize<y>? yes
Inode 236848701 extent tree (at level 1) could be shorter.  Optimize<y>? yes
Pass 1E: Optimizing extent trees
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
Free blocks count wrong (203470928, counted=202796926).
Fix<y>? yes
/dev/sdc1: ***** FILE SYSTEM WAS MODIFIED *****
/dev/sdc1: 1818337/244187136 files (0.2% non-contiguous), 773948802/976745728 blocks

After fsck I tried mount and ls which took some time, but fortunately it worked

Multimedia keys for YouTube Music Desktop App

After installing YouTube Music Desktop App and enabling plugin Shortcuts it’s possible to use D-bus commands.

I had to identify the bus so ended up with https://unix.stackexchange.com/a/46309/39470

dbus-send --print-reply --dest=org.freedesktop.DBus /org/freedesktop/DBus org.freedesktop.DBus.ListNames
      string "org.mozilla.thunderbird.ZGVmYXVsdA__"
      string "org.mpris.MediaPlayer2.brave.instance1661"
      string "org.mpris.MediaPlayer2.youtube-music"
      string "org.pulseaudio.Server"

Now I could test if it works

dbus-send --print-reply --dest=org.mpris.MediaPlayer2.youtube-music /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.PlayPause

dbus-send --print-reply --dest=org.mpris.MediaPlayer2.youtube-music /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Next

dbus-send --print-reply --dest=org.mpris.MediaPlayer2.youtube-music /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Previous

$keepRequestMethod must be of type bool, null given

Just received error response

{"title":"Internal Server Error","detail":"Symfony\\Bundle\\FrameworkBundle\\Controller\\RedirectController::urlRedirectAction(): Argument #7 ($keepRequestMethod) must be of type bool, null given, called in \/var\/www\/vendor\/symfony\/http-kernel\/HttpKernel.php on line 163"}

It appeared on URL http://auth.dev/api/v2/manual-oauth-token/login/?vendor=mpc

Solution in my case was removing slash before question mark
http://auth.dev/api/v2/manual-oauth-token/login?vendor=mpc

Fixing ERR_SSL_PROTOCOL_ERROR for t.co

I was receiving ERR_SSL_PROTOCOL_ERROR always for any t.co URL. It was so annoying to open it via Tor Browser (via it it worked)

Just accidentally after pinging that host I spotted it’s resolved to localhost :facepalm:

So I checked my PiHole and via the section Find Blocked Domain In Lists I found the root cause.

Exact match for t.co found in:
 - https://pgl.yoyo.org/adservers/serverlist.php?hostformat=hosts&showintro=1&mimetype=plaintext

So I headed to Domain management and whitelisted t.co

Heureka, finally can open links without any hassle.

Intel NUC BIOS upgrade

I just wanted to enable auto power on after outage so I just searched based on my BIOS version MYBDWi5v.86A.0048.2018.0709.2009 and spotted that a new BIOS MYBDWi5v.86A.0059.2022.0706.2207 is available https://www.intel.com/content/www/us/en/download/18110/bios-update-mybdwi5v.html for my Intel NUC5i5MYBE.

After checking out the release notes what was fixed, is the upgrade worth the time I spotted the magic sentence “Fixed issue where system hangs during POST when Western Digital 1TB MyPassport external USB drive is connected”
Exactly the issue I was having with my WD MyPassport USB disks. Now it was no question if I’m into the upgrade.

Unfortunately the upgrade wasn’t without troubles so it took a bit more time then I planned.

I took the F7 approach via Visual BIOS from https://www.intel.com/content/dam/support/us/en/documents/mini-pcs/Visual-BIOS-Update-NUC.pdf

After successful upgrade I wanted to modify some BIOS settings, after pressing F2 I ended up with a hanging “Entering setup” prompt. Checked https://www.intel.com/content/www/us/en/support/articles/000005847/intel-nuc.html, but didn’t help.

Here https://community.roonlabs.com/t/intel-nuc8i5beh3-cant-access-bios/61155/5 I read about the 3 second power button hold after which the power menu shows up. Maybe the issue was due Fast Boot https://www.intel.com/content/www/us/en/support/articles/000006699/intel-nuc.html, but I also tried switching HDMI cable from smart TV to a monitor which showed the same, BUT after switching ports on NUC from HDMI 2 to HDMI 1 finally I saw the Visual BIOS.

Honestly I don’t know which step helped, but finally I’m after a successful BIOS upgrade.

Download Vimeo video with yt-dlp

You might try downloading Vimeo video with yt-dlp

On the Vimeo page open browser developer tools, switch to Network tab and in search input type master.json or json

After getting the URL to master.json replace json with mpd and execute yt-dlp, e.g.

yt-dlp https://38vod-adaptive.akamaized.net/exp\=1677605361\~acl\=%2F33d6eda6-8b26-42a6-8a0d-b673968a71dd%2F%2A\~hmac\=10886bcd6adf633ba77d6348ed10bd50d58e3036a7b8190693a977520364419f/33d6eda6-8b26-42a6-8a0d-b67396
8a71dd/sep/video/2ed2bbd4,469ee94e,7dab4c14,b878a1f6,c6a872da/audio/37fae490,a2778785,f91cbeb3/master.mpd

Prune docker data after system resumes from sleep

Almost daily I need to issue docker system prune and today my mind came up with the idea to do it daily after I resume my desktop from sleep.

So I created and enabled the following systemd service

# /etc/systemd/system/resume.service
[Unit]
Description=Prune docker data

[Service]
Type=simple
ExecStart=docker system prune -f

[Install]
WantedBy=suspend.target
WantedBy=hibernate.target
WantedBy=hybrid-sleep.target