$ sudo su
$ bootctl install
$ cat <<EOF>/boot/loader/loader.conf
#https://wiki.archlinux.org/index.php/Systemd-boot#Configuration
# menu timeout
timeout 3
$ # Use Live CD to boot | |
$ sudo su # Switch to root | |
$ fdisk -l # Get names of root, boot & EFI partition names. you can also use blkid | |
$ mount /dev/mapper/fedora_localhost--live-root /mnt # mount root partition | |
$ cat /mnt/etc/fedora-release | |
Fedora release 31 (Thirty One) | |
$ mount /dev/nvme0n1p2 /mnt/boot # mount boot partition | |
$ mount /dev/nvme0n1p1 /mnt/boot/efi # mount EFI partition | |
# Note: If you are not able to mount EFI partition ('Input/Output error'), | |
# You may have to repair ESP file system or format ESP. |
[[inputs.snmp]] | |
agents = [ "firewall.ip.address.here:161" ] | |
version = 1 | |
community = "public" | |
interval = "10s" | |
timeout = "20s" | |
[[inputs.snmp.field]] | |
name = "host" | |
oid = ".1.3.6.1.2.1.1.5.0" | |
is_tag = true |
# Add Repository to your system (ondrej/php PPA) | |
sudo apt install apt-transport-https lsb-release ca-certificates | |
sudo wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg | |
sudo sh -c 'echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list' | |
sudo apt update | |
# Install PHP 7.1 | |
sudo apt install php7.1 |
I play games regularly, and the sad reality is that it forces me to use Windows on my desktop. There's a Linux installation on there, but rebooting into it is such a massive interruption that I usually just move over to my laptop for programming. Working on a laptop leads to all sorts of ergonomic issues, and it felt like a massive waste to not develop on the desktop hardware I invested so much in. So after extensively researching what the VFIO community has been doing, I've deleted my Windows installation and moved all my gaming into a virtual machine on a Linux host.
Normally VMs are too slow for gaming, but thanks to a feature called VFIO you can run games at near-native performance by passing graphics cards and USB controllers directly to a virtual machine. The only requirement is that your board supports IOMMU, which most modern systems have. In this guide I'll wal
LVM on LUKS Arch installation with systemd-boot
Sources:
- https://wiki.archlinux.org/index.php/Installation_guide
- https://wiki.archlinux.org/index.php/Dm-crypt/Encrypting_an_entire_system
Note: If you want a simpler encryption setup (with LUKS only), you can instead use the archinstall "guided" installer included with Arch since April 2021.
##Installing a custom SSL cert on Unifi Controller
Requirements:
- Domain certificate (*.crt)
- Certificate key (*.key)
- Intermediate certificate from CA (*.crt, *.pem)
- Permissions to restart the unifi service
- Debian or Ubuntu Unifi Controller installation
// Run PostgreSQL server: | |
// docker run -e POSTGRES_PASSWORD="" -p 5432:5432 postgres | |
// Monitor running processes: | |
// watch -n 1 'echo "select pid,query_start,state,query from pg_stat_activity;" | psql -h localhost -U postgres | |
// | |
// For all handlers, call to db takes 5 seconds, | |
// | |
// Three endpoints: | |
// - "/" - take 5 seconds | |
// - "/ctx" - take 1 seconds, due to 1 second cancellation policy |
#!/bin/env bash | |
## Needs `jq` (https://stedolan.github.io/jq/) on PATH | |
## and a personal gogs token of yours. | |
## Obtain token from https://git.example.com/user/settings/applications | |
## Usage: | |
## ./migrate.sh $clone_url $project_name [$optional_group] | |
## Migrate a repository to gogs into the user namespace of the token-user | |
## ./migrate.sh [email protected]:group/repo.git repo | |
## Migrate a repository to gogs into the group namespace `group` (needs to exist) |