Skip to main content

Primary links

  • Home
  • AI
  • Kubernetes
  • Incus
  • Ansible
  • Terraform
  • OpenStack
  • Virtualization
  • Linux
  • SmartHome
  • HowTo

Misc

  • Linux
  • Hardware
  • Programming
  • Databases
  • Multimedia
  • Windows

Cloud

  • OpenStack
  • cloud-config
  • nextcloud

Virtualization

  • Virtualization
  • Incus
  • Docker
  • KVM
  • Kubernetes
  • LXC
  • LXD
  • QEMU
  • VMware
  • VirtualBox
  • multipass
  • podman
  • vagrant
  • XEN

Network

  • DNS
  • Firewall
  • Linux
  • OpenvSwitch
  • SSL
  • VLAN
  • VPN
  • iPXE
  • namespaces
  • nmcli
  • tcpdump

Storage

  • CEPH
  • DRBD
  • LVM
  • S3
  • ZFS
  • btrfs

Automation / CI/CD

  • Install
  • Ansible
  • GitLab
  • LLM
  • Preseed
  • Puppet
  • Terraform
  • Ubuntu autoinstall

Monitoring / Visualisation

  • Grafana
  • Icinga
  • Prometheus
  • Monitoring
  • ELK
  • mermaid

Flash LibreELEC to S905X

Latest version
http://kszaq.libreelec.tv/s905/

wget http://kszaq.libreelec.tv/s905/8.2/8.2.3.1/LibreELEC-S905.arm-8.2-8.2.3.1.img.gz -P /tmp/
gzip -d /tmp/LibreELEC-S905.arm-8.2-8.2.3.1.img.gz -C /tmp
dd if=/tmp//tmp/LibreELEC.USB-SD.Creator.Linux-64bit.bin of=/dev/mmcblk0
1. remove power connector from the box
2. insert sd card to to the box
3. press button inside aux connector and connect power to the box
4. enable ssh service on the box
5. ssh root@your_box_ip (pass: libreelec)
6. installtointernal

Links
https://blog.sengotta.net/libreelec-auf-nexbox-a95x-installieren/
https://kszaq.libreelec.tv/s905/
https://coreelec.org/

Redfish

BMC_IP=10.0.1.123
BMC_USER=ADMIN
BMC_PASS=ADMIN

# Install redfishtool (CLI)
git clone  https://github.com/DMTF/Redfishtool.git
cd Redfishtool/
python3 redfishtool.py -r ${BMC_IP} -u ${BMC_USER} -p ${BMC_PASS} Systems -F

for BMC_IP in 10.0.1.11 10.0.1.12 10.0.1.13; do
    python3 redfishtool.py -r ${BMC_IP} -u ${BMC_USER} -p ${BMC_PASS} Systems -F | jq .SerialNumber
    python3 redfishtool.py -r ${BMC_IP} -u ${BMC_USER} -p ${BMC_PASS} Systems -F | jq .IndicatorLED
done

BMC_HOSTS=$(grep 10.52 /var/lib/misc/dnsmasq.leases | cut -d" " -f3 | sort)
for BMC_HOST in ${BMC_HOSTS}; do
    echo ${BMC_HOST}
    curl --connect-timeout 1 -s https://${BMC_HOST}/redfish/v1/Systems/1/ -k -u ${BMC_USER}:${BMC_PASS} | jq -r .IndicatorLED
  echo
done

python3 redfishtool.py -r ${BMC_IP} -u ${BMC_USER} -p ${BMC_PASS} Chassis list
python3 redfishtool.py -r ${BMC_IP} -u ${BMC_USER} -p ${BMC_PASS} Chassis -I 1
python3 redfishtool.py -r ${BMC_IP} -u ${BMC_USER} -p ${BMC_PASS} Chassis -I HA-RAID.0.StorageEnclosure.0

python3 redfishtool.py -r ${BMC_IP} -u ${BMC_USER} -p ${BMC_PASS} Systems -F | jq .UUID
python3 redfishtool.py -r ${BMC_IP} -u ${BMC_USER} -p ${BMC_PASS} Systems -F | jq .IndicatorLED

python3 redfishtool.py -r ${BMC_IP} -u ${BMC_USER} -p ${BMC_PASS} Chassis -I 1 setIndicatorLed Off

BMC_IP=$(dig +short node1.example.com)

LXD: tftp container (recover ASUS RT-N66U under Linux)

lxc launch ubuntu:20.04 tftp

lxc config device add tftp eth0 nic nictype=physical parent=enp0s25

lxc file push Downloads/RT-N66U_3.0.0.4_382_52272-g73d3ea2.trx tftp/tmp/
lxc shell tftp

apt update 
apt install -y tftp

ip l set dev eth0 up
ip a add 192.168.1.111/24 dev eth0


