Skip to content

Instantly share code, notes, and snippets.

View xros's full-sized avatar
🎯
Focusing

Songhua Liu xros

🎯
Focusing
View GitHub Profile
@xros
xros / readme.md
Last active March 4, 2025 17:37
setting up docker on ARM v7 (32bit) CPU - NanoPC T2 and Raspberry Pi 1B, 2B

Docker can run on ARM v7 CPU

I am gonna demonstrate how to run a docker engine on an ARM v7 CPU on NanoPC T2, which was released in 2016 on s5p4418 chip.

docker error: level=error msg="failed to mount overlay: invalid argument"

Quick solution: use vfs driver instead of overlay

Item Info
@xros
xros / readme.md
Last active February 19, 2025 23:48
iperf3 network testing for VMs using private (internal) switch in Synology DSM

TD;DR

Summary

I found Synology DSM 7.2.2 supports internal(private) vSwitch with IPv6 support ONLY (without using a physical switch). No IPv4! (I assume Synology won't like users to use internal(private) vSwitch because it costs lots of CPU)

Here's how-to

@xros
xros / readme.md
Last active February 10, 2025 20:43
Solution to Synology NAS Error: GPT PMBR size mismatch (239649 != 245759) will be corrected by write.

This issue has been there since many years. It can be found on some forums. Searching links from Google https://www.google.com/search?q=Synology+GPT+PMBR+size+mismatch+%28239649+%21%3D+245759%29+will+be+corrected+by+write.&newwindow=1

I personally enabled 2 pcie-nvme SSD disks as Read-Write cache RAID1 on Synology NAS. Then I disabled them safely from DSM web UI (Storage Manager / Storage / Select your Volume), then I found some error from terminal via command fdisk -l. After I removed the 2 SSDs, the error was still there.

Error: GPT PMBR size mismatch (239649 != 245759) will be corrected by write. reported by fdisk -l via SSH to NAS.

GPT PMBR size mismatch (239649 != 245759) will be corrected by write.
Disk /dev/synoboot: 120 MiB, 125829120 bytes, 245760 sectors
Disk model: DiskStation
@xros
xros / readme.md
Created February 9, 2025 15:15
Linux (Ubuntu) set network interface priority using nmcli

2 ethernet interfaces: enp6s18, enp6s19

Need to use enp6s19 as default and use enp6s18 as backup

Principle: set different Metric on different interfaces. The lower Metric is, the higher the priority is.

Need tool nmcli

1. Check route

Run command route

@xros
xros / esp32_c3_hello_world_arduino_AirM2M_core_esp32c3.md
Last active January 23, 2025 18:03 — forked from MartinRGB/esp32_hello_world_arduino.md
ESP32 C3 Hello World Arduino, luatos Air2Air Core ESP32 C3

init...

#define LED_D4 13
#define LED_D5 12

void setup() {
  // put your setup code here, to run once:
  Serial.begin(115200);
 pinMode(LED_D4,OUTPUT);
@xros
xros / official-discord-domains-list.md
Created August 28, 2024 15:44 — forked from InvalidLenni/official-discord-domains-list.md
All (If I have forgotten a URL here, then please just let me know :)!) official Discord domains (Discord Domain List)

Official Discord Domains, let's reduce the scams!

Domain Description
dis.gd Discord's URL shorter (I like .gd as top-level domain)
discord.co Admin panel, this means not for us! (Not discord administrators / maybe staffs)
discord.com The domain is for e.g the homepage or message links etc
discord.design Dribbble profile shortlink
discord.dev Developer site shortlinks
discord.gg Invite shortlinks
@xros
xros / readme.md
Created August 11, 2024 13:11
Bypassing GPU lock (such as RTX 20xx GPU) when installing ChatRTX from Nvidia

By time time of writting which is 11th Aug 2024, ChatRTX from Nvidia has only offically supported RTX 30/40 series GPU. I have a RTX 2080Ti which Nvidia has abandoned support.

I don't like this.

So I found out the way of bypassing the ChatRTX installation process on Windows 11 with RTX 2080 Ti.

After finishing downloading all the ChatRTX zip file from Nvidia, find some files in the folder and change it. https://www.nvidia.com/en-us/ai-on-rtx/chatrtx/

Steps

@xros
xros / readme.md
Created July 18, 2024 01:31
Building Custom EdgeTX firmware cmake commands in browser using GitPod.io
@xros
xros / warp.js
Created March 30, 2024 20:09 — forked from lzjluzijie/warp.js
Cloudflare Warp 24PB key generator
# See https://halu.lu/%E6%9D%82%E8%B0%88/cloudflare-warp/
# Depolyed at https://warp.halu.lu/
// Change keys if needed
const keys = [
"9WO41D5p-6OP8xj27-36gQG75D",
"R65K12Up-aU907O2e-4nuvD581",
"06LM94EJ-1nl0V2d7-V847va5y",
]