This is a quick guide to mounting a qcow2 disk images on your host server. This is useful to reset passwords, edit files, or recover something without the virtual machine running.
Step 1 - Enable NBD on the Host
modprobe nbd max_part=8
| #!/bin/sh | |
| set -euo pipefail | |
| umask 077 | |
| CA_DN="CN=IPsec Root CA" | |
| NODE_ID="ipsecXXXXXX" | |
| NODE_DN="CN=$NODE_ID" | |
| CERT_SIG_TYPE="RSA" |
| Homebrew build logs for virt-manager on macOS 26 | |
| Build date: 2026-04-10 12:40:31 |
| #ps1 | |
| $index = (Invoke-WebRequest -Uri 'https://cdn.media.ccc.de/INDEX' -Verbose).Content -split "`n" | ForEach-Object {$_.Trim()} | Where-Object {-not [String]::IsNullOrEmpty($_)} | |
| #$aria2cIndex = foreach($e in $index) { "https://cdn.media.ccc.de/$e"; " dir=./$(Split-Path -Parent $e)"; " out=$(Split-Path -Leaf $e)" } | |
| $aria2cIndex = foreach($e in $index) { | |
| "https://cdn.media.ccc.de/$e`thttps://berlin-ak.ftp.media.ccc.de/$e`thttps://mirror.selfnet.de/CCC/$e`thttps://ftp.fau.de/cdn.media.ccc.de/$e`thttps://mirror.eu.oneandone.net/projects/media.ccc.de/$e`thttps://mirrors.dotsrc.org/cdn.media.ccc.de/$e`thttps://koeln.ftp.media.ccc.de/$e`thttps://mirror.netcologne.de/CCC/$e" | |
| " dir=./$(Split-Path -Parent $e)" | |
| " out=$(Split-Path -Leaf $e)" | |
| } | |
| $aria2cIndex | Out-File -Encoding ascii -Path "./INDEX.aria2c.txt" |
| [submodule ".pyenv"] | |
| path = .pyenv | |
| url = https://github.com/pyenv/pyenv.git | |
| branch = master | |
| [submodule ".pyenv-doctor"] | |
| path = .pyenv-doctor | |
| url = https://github.com/pyenv/pyenv-doctor.git | |
| branch = master | |
| [submodule ".pyenv-installer"] | |
| path = .pyenv-installer |
| #!/bin/bash | |
| # Place this file in `ci/init.sh` within any Git repository. | |
| : <<EOF | |
| MIT License | |
| Copyright (c) 2021 Klaus Frank | |
| Permission is hereby granted, free of charge, to any person obtaining a copy | |
| of this software and associated documentation files (the "Software"), to deal |
| version: '3.7' | |
| services: | |
| localstack: | |
| image: localstack/localstack | |
| container_name: localstack_service | |
| ports: | |
| - "4566-4584:4566-4584" | |
| - "8055:8080" | |
| environment: | |
| - SERVICES=s3 |
| Add-Type -AssemblyName System.Windows.Forms | |
| $file = "C:\bginfo\bginfo.png" | |
| [System.Windows.Forms.Application]::EnableVisualStyles() | |
| [System.Windows.Forms.Application]::SetCompatibleTextRenderingDefault($false) | |
| $form = [System.Windows.Forms.Form]::new() | |
| $form | Add-Member -Name pictureBox1 -MemberType NoteProperty -Value ([System.Windows.Forms.PictureBox]::new()) | |
| ([System.ComponentModel.ISupportInitialize]$form.pictureBox1).BeginInit() | |
| $form.SuspendLayout() |
| enum EnumBlock { | |
| water | |
| sand | |
| } | |
| enum EnumBlockShort { | |
| w | |
| s | |
| } | |
| function New-Board { |
| # This script uses this library: https://github.com/lduchosal/ipnetwork | |
| # It needs to be imported using e.g. `Add-Type -AssemblyName ./System.Net.IPNetwork.dll` | |
| # Not to be confused with IPNetwork from Microsoft.AspNetCore.HttpOverrides.dll | |
| function Get-CIDRFromAddressByPrefixList { | |
| [OutputType([System.Net.IPNetwork])] | |
| param( | |
| [Parameter(Mandatory)][System.Net.IPAddress]$address, | |
| [Parameter(Mandatory)][System.Net.IPNetwork[]]$prefixes | |
| ) | |
| $address6 = $address.MapToIPv6() |