-
SSH into proxmox node and become root user. Run the following commands to download extra software dependencies we'll need.
apt update apt install -y libsasl2-modules mailutils
-
Enable 2FA for the gmail account that will be used by going to security settings
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/local/bin/bash | |
# | |
# Calomel.org | |
# https://calomel.org/zfs_health_check_script.html | |
# FreeBSD 9.1 ZFS Health Check script | |
# zfs_health.sh @ Version 0.15 | |
# Check health of ZFS volumes and drives. On any faults send email. In FreeBSD | |
# 10 there is supposed to be a ZFSd daemon to monitor the health of the ZFS | |
# pools. For now, in FreeBSD 9, we will make our own checks and run this script |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rsync -rtvzplogDH --numeric-ids --exclude=/etc/fstab --exclude=/etc/network/* --exclude=/proc/* --exclude=/tmp/* --exclude=/sys/* --exclude=/dev/* --exclude=/mnt/* --exclude=/boot/* /* root@$DESTINATION_HOST:/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# 1. Download and install the QEMU hook helper from here: https://github.com/PassthroughPOST/VFIO-Tools | |
# 2. Place this file in /etc/libvirt/hooks/qemu.d/NAME OF YOUR VM/prepare/begin/disable-fb.sh | |
# 3. Make disable-fb.sh executable. | |
VM_NAME="$1" | |
echo "libvirt-qemu disable-fb: Disabling efi-framebuffer to prepare to pass GPU to VM $VM_NAME" > /dev/kmsg 2>&1 | |
echo "efi-framebuffer.0" > /sys/bus/platform/devices/efi-framebuffer.0/driver/unbind |
/etc/ufw/applications.d/plexmediaserver
[plexmediaserver]
title=Plex Media Server (Standard)
description=The Plex Media Server
ports=32400/tcp|3005/tcp|5353/udp|8324/tcp|32410:32414/udp
[plexmediaserver-dlna]
title=Plex Media Server (DLNA)
description=The Plex Media Server (additional DLNA capability only)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -euo pipefail | |
shopt -s inherit_errexit 2>/dev/null || true | |
# this script will generate wg-quick(8) config file | |
# in order to connect to Cloudflare Warp using Wireguard on Linux | |
# note: this is *absolutely not* an official client from Cloudflare | |
# Copyright (C) 2019 Ondrej Caletka | |
# based heavily on macOC client by Jay Freeman (saurik) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import json | |
import subprocess | |
import sys | |
from concurrent.futures import ThreadPoolExecutor | |
import html | |
import dictdiffer | |
import iso8601 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# This script will make a local SNMP server accessible on a remote system by | |
# forwarding its UDP traffic over an SSH connection. | |
# To do this, the following port forwardings are applied (in this order): | |
# - local TCP port 42061 (arbitrary) to local UDP port 161 (SNMP) | |
# - remote TCP port 42061 to local TCP port 42061 (via SSH connection) | |
# - remote UDP port 42061 to remote TCP port 42061 |
Here's my setup:
- Home server running Ubuntu 14.04.5 LTS (GNU/Linux 3.13.0-93-generic x86_64)
- Plex Media Server debian package running on server
- Netgear Nighthawk R6900 home router
- Dynamic hostname from no-ip.org, which I'll use for this setup
Complete up to the "Generate the cert" section in this gist
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
head -1 example.torrent | grep -aoE '6:lengthi[0-9]+' | cut -di -f2 | awk '{s+=$1} END {print s}' |
NewerOlder