Mastodon https://mastodon.social/@chrisbensen or Twitter https://twitter.com/chrisbensen
Wednesday, November 9, 2022
Tuesday, November 9, 2021
How do I find my router's public IP Address from the command line?
dig -4 TXT +short o-o.myaddr.l.google.com @ns1.google.com
@jpluimers commented on Twitter that he uses:
alias whatismyipv4='curl http://ipv4.whatismyip.akamai.com && echo'
Which is quite a bit shorter, I'll admit. However I think mine works in more situations, such as when http is blocked as @jpluimers mentions. I'm not worried about length because a. I don't have to do this very often and b. when I do I search my blog and copy-paste. If you do it often, maybe alias the dig command. But I will leave that as an exercise for the reader.
Posted by Chris Bensen at 7:00 AM 0 comments
Sunday, March 14, 2021
Friday, December 4, 2020
GraalVM on macOS Big Sur
Apparently Graal isn't registered or signed right for macOS Big Sur:
Posted by Chris Bensen at 7:00 AM 0 comments
Tuesday, November 17, 2020
All Raspberry Pi Super Computer Posts in One Spot
https://www.thingiverse.com/thing:3958586
https://www.thingiverse.com/thing:4652356
http://chrisbensen.blogspot.com/2019/06/very-large-raspberry-pi-cluster-part-i.html
http://chrisbensen.blogspot.com/2019/06/very-large-raspberry-pi-cluster-part-ii.html
http://chrisbensen.blogspot.com/2019/06/very-large-raspberry-pi-cluster-part-iii.html
http://chrisbensen.blogspot.com/2019/07/very-large-raspberry-pi-cluster-part-iv.html
http://chrisbensen.blogspot.com/2019/07/very-large-raspberry-pi-cluster-part-v.html
http://chrisbensen.blogspot.com/2019/07/very-large-raspberry-pi-cluster-part-vi.html
http://chrisbensen.blogspot.com/2019/09/bringing-pi-home.html
http://chrisbensen.blogspot.com/2019/11/raspberry-pi-super-computer-stl-files.html
http://chrisbensen.blogspot.com/2019/11/using-max-build-volume-of-ultimaker-3d.html
http://chrisbensen.blogspot.com/2019/12/get-mac-address-for-pi-cluster.html
http://chrisbensen.blogspot.com/2020/01/raspberry-pi-overlay-root-filesystem.html
http://chrisbensen.blogspot.com/2020/07/behind-scenes-building-worlds-largest.html
http://chrisbensen.blogspot.com/2020/11/parts-list-for-raspberry-pi-mini-super.html
Posted by Chris Bensen at 7:00 AM 0 comments
Wednesday, November 11, 2020
git - make the history never exist
I committed something to my git repo that I didn't mean to. Always, I mean always create a .gitignore first and add everything that should be excluded. Modifying the history is super scary and dare I say, dangerous. I did a quick google search and ran across this which seems to have the best steps for doing the desired surgery.
First run this to check the size:
git count-objects -vH
Just in case that link stops working I've pasted there relevant bits here:
# Make a fresh clone of YOUR_REPO
git clone YOUR_REPO
cd YOUR_REPO
# Create tracking branches of all branches
for remote in `git branch -r | grep -v /HEAD`; do git checkout --track $remote ; done
# Remove DIRECTORY_NAME from all commits, then remove the refs to the old commits
# (repeat these two commands for as many directories that you want to remove)
git filter-branch --index-filter 'git rm -rf --cached --ignore-unmatch DIRECTORY_NAME/' --prune-empty --tag-name-filter cat -- --all
git for-each-ref --format="%(refname)" refs/original/ | xargs -n 1 git update-ref -d
# Ensure all old refs are fully removed
rm -Rf .git/logs .git/refs/original
# Perform a garbage collection to remove commits with no refs
git gc --prune=all --aggressive
# Force push all branches to overwrite their history
# (use with caution!)
git push origin --all --force
git push origin --tags --force
Lastly run this command to check the size again:
git count-objects -vH
It appears to have worked. I did have to reclone my repository which seemed a little odd but it worked.
Posted by Chris Bensen at 7:00 AM 0 comments
Tuesday, November 10, 2020
Delete .DS_Store files on Mac
As with many things I post to my blog I post them here rather than keeping on some personal repository of information because I don't want to have to remember it every time (no matter how simple it might be) and other people might find it useful when searching around.
Have you ever needed to remove all the .DS_store files on your Mac from all subdirectories, I dunno, maybe from a git repository? If so here:
find . -name ".DS_Store" -print -exec rm {} \;
Posted by Chris Bensen at 7:00 AM 0 comments
Thursday, November 5, 2020
Parts List for Raspberry Pi Mini Super Computer
Here are the parts for the Raspberry Pi Mini Super Computer. A build video can be found here.
Name | Description | URL | Count | Price | Total |
Ubiquiti Networks US-48 48-Port UniFi Managed Gigabit Switch with SFP BH #UBUS48 • MFR #US-48 4 reviews 2 Questions, 3 Answers | https://www.bhphotovideo.com/c/product/1267264-REG/ubiquiti_networks_us_48_48_port_unifi.html | 2 | 359 | 718 | |
Network Cloud Key | Ubiquiti Networks UniFi Cloud Key Gen2 B&H # UBUCKG2 MFR # UCK-G2 | 1 | 179 | 179 | |
Ubiquiti Networks Networks Unifi Security Gateway Pro (USG-PRO-4) | 1 | 311.00 | 311 | ||
Lenovo | https://www.bhphotovideo.com/c/product/1447926-REG/lenovo_10vg000sus_m715q_tiny_amd_ryzen.html | 2 | $649.00 | $1298.00 | |
Raspberry Pi 3B+ | 84 | $35.00 | $2940.00 | ||
Pearstone Cat 6a Snagless Patch Cable (1', Blue) | 84 | $1.99 | $167.16 | ||
Pearstone Cat 6a Snagless Patch Cable (3’, Blue) | 6 | $1.99 | $11.94 | ||
StarTech.com 3 ft / 91cm Micro USB Cable - A to Right Angle Micro B - USB Type A - 90 Degree Micro-USB Type B (M) - Black (UUSBHAUB3RA) | https://www.amazon.com/gp/product/B001AR4NC8/ref=ppx_yo_dt_b_asin_title_o02_s00?ie=UTF8&psc=1 | 84 | $3.00 | $252.00 | |
Security-01 2 Packs 80mm by 80mm by 25mm 8025 12V DC 0.20A Ball Bearing Brushless Cooling Fan 2pin AV-F8025MB UL CE | https://www.amazon.com/gp/product/B072QCTYJW/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 | 42 | $15.98 | $671.16 | |
USB Charging Station, 60 Ports USB Power Station | https://www.amazon.com/gp/product/B07MB12XZ4/ref=ppx_yo_dt_b_asin_title_o06_s00?ie=UTF8&psc=1 | 2 | 0 | ||
NP-05B Remote PDU, UL-STD TUV Listed, 5 Switchable Outlets. Manufactured and Supported in USA. Control Via Web, Telnet, USB Serial Port. | https://www.amazon.com/gp/product/B0039OZKPE/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 | 1 | $229.00 | $229.00 | |
10 Pack AC 250V 10A IEC 320 C14 Panel Mount Plug Adapter Power Connector Socket Black Screw Mount 3 Pins Inlet Power Plug Socket By MXR | https://www.amazon.com/gp/product/B07DCXKNXQ/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 | 1 | $6.99 | $6.99 | |
20 Amp Commercial Grade Self Grounding Duplex Outlet, White | 1 | $1.58 | $1.58 | ||
ADJ Products AC POWER STRIP (PC-100A) | https://www.amazon.com/gp/product/B00KFZ98YO/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 | 1 | $60.00 | $60.00 | |
Lenovo m715q | 2 | $500.00 | $1000.00 | ||
UGREEN USB C Charger 18W PD 3.0 Type C Wall Charger Power Delivery for iPhone SE 11 Pro Max Xs Max XR X 8 Plus, AirPods Pro, iPad Pro, Google Pixel 3a XL, Samsung Galaxy S10+ S9+, LG V50 ThinQ G8 | Needed to power cloud key | https://www.amazon.com/gp/product/B07R7K2QMW/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 | 1 | $13.89 | $13.89 |
XLX 50PCS 25Pair Mini Micro 2.54 2PIN Female and Male Connection Plug with Red Black Terminal Connector Wire Cable 200mm Compatible with JST XH | Connect to fans. You have to swap red and black or remember to connect red to black | https://www.amazon.com/gp/product/B076JFFDWN/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 | 1 | $17.99 | $17.99 |
Power supply for fans? | |||||
DisplayPort to HDMI, Benfei Gold-Plated DP Display Port to HDMI Adapter (Male to Female) Compatible for Lenovo Dell HP and Other Brand | Connect Lenovo to HDMI | https://www.amazon.com/gp/product/B017Q8ZVWK/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 | 2 | $9.99 | $19.98 |
BATIGE HDMI Male to Female Car Mount Flush Extension Cable Truck Boat Motorcycle Dashboard Flush Mount with Mounting Panel - 3ft | https://www.amazon.com/gp/product/B01LX1FQPE/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 | 2 | $9.45 | $18.90 | |
VELCRO Brand ONE-WRAP Roll Black | 30 Ft x 1-1/2 In | Reusable Self-Gripping Hook and Loop Tape | Cut Straps to Bundle Tie Materials and Tools in Garage Shed or Worksite | https://www.amazon.com/gp/product/B00404ULFQ/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 | 1 | $20.00 | $20.00 | |
GOWOS (5 Pack) Cat6 Shielded RJ45 Panel Mount Industrial Bulkhead - Female to Female Feed Thru Coupler | https://www.amazon.com/gp/product/B07PRDVZ5X/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&th=1 | 1 | $57.03 | $57.03 | |
Neutrik NE8FDP etherCON RJ-45 Feedthrough Chassis Connector | https://www.amazon.com/gp/product/B002BER402/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 | 2 | $8.71 | $17.42 | |
Gigabit + PoE Adapter (L6-NETPOE) | 1 | 99 | 99 | ||
USB Micro B Cable for Lightning 400mm (L90-B-4) | 1 | 29.00 | 29 | ||
SR Mini Keyboard Wired Thin Light 78 Keys USB Multimedia Small for Pc Computer Laptop | https://www.amazon.com/gp/product/B01IQL2VCE/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 | 1 | 12.99 | 12.99 | |
Neutrik NE8FDP etherCON RJ-45 Feedthrough Chassis Connector | https://www.amazon.com/gp/product/B002BER402/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1 | 2 | 8.71 | 17.42 | |
Seismic Audio - SA-ET10-10 Foot CAT6 Ethercon Compatible RJ45 Pro Audio Patch Cable - Pro Series OFC for Recording, Stage, Studio use | 1 | 19.99 | 19.99 | ||
Pelican Air 1615 Case with Foam (Yellow) | With Foam | https://www.amazon.com/gp/product/B07JHTXF3X/ref=ppx_yo_dt_b_asin_title_o08_s01?ie=UTF8&psc=1 | 1 | 325.77 | 325.77 |
Ceptics 12Pcs International Travel Worldwide Grounded Universal Plug Adapter Set - Charge Your Devices from Anywhere in The World | https://www.amazon.com/gp/product/B01DJEBLQU/ref=ppx_yo_dt_b_asin_title_o05_s00?ie=UTF8&psc=1 | 1 | 13.85 | 13.85 |
Posted by Chris Bensen at 7:00 AM 2 comments
Thursday, August 27, 2020
Three Important Things to Work From Home
1. A good headset
I have tried a lot of headsets. There are two that I really like
Sennheiser GAME ZERO Gaming Headset
Apple AirPods
Both of these have noise cancelling and just work. Don't bother with the AirPod Pro noise cancelling, I'm sure they're nice but they are super expensive, and if you don't get the wireless charging case then you can get AirPods for around $120 which is still expensive but they really work great. Other similar headphones are out and I haven't tried all of them but considering I'd probably try 2-3 at half the price then surpassing the price of the AirPods and the AirPods work great I just go with it.
Posted by Chris Bensen at 7:00 AM 0 comments
Wednesday, August 26, 2020
Evacuated from the Fires in Santa Cruz - Tried to Rescue the Raspberry Pi Mini Super Computer
We had to evacuate our home because of the fires in Santa Cruz California. Trying to find some humor in a very difficult situation.
Posted by Chris Bensen at 7:41 AM 0 comments
Thursday, July 30, 2020
Upgrade to macOS Catalina broke the Arduino IDE
Everything was working fine and then I upgraded to macOS Catalina. The Arduino IDE version 1.8.12 just wouldn't start. Then I ran from terminal and looked at the actually error.
./Arduino
Set log4j store directory /Users/cbensen/Library/Arduino15
2020-07-30 08:39:47.311 Arduino[73800:11442574] name is : .SFNS-Regular
2020-07-30 08:39:47.311 Arduino[73800:11442574] family is : .AppleSystemUIFont
2020-07-30 08:39:47.311 Arduino[73800:11442574] name is : .SFNS-Bold
2020-07-30 08:39:47.311 Arduino[73800:11442574] family is : .AppleSystemUIFont
2020-07-30 08:39:47.312 Arduino[73800:11442574] name is : .SFNSMono-Regular
2020-07-30 08:39:47.312 Arduino[73800:11442574] family is : .SF NS Mono
2020-07-30 08:39:47.706 Arduino[73800:11442574] CoreText note: Client requested name ".SFNS-Regular", it will get Times-Roman rather than the intended font. All system UI font access should be through proper APIs such as CTFontCreateUIFontForLanguage() or +[NSFont systemFontOfSize:].
2020-07-30 08:39:47.706 Arduino[73800:11442574] CoreText note: Set a breakpoint on CTFontLogSystemFontNameRequest to debug.
2020-07-30 08:39:47.706 Arduino[73800:11442574] needed to substitute Lucida Grande for: .SFNS-Regular
2020-07-30 08:39:47.707 Arduino[73800:11442574] CoreText note: Client requested name ".SFNS-Bold", it will get Times-Roman rather than the intended font. All system UI font access should be through proper APIs such as CTFontCreateUIFontForLanguage() or +[NSFont systemFontOfSize:].
2020-07-30 08:39:47.707 Arduino[73800:11442574] needed to substitute Lucida Grande for: .SFNS-Bold
2020-07-30 08:39:47.707 Arduino[73800:11442574] CoreText note: Client requested name ".SFNSMono-Regular", it will get Times-Roman rather than the intended font. All system UI font access should be through proper APIs such as CTFontCreateUIFontForLanguage() or +[NSFont systemFontOfSize:].
2020-07-30 08:39:47.707 Arduino[73800:11442574] needed to substitute Lucida Grande for: .SFNSMono-Regular
2020-07-30 08:39:47.710 Arduino[73800:11442574] CoreText note: Client requested name ".SFNSMono-Regular", it will get Times-Roman rather than the intended font. All system UI font access should be through proper APIs such as CTFontCreateUIFontForLanguage() or +[NSFont systemFontOfSize:].
2020-07-30 08:39:47.710 Arduino[73800:11442574] needed to substitute Lucida Grande for: .SFNSMono-Regular
2020-07-30 08:39:47.710 Arduino[73800:11442574] CoreText note: Client requested name ".SFNSMono-Regular", it will get Times-Roman rather than the intended font. All system UI font access should be through proper APIs such as CTFontCreateUIFontForLanguage() or +[NSFont systemFontOfSize:].
2020-07-30 08:39:47.710 Arduino[73800:11442574] needed to substitute Lucida Grande for: .SFNSMono-Regular
2020-07-30 08:39:47.713 Arduino[73800:11442574] CoreText note: Client requested name ".SFNS-Regular", it will get Times-Roman rather than the intended font. All system UI font access should be through proper APIs such as CTFontCreateUIFontForLanguage() or +[NSFont systemFontOfSize:].
2020-07-30 08:39:47.713 Arduino[73800:11442574] needed to substitute Lucida Grande for: .SFNS-Regular
2020-07-30 08:39:47.713 Arduino[73800:11442574] CoreText note: Client requested name ".SFNS-Bold", it will get Times-Roman rather than the intended font. All system UI font access should be through proper APIs such as CTFontCreateUIFontForLanguage() or +[NSFont systemFontOfSize:].
2020-07-30 08:39:47.713 Arduino[73800:11442574] needed to substitute Lucida Grande for: .SFNS-Bold
java.lang.NullPointerException
at cc.arduino.contributions.packages.ContributionsIndexer.parseIndex(ContributionsIndexer.java:134)
at processing.app.BaseNoGui.initPackages(BaseNoGui.java:483)
at processing.app.Base.<init>(Base.java:273)
at processing.app.Base.main(Base.java:150)
After some digging around, trying a few things I came across this article https://github.com/arduino/Arduino/issues/9828 and I decided to live life on the edge and try the hourly build! And that did it. So there's an issue and it apparently is known and has been fixed.
Posted by Chris Bensen at 7:00 AM 0 comments
Thursday, July 23, 2020
Running Out of Memory with SQL Developer
Previously I wrote about getting SQL Developer to work, well, just work here. It just doesn't work as downloaded and is still a very useful tool when connecting to databases. I recently ran into another issue, which is out of memory problems. It's rather easy to fix but I spent all day tracking down in the boot scripts for how. So here's how (even if all I'm doing is documenting it for my future self):
1. Open the file in your favorite text editor:
/Applications/SQLDeveloper.app/Contents/Resources/sqldeveloper/ide/bin/ide.conf
2. Search for the line:
AddVMOption -Xmx800M
3. Change it to more, a lot more! I just added a couple zeros and I'm all good:
AddVMOption -Xmx80000M
So there you have it.
Posted by Chris Bensen at 7:00 AM 0 comments