# ping 192.168.1.1

# tftp 
tftp> connect
(to) 192.168.1.1

put RT-N66U_3.0.0.4_382_52272-g73d3ea2.trx

Links
https://chrishardie.com/2013/02/asus-router-firmware-windows-mac-linux/

kexec (reboot without hardware initialization)

echo "kexec-tools kexec-tools/load_kexec select true" | sudo debconf-set-selections

sudo apt install -y kexec-tools
#sudo kexec -l /boot/vmlinuz-4.15.0-32-generic --initrd=/boot/initrd.img-4.15.0-32-generic --reuse-cmdline
#sudo kexec -e
#systemctl kexec

sudo kexec -l /vmlinuz --initrd=/initrd.img --reuse-cmdline && sudo systemctl kexec
- name: Enable kexec
   lineinfile:
     path: /etc/default/kexec
     regexp: '^LOAD_KEXEC='
     line: 'LOAD_KEXEC=true'
   when: ('dev' in group_names)

Test: boot Ubuntu Bionic mini.iso

wget http://archive.ubuntu.com/ubuntu/dists/bionic/main/installer-amd64/current/images/netboot/mini.iso
sudo kexec -l /mnt/linux --initrd=/mnt/initrd.gz
sudo systemctl kexec

Links
https://liranv.github.io/post/booting-memtest86-uefi/

ironic / bifrost

# load env
. /opt/stack/bifrost/env-vars

# list nodes
ironic node-list

# remove / shutdown existing node
ironic node-set-provision-state foo.example.com deleted

# load node configuration
export BIFROST_INVENTORY_SOURCE=/opt/openstack-prepare-baremetal/bifrost/json/foo.example.com.json

# add new node
ansible-playbook -i inventory/bifrost_inventory.py enroll-dynamic.yaml
ironic node-update foo.example.com add properties/capabilities='boot_mode:uefi'

# deploy
ansible-playbook -v -i inventory/bifrost_inventory.py deploy-dynamic.yaml

# show node details
ironic node-show foo.example.com

# cli
#ironic node-set-maintenance 00000000-0000-0000-0000-112233445566 on
openstack baremetal node maintenance set ${NODE_UUID}

ironic node-delete 00000000-0000-0000-0000-112233445566
ironic node-list

ironic node-set-power-state  00000000-0000-0000-0000-112233445566 on

ironic node-set-maintenance ${NODE} on
ironic node-delete ${NODE}
ansible-playbook -i inventory/bifrost_inventory.py enroll-dynamic.yaml
ironic node-update ${NODE add properties/capabilities='boot_mode:uefi'
ansible-playbook -i inventory/bifrost_inventory.py deploy-dynamic.yaml

# log (on ironic server)
tail -f /var/log/daemon.log

# show node state
ironic node-show  node1

# rebuild
ironic node-set-provision-state ${NODE} rebuild

Install OpenStack with Kolla-ansible under Ubuntu

Docu
https://docs.openstack.org/releasenotes/kolla-ansible/
https://docs.openstack.org/project-deploy-guide/kolla-ansible/latest/quickstart.html
https://docs.openstack.org/kolla-ansible/latest/reference/index.html
https://governance.openstack.org/tc/reference/runtimes/

Repository
https://github.com/openstack/kolla-ansible
# global kolla-ansible configuration file
https://github.com/openstack/kolla-ansible/blob/master/etc/kolla/globals.yml

Install all-in-one

apt-get install python-dev libffi-dev gcc libssl-dev python-selinux python-setuptools ansible pip
pip install kolla-ansible
#pip install -r requirements.txt
#python setup.py install
cp -r /usr/local/share/kolla-ansible/etc_examples/kolla /etc/
cp /usr/local/share/kolla-ansible/ansible/inventory/* .
kolla-genpwd
cp /etc/kolla/globals.yml{,org}
vi /etc/kolla/globals.yml
sed -i 's|#kolla_base_distro: "centos"|kolla_base_distro: "ubuntu"|g' /etc/kolla/globals.yml
sed -i 's|#kolla_install_type: "binary"|kolla_install_type: "source"|g' /etc/kolla/globals.yml
sed -i 's|#openstack_release: ""|openstack_release: "queens"|g' /etc/kolla/globals.yml
sed -i 's|kolla_internal_vip_address: "10.10.10.254"|kolla_internal_vip_address: "192.168.1.111"|g' /etc/kolla/globals.yml
sed -i 's|#network_interface: "eth0"|network_interface: "eth0"|g' /etc/kolla/globals.yml
sed -i 's|#neutron_external_interface: "eth1"|neutron_external_interface: "eth1"|g' /etc/kolla/globals.yml
cp /usr/local/share/kolla-ansible/ansible/roles/baremetal/defaults/main.yml{,org}
vi /usr/local/share/kolla-ansible/ansible/roles/baremetal/defaults/main.yml
diff /usr/local/share/kolla-ansible/ansible/roles/baremetal/defaults/main.yml{,org}
kolla-ansible -i ./all-in-one bootstrap-servers
kolla-ansible -i ./all-in-one prechecks

Credentials

Terraform

Install
https://www.terraform.io/downloads.html

# sudo apt install -y jq

URL=$(wget https://checkpoint-api.hashicorp.com/v1/check/terraform -qO- | jq  -r '.current_download_url + "/" + .product + "_" + .current_version + "_linux_amd64.zip"')
wget ${URL} -qP /tmp
unzip -d /tmp /tmp/${URL##*/}
mv /tmp/terraform ~/.local/bin/

