Ah Chat GPT, how I wish you were correct. Sadly, this does not work and it seems that there is no way to find out.
davidbond.net
Friday, 24 February 2023
Wednesday, 2 November 2022
Craiyon is AMAZING
OK, so Craiyon (art AI) is stunning. A beautiful creation.
Here are some screenshots that show how amazing this thing is:
Tuesday, 6 September 2022
LogicMonitor in containers
If your LogicMonitor collector container fails to start with:
/usr/local/logicmonitor/agent/bin/logicmonitor-agent: 32: Syntax error : ")" unexpected
...allocate it more memory (e.g. from 2G to 4G).
You're welcome. We, however, will not get the last 2 hours back.
Sunday, 31 July 2022
Recovering from a Failure / SMART ERROR RAID 1 situation
The situation
You have an DL380 or similar. Your first disk has failed. Your second disk is in SMART ERROR.
What next?
The hardware
- a USB adapter for mounting your disk on Windows
- the failed disks
The software
- Windows 10/11
- Windows Subsystem for Linux installed
The process
- Attach the disk to USB via the adapter
- If the disk is Windows-compatible, you can use freeware disk recovery tools to go from here. Do not follow the following steps.
- If the disk is Linux-compatible, proceed to the next step
- Start Disk Manager to ensure that you are able to see the disk partition
- Start an elevated PowerShell prompt
- Type:
- wmic diskdrive list brief
- Note the drive that you want to mount
- Type (e.g.)
- wsl --mount \\.\PHYSICALDRIVE2
- If you receive an error:
- The disk \\.\PHYSICALDRIVE2 was attached from WSL2, but failed to mount (error code: -22). For more details, run 'dmesg' inside WSL2.
- ... then you likely have a different file system to EXT4.
- Enter WSL with:
- wsl --system
- Look at the dmesg output by typing:
- dmesg
- Look for the following (or similar):
- [224440.126973] EXT4-fs (sde): VFS: Can't find ext4 filesystem
- [224440.127932] ERROR: Mount:2528: mount(/dev/sde, /share/PHYSICALDRIVE2, ext4, 0x0, ) failed
- Note the disk, in this case "sde"
- Make a data directories for each partition:
- mkdir /data1
- mkdir /data2
- mkdir /data3
- ...
- Mount each partition - the command will fail when there are no more partitions to mount:
- mount -t xfs /dev/sde1 /data1
- mount -t xfs /dev/sde2 /data2
- mount -t xfs /dev/sde3 /data3
- ...
- Now copy the data off to your home directory using the rsync command (cp has issues with large files)
- Install rsync with:
- yum install rsync
- Have progress bars on your file copy with (e.g.):
- rsync --progress /data1/110/disk.0 .
- When you are finished, remember to unmount the partitions:
- umount /data1
- umount /data2
- umount /data3
- ...
- You can now unplug the drive.
Wednesday, 8 June 2022
New York drivers: the most important people in the world
Sunday, 8 May 2022
Mars
Another Whole New World (Mars)
While "Earth 2" is out for repairs, I bought a temporary replacement machine on Amazon next day delivery. It's smaller than Earth2, so it's called "Mars".
Winget
Choco is no longer the way to go, so let's try to get everything back in using winget....
Winget
winget install -e -h --accept-source-agreements Google.Chrome
winget install -e -h Microsoft.VisualStudio.2022.Professional
winget install -e -h Microsoft.SQLServer.2019.Express
winget install -e -h Valve.Steam
winget install -e -h Microsoft.VisualStudioCode
winget install -e -h Ditto.Ditto
winget install -e -h Git.Git
winget install -e -h Mozilla.Firefox
winget install -e -h Github.GithubDesktop
winget install -e -h 7zip.7zip
winget install -e -h VideoLAN.VLC
winget install -e -h Notepad++.Notepad++
winget install -e -h Foxit.FoxitReader
winget install -e -h Zoom.Zoom
winget install -e -h Inkscape.Inkscape
winget install -e -h Docker.DockerDesktop
winget install -e -h ShareX.ShareX
winget install -e -h Audacity.Audacity
winget install -e -h Postman.Postman
winget install -e -h Microsoft.PowerToys
winget install -e -h WhatsApp.WhatsApp
winget install -e -h BlenderFoundation.Blender
winget install -e -h Discord.Discord
winget install -e -h KeePassXCTeam.KeePassXC
winget install -e -h PostgreSQL.pgAdmin
winget install -e -h Microsoft.SQLServerManagementStudio
winget install -e -h JanDeDobbeleer.OhMyPosh
winget install -e -h Microsoft.MouseWithoutBorders
REM SysInternals: Process Explorer etc.
winget install -e -h 9P7KNL5RWT25
REM Windows Terminal
winget install -e -h 9N0DX20HK701
winget install -e -h Microsoft.Teams
winget install -e -h Elgato.StreamDeck
winget install -e -h NathanBeals.WinSSH-Pageant
winget install -e -h Toggl.TogglDesktop
winget install -e -h Mirantis.Lens
winget install -e -h Canonical.Multipass
REM FFMPEG
winget install -e -h 9NB2FLX7X7WG
winget install -e -h WinMerge.WinMerge
Other downloads
- Paint.NET
- Fiddler
- KiTTY
- WiX Toolset
- Davinci Resolve
Oh My Posh
- Install CaskaydiaCove Nerd Font
"defaults": {
"font": {
"face": "CaskaydiaCove Nerd Font"
}
},
...
Private key management
ssh-add <keyname>.private.rsa
Docker desktop
First, carefully follow the instructions here:
wsl -d docker-desktop
sysctl -w vm.max_map_count=262144
exit
docker run --name rabbitmq -p 5672:5672 -p 15672:15672 -e RABBITMQ_DEFAULT_USER=<username> -e RABBITMQ_DEFAULT_PASS=<password> -d bitnami/rabbitmq:latest
docker run --name postgres -e POSTGRES_PASSWORD=<mysecretpassword> -e PGDATA=/var/lib/postgresql/data/pgdata -v "C:/users/david/Postgres Data:/var/lib/postgresql/data" -d postgres
Visual Studio Extensions
Get ELK working:
Visual Studio Extensions
Add all the good Visual Studio Extensions:
- Add New File (64-bit)
- Bootstrap Snippet Pack
- Case Converter 2022
- EditorConfig Language Service
- File Icons
- Git Diff Margin
- Inheritance Margin
- Markdown Editor (64-bit)
- Match Margin 2022
- NamespaceFixer
- Hgrok Extensions
- Open Command Line
- Solution Error Visualizer 2022
- SwitchStartupProject for VS 2022
- Time Stamp Margin 2022
- Trailing Whitespace Visualizer
- Viasfora
- Visual Studio Spell Checker (VS2022 and Later)
- Wix Toolset Visual Studio 2022 Extension
- Add New File (64-bit)
- Bootstrap Snippet Pack
- Case Converter 2022
- EditorConfig Language Service
- File Icons
- Git Diff Margin
- Inheritance Margin
- Markdown Editor (64-bit)
- Match Margin 2022
- NamespaceFixer
- Hgrok Extensions
- Open Command Line
- Solution Error Visualizer 2022
- SwitchStartupProject for VS 2022
- Time Stamp Margin 2022
- Trailing Whitespace Visualizer
- Viasfora
- Visual Studio Spell Checker (VS2022 and Later)
- Wix Toolset Visual Studio 2022 Extension
Settings
- Visible white space
- Enable with Ctrl R, Ctrl-W
- Make less harsh on the eyes by moving the saturation to ~50% of its default value
- Set Cascadia Code to be the default Font
- Move the Solution Explorer back to the left hand side
- Visible white space
- Enable with Ctrl R, Ctrl-W
- Make less harsh on the eyes by moving the saturation to ~50% of its default value
- Set Cascadia Code to be the default Font
- Move the Solution Explorer back to the left hand side
Data transfer
Data transfer will be fun - there's so much on my old PC, so I have that running at a second desk in case I need something in a hurry.
HP Console
Saturday, 9 April 2022
Undead LogicMonitor Devices / Resources
Do you have seemingly dead LogicMonitor devices, with skull and crossbones, just because you have written your own DataSources, have applied "NoPing" to system.categories so the usual Host Status DataSource Group doesn't appear?
Simply add the following lines to your DataSource's Groovy collection script (not active discovery) and viola: they're undead.
import com.santaba.agent.live.LiveHostSet
LiveHostSet.getInstance().flag(hostProps.get("system.deviceId").toInteger())