Skip to content

Instantly share code, notes, and snippets.

View bahamas10's full-sized avatar

Dave Eddy bahamas10

View GitHub Profile
@bahamas10
bahamas10 / 00-readme.md
Created March 12, 2022 20:48
illumos LX (void linux) rustup hangs

Rust fails to install via rustup - the process hangs when trying to download files.

Quick Fix

The simple fix is:

RUSTUP_USE_CURL=1 ./rustup-init

This will tell rustup-init to use curl instead of reqwest.

@bahamas10
bahamas10 / output.txt
Created January 26, 2022 02:32
void linux in LX rustup hangs
dave - jackett linux ~ $ strace -f ./rustup-init
execve("./rustup-init", ["./rustup-init"], 0x7fffffeff208 /* 47 vars */) = 0
brk(NULL) = 0x1000
uname({sysname="Linux", nodename="jackett.rapture.com", ...}) = 0
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/lib64/tls/x86_64/libgcc_s.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/usr/lib64/tls/x86_64", 0x7fffffefe2f0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/lib64/tls/libgcc_s.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat("/usr/lib64/tls", 0x7fffffefe2f0) = -1 ENOENT (No such file or directory)
@bahamas10
bahamas10 / README.md
Created September 1, 2021 02:39
Quick and dirty youtube subscriber count getter
$ ./get-subscriber-count
2.91K subscribers
@bahamas10
bahamas10 / output.md
Created August 16, 2021 23:48
game and watch 2
$ OPENOCD=/opt/openopcd-git/bin/openocd ./5_restore.sh jlink
Ok, restoring original firmware! (We will not lock the device, so you won't have to repeat this procedure!)
Restoring internal flash...
Open On-Chip Debugger 0.11.0+dev-00331-g53556fcde-dirty (2021-08-16-17:30)
Licensed under GNU GPL v2
For bug reports, read
	http://openocd.org/doc/doxygen/bugs.html
Info : J-Link ARM V8 compiled Dec  1 2009 11:42:48
Info : Hardware version: 8.00
@bahamas10
bahamas10 / output.md
Last active September 1, 2021 02:36
game and watch step 5

Running through the steps of https://github.com/ghidraninja/game-and-watch-backup

steps 1 - 4 were a success, step 5 gives me this:

$ OPENOCD=/opt/openopcd-git/bin/openocd ./5_restore.sh jlink
Ok, restoring original firmware! (We will not lock the device, so you won't have to repeat this procedure!)
Restoring internal flash...
Open On-Chip Debugger 0.11.0+dev-00331-g53556fcde-dirty (2021-08-16-17:30)
Licensed under GNU GPL v2
@bahamas10
bahamas10 / readme.md
Created July 28, 2020 21:23
ThinkPad TouchPad on Void Linux fix

Synaptics Touchpad

I did an XBPS upgrade on my Void Linux system and my touchpad stopped working (ThinkPad X1 Carbon Gen6). The TrackPoint (little red nub thingy in the keyboard) still worked just fine.

Find the device

@bahamas10
bahamas10 / readme.md
Created June 17, 2020 20:33
slow stat in smartos after usermod

Stat'ing my home directory normally:

$ echo $USER
dave
$ ptime stat /home/dave >/dev/null

real        0.004714407
user        0.000784144
sys         0.002977563
@bahamas10
bahamas10 / 00-patch.diff
Last active May 4, 2020 20:41
cueball postgres rust mdapi
diff --git a/utils/Cargo.toml b/utils/Cargo.toml
index 11b114c..e08a152 100644
--- a/utils/Cargo.toml
+++ b/utils/Cargo.toml
@@ -9,7 +9,7 @@ edition = "2018"
clap = "2.32"
cueball = "0.3.3"
cueball-manatee-primary-resolver = "0.3.0"
-cueball-postgres-connection = "0.3.0"
+cueball-postgres-connection = { git = "https://github.com/joyent/rust-cueball", branch = "master" }
@bahamas10
bahamas10 / 00-readme.md
Created April 6, 2020 17:27
void linux on illumos lx
@bahamas10
bahamas10 / ps-svcs
Created January 14, 2020 07:39
illumo smf svcs for processes
#!/usr/bin/env bash
#
# svcs wrapper for services with processes
#
# Author: Dave Eddy <dave@daveeddy.com>
# Date: January 12, 2020
# License: MIT
red=$(tput setaf 1 2>/dev/null)
green=$(tput setaf 2 2>/dev/null)