Skip to content

Instantly share code, notes, and snippets.

View cu's full-sized avatar

Charles Ulrich cu

View GitHub Profile
@cu
cu / 9VF7iSY.jpg
Last active January 27, 2025 20:53
the gist of things
9VF7iSY.jpg
@cu
cu / powernet446.mib
Created September 18, 2023 18:59
APC PowerNet MIB Version 4.4.6
This file has been truncated, but you can view the full file.
-- *************************************************************************
-- AMERICAN POWER CONVERSION PowerNet-MIB
-- *************************************************************************
-- Copyright (c) 2022 American Power Conversion, Inc.
-- PowerNet is a Trademark of American Power Conversion Corp.
--
-- Title: APC TOP LEVEL PowerNet MIB
--
-- Version : 4.4.6
--
@cu
cu / jsonpp.py
Created November 7, 2024 21:26
JSON Pretty Printer and Highlighter
import json
import sys
from pygments import highlight
from pygments.lexers import JsonLexer
from pygments.formatters import TerminalFormatter
if __name__ == "__main__":
print(
highlight(
@cu
cu / Linux_Dell_Precision_7550.md
Last active January 27, 2025 01:45
Linux Notes for Dell Precision 7550

I bought this laptop to replace my nearly 10-year-old personal machine that finally died due to a failing display. It was already three years old when I bought it, but it had everything I wanted at a price I couldn't refuse. (Black Friday.)

I guess this is as good a place as any for a side note: I bought this laptop from dellrefurbished.com. Note that I don't recommend buying from them due to the exceedingly poor quality of support that I received. They have permission to use the Dell logo and branding for their business but they are NOT Dell and you do NOT get the standard Dell support or warranty. If something is wrong with the laptop, they will NOT offer to repair it. Instead, they will only offer you a very low token partial refund. I would say if you are going to buy from them, these are the things to keep in mind:

  • Their normal warranty is essentially worthless, so do not buy their extended warranty either.
  • Even if the laptop is listed as being in "A" condition, that only applies to the cosmetics
@cu
cu / puppetctl-unix-syslog-delivery-error.md
Created January 27, 2025 21:05
puppetctl "Unix syslog deliery error"

Getting this when running puppetctl status:

[db160024.bwi701:/root]# puppetctl status
2025/01/27 09:44:55 Unix syslog delivery error

Rsyslogd is running:

@cu
cu / how_to_mount_filesystems_using_UUID.md
Last active February 25, 2025 13:43
Linux: Mounting a filesystem with a UUID/PARTUUID

To get the UUID of a block device, use blkid:

$ blkid /dev/sdb1
/dev/sdb1: UUID="1c46a3c1-cbe7-4bb6-a412-445f317e2b5d" BLOCK_SIZE="4096" TYPE="xfs" PARTUUID="7f943a21-be92-304f-8bae-45aa7c4b0c78"

There are typically two UUIDs given, UUID and PARTUUID. UUID is a property of the filesystem, while PARTUUID is a property of the GPT partition table. In a lot of cases, you can use either/or but keep in mind your future use cases before settling on one or the other. For example:

  • If you might be cloning a filesystem on the same host, this will result in a duplicate UUID but not a duplicate PARTUUID. If there are two filesystems with the same UUID present on the system, Linux will refuse to guess which one you mean.