Skip to content

Instantly share code, notes, and snippets.

View frankperrakis's full-sized avatar

Frank Perrakis frankperrakis

View GitHub Profile
@frankperrakis
frankperrakis / archlinux-qemu-kvm.md
Created November 19, 2024 20:34 — forked from tatumroaquin/archlinux-qemu-kvm.md
QEMU-KVM Installation for Arch Linux

QEMU-KVM in Arch Linux

Check Virtualization Support

Check CPU has VM capabilities

lscpu | grep -i Virtualization
  • VT-x for Intel
  • AMD-Vi for AMD
@frankperrakis
frankperrakis / PVE-host-backup.md
Created November 10, 2023 12:36 — forked from mrpeardotnet/PVE-host-backup.md
Proxmox PVE Host Config Backup Script

Proxmox PVE Host Config Backup Script

This script can be used to backup essential configuration files from the Proxmox Virtual Enivronment (PVE) host.

The script will create backups using tar with specified backup prefix and date and time stamp in the file name. Script will also delete backups that are older then number of days specified.

Create backup script file

To create backup script that will be executed every day we can create backup script in /etc/cron.daily/ folder. We need to make it writeable by root (creator) only, but readable and executable by everyone:

touch /etc/cron.daily/pvehost-backup
@frankperrakis
frankperrakis / lxc_plex_intel_quicksync.md
Created November 10, 2023 11:11 — forked from packerdl/lxc_plex_intel_quicksync.md
Intel QuickSync passthrough to an unprivileged LXC container running plex.

Running Plex in an Unprivileged LXC with Intel QuickSync Passthrough

First setup an unprivileged Ubuntu container with Plex Media Server installed. Inside the container take note of the id of the plex group.

# Your Plex group's ID may be different
$ getent group plex | cut -d : -f3
998
@frankperrakis
frankperrakis / skylake-tuning-linux.md
Created January 31, 2023 19:07 — forked from Brainiarc7/skylake-tuning-linux.md
This gist will show you how to tune your Intel-based Skylake, Kabylake and beyond Integrated Graphics Core for performance and reliability through GuC and HuC firmware usage on Linux.

Tuning Intel Skylake and beyond for optimal performance and feature level support on Linux:

Note that on Skylake, Kabylake (and the now cancelled "Broxton") SKUs, functionality such as power saving, GPU scheduling and HDMI audio have been moved onto binary-only firmware, and as such, the GuC and the HuC blobs must be loaded at run-time to access this functionality.

Enabling GuC and HuC on Skylake and above requires a few extra parameters be passed to the kernel before boot.

Instructions provided for both Fedora and Ubuntu (including Debian):

Note that the firmware for these GPUs is often packaged by your distributor, and as such, you can confirm the firmware blob's availability by running:

@frankperrakis
frankperrakis / tmux.conf
Created June 5, 2022 20:38 — forked from spicycode/tmux.conf
The best and greatest tmux.conf ever
# 0 is too far from ` ;)
set -g base-index 1
# Automatically set window title
set-window-option -g automatic-rename on
set-option -g set-titles on
#set -g default-terminal screen-256color
set -g status-keys vi
set -g history-limit 10000
@frankperrakis
frankperrakis / cytrox-check.sh
Created May 25, 2022 08:45 — forked from dspinellis/cytrox-check.sh
Display host names of Cytrox spyware-hosting sites visited with Firefox
#!/usr/bin/env bash
#
# Display host names of Cytrox spyware-hosting sites visited with Firefox
# See: https://github.com/AmnestyTech/investigations/tree/master/2021-12-16_cytrox
#
# Diomidis Spinellis, May 2022
#
if [ -z "$1" ] ; then
echo "Usage: $0 /path/to/Firefox/places.sqlite" 1>&2

Generating Authy passwords on other authenticators


There is an increasing count of applications which use Authy for two-factor authentication. However many users who aren't using Authy, have their own authenticator setup up already and do not wish to use two applications for generating passwords.

Since I use 1Password for all of my password storing/generating needs, I was looking for a solution to use Authy passwords on that. I couldn't find any completely working solutions, however I stumbled upon a gist by Brian Hartvigsen. His post had a neat code with it to generate QR codes for you to use on your favorite authenticator.

His method is to extract the secret keys using Authy's Google Chrome app via Developer Tools. If this was not possible, I guess people would be reverse engineering the Android app or something like that. But when I tried that code, nothing appeared on the screen. My guess is that Brian used the