Skip to content

Instantly share code, notes, and snippets.

View clexanis's full-sized avatar

clexanis clexanis

  • 05:13 (UTC +02:00)
View GitHub Profile
@jcberthon
jcberthon / networkmanager-wifi-powersave.md
Last active September 15, 2025 16:56
NetworkManager Wi-Fi powersaving configuration

NetworkManager WiFi Power Saving

NetworkManager supports WiFi powersaving but the function is rather undocumented.

From the source code: wifi.powersave can have the following value:

  • NM_SETTING_WIRELESS_POWERSAVE_DEFAULT (0): use the default value
  • NM_SETTING_WIRELESS_POWERSAVE_IGNORE (1): don't touch existing setting
  • NM_SETTING_WIRELESS_POWERSAVE_DISABLE (2): disable powersave
@olavmrk
olavmrk / lvm-daily-snapshot.sh
Created December 11, 2013 13:24
A script to take daily snapshots of a LVM volume.
#!/bin/bash
KEEP_DAYS=15
VG="vg" # LVM volume group we are snapshoting
LV="data-volume-name" # Name of LVM-volume to take a snapshot of
BACKUP_PREFIX="backup-volume-prefix-" # Prefix of snapshot volume name.
SIZE=40G # Amount of disk space to allocate for the snapshot
# Create new snapshot