# or deploy global
# sudo mv /tmp/terraform /usr/local/bin/

terraform  version

Debug
https://www.terraform.io/internals/debugging

# enable
export TF_LOG=DEBUG
# disable
export TF_LOG=ERROR

TF_LOG=debug OS_DEBUG=1 terraform apply

CLI

# deploy
terraform init
terraform plan
terraform apply -auto-approve

# format the Terraform files
terraform fmt

# list workspaces
terraform workspace list

# destroy
terraform destroy -auto-approve

Install with Ansible
[embed_url: https://raw.githubusercontent.com/panticz/ansible/master/roles/terraform/tasks/main.yml]

GitLab runner

Install
https://packages.gitlab.com/app/runner/gitlab-runner/gpg
https://packages.gitlab.com/runner/gitlab-runner/install

curl -s https://packages.gitlab.com/install/repositories/runner/gitlab-runner/script.deb.sh | sudo bash
sudo apt install gitlab-runner

List / delete gitlab-runner

# List GitLab runner configuration
gitlab-runner list

# Delete all GitLab runner
gitlab-runner unregister --all-runners

Instlal with Ansible
https://github.com/panticz/ansible/tree/master/roles/gitlab-runner
https://github.com/haroldb/ansible-gitlab-runner

Relogin as gitlab-runner user

su gitlab-runner -s /bin/bash

Get token from GitLab server
http:///admin/runners

# configure DNS for GitLab server
echo "10.0.1.12 gitlab.example.com gitlab" >> /etc/hosts

Register
https://docs.gitlab.com/runner/register/

Go language

# hello.go

package main

import "fmt"

func main() {
fmt.Println("Hello, World")
}

# run source
go run hello.go
# build
go build hello.go

OpenStack diskimage-builder

Install

sudo apt install -y curl python-pip qemu-utils
pip install diskimage-builder

# packages
dib/elements/my_pkg/package-installs.yaml
...
vlan:
wget:
linux-image-generic:
  uninstall: True

# change TMPDIR
export TMPDIR=/mnt
disk-image-create -o output.qcow --no-tmpfs vm block-device-gpt ubuntu-minimal

Build IPA image

export DIB_QUIET=0
export ELEMENTS_PATH=/opt/ironic-python-agent-builder/dib:/opt/diskimage-builder/dib/elements
export IMAGE_NAME=ironic-python-agent
export DIB_ELEMENTS=ironic-python-agent-ramdisk
export DIB_RELEASE=focal

disk-image-create ${DIB_ELEMENTS} -o ${IMAGE_NAME} --logfile ${IMAGE_NAME}.log

Build Ubuntu image

export DIB_QUIET=0
export ELEMENTS_PATH=/opt/diskimage-builder/dib/elements
export IMAGE_NAME=img-${DIB_RELEASE}-minimal
export DIB_ELEMENTS=foo
export DIB_RELEASE=focal

disk-image-create ${DIB_ELEMENTS} -o ${IMAGE_NAME} -t tgz --logfile ${IMAGE_NAME}.log --checksum

dynamic-login
https://docs.openstack.org/diskimage-builder/latest/elements/dynamic-login/README.html
https://docs.openstack.org/ironic/pike/install/include/kernel-boot-parameters.html

Options
https://github.com/openstack/diskimage-builder/blob/master/diskimage_builder/lib/disk-image-create#L52

Elements
https://docs.openstack.org/diskimage-builder/latest/elements.html

Pagination

  • First page
  • Previous page
  • …
  • Page 18
  • Page 19
  • Page 20
  • Page 21
  • Page 22
  • Page 23
  • Page 24
  • Page 25
  • Page 26
  • …
  • Next page
  • Last page
Profiles GitHub StackOverflow LinkedIn Xing
Contact Imprint
© panticz 2026

Cookie-Einstellungen

Diese Website nutzt eingebettete Inhalte von Drittanbietern (z.B. YouTube, SoundCloud). Beim Laden dieser Inhalte werden Daten an die jeweiligen Anbieter übermittelt. Datenverarbeitungserklärung