Skip to content

Instantly share code, notes, and snippets.

View ricjcosme's full-sized avatar

Ricardo Cosme ricjcosme

View GitHub Profile

Disabling GNOME Tracker and Other Info

GNOME's tracker is a CPU and privacy hog. There's a pretty good case as to why it's neither useful nor necessary here: http://lduros.net/posts/tracker-sucks-thanks-tracker/

After discovering it chowing 2 cores, I decided to go about disabling it.

Directories

@ricjcosme
ricjcosme / gist:c6f4c72644cc9bf0e63db7acc54bf6fb
Created May 24, 2020 14:20
Resizing a filesystem using qemu-img and fdisk

Occasionally we will deploy a virtual instance into our KVM infrastructure and realize after the fact that we need more local disk space available. This is the process we use to expand the disk image. This process assumes the following:

  • You're using legacy disk partitions. The process for LVM is similar and I will describe that in another post.
  • The partition you need to resize is the last partition on the disk.

This process will work with either a qcow2 or raw disk image. For

@ricjcosme
ricjcosme / mongo-dump-csv.sh
Created January 16, 2021 22:56 — forked from mderazon/mongo-dump-csv.sh
Export all of Mongodb collections as csv without the need to specify fields
OIFS=$IFS;
IFS=",";
# fill in your details here
dbname=DBNAME
user=USERNAME
pass=PASSWORD
host=HOSTNAME:PORT
# first get all collections in the database