Skip to content

Instantly share code, notes, and snippets.

View meetnick's full-sized avatar

Niccola meetnick

  • Belo Horizonte, MG - Brazil
View GitHub Profile
@hmenke
hmenke / README.md
Last active May 17, 2023 11:21
Ubuntu cloud-init autoinstall

Create an Ubuntu 20.04 LTS autoinstall USB

This only works with UEFI boot.

  1. Get a USB key and format it with a GPT partition table. Using gptfdisk something like this should do it:
    sgdisk -og /dev/sdX
    sgdisk -n 0:0:0 -t 0:ef00 /dev/sdX
    

Create a FAT32 partition, mount it and extract the ISO image to that location

@holyketzer
holyketzer / power.sh
Created October 11, 2013 07:21
/etc/acpi/power.sh and /etc/rc.local For good laptop powersaving. I reccommend it!
#!/bin/sh
if on_ac_power; then
echo "Power mode"
echo 0 > /proc/sys/vm/laptop_mode
echo 10 > /proc/sys/vm/dirty_ratio
echo 5 > /proc/sys/vm/dirty_background_ratio
echo 6000 > /proc/sys/vm/dirty_writeback_centisecs
echo 0 > /sys/module/snd_hda_intel/parameters/power_save
echo max_performance > /sys/class/scsi_host/host0/link_power_management_policy