VirtualBox

VirtualBox 显存 使用 4k 显示器的时候如果 virtualbox 显存设置的太小, 会导致黑屏. 剪贴板共享 Settings> General> Advanced> Shared Clipboard: Bidirectional NAT 端口转发 虚拟机> 设置> 网络> 网卡1>

Archlinux 安装 linux-lts 内核

Archlinux 安装 linux-lts 内核 Archlinux 如果做服务器用的话, 最好安装 LTS 内核, 否则…说不定哪次更新之后, 服务就起不来了, 比如最近遇到的 linux 5.19.1 和 netavark 的兼容问题.

git reset

git reset git reset 是一个重置 (reset) 命令, 通过 git reset 命令可以修改 HEAD 指向不同的提交,这个提交甚至都不必是当前分支上的某次提交, 只要是版本库中合法提交都可以使用这

openwrt basic, opkg basic, ipk

openwrt basic, opkg basic, ipk commands 1 2 3 4 5 # 查看 openwrt 版本 cat /etc/openwrt_release # 更新所有软件,包括 OpenWRT 内核、固件等 opkg list-upgradable | cut -f 1 -d ' ' | xargs opkg upgrade wan dns 在 wan 口设置里的“高级设置”选项里去掉&

resolv.conf, systemd-resolved, DNS

resolv.conf, systemd-resolved, DNS 1 2 3 4 5 6 7 8 9 10 11 12 13 # 查看版本 systemd-resolve --version # check systemd-resolved status resolvectl status resolvectl restart # disable dns on 53 port vim /etc/systemd/resolved.conf # switch off binding to port 53 DNSStubListener=no # disable LLMNR LLMNR=false https://cloud-atlas.readthedocs.io/zh_CN/latest/linux/redhat_linux/systemd/systemd_resolved.html 测试 域名解析 1 2 3 resolvectl query goproxy.cn resolvectl query baidu.com resolvectl query google.com

wireguard

wireguard wireguard default port: 51820 install archlinux archlinux 新版本的内核已经集成了 wireguard,不需要单独安装. 已经集成了 wireguard 但是默认没加载, 需要配置一下启动的时候加载 wireguard 内核模块.

xfce

xfce disable taskbar items grouping Right click on the taskbar, select Panel -> Panel Preferences Select the Items tab , select Window Buttons in the list, click the Edit button on the right side Change Window grouping to Never xfce 快捷键 1 ctrl+F1 #切换工作区 列出已经配置的快捷键 1 xfconf-query -c xfce4-keyboard-shortcuts -l -v|grep thunar 修改

systemd timer, 定时任务

systemd timer, 定时任务 1 2 3 # 查看 timer systemctl list-timers systemctl list-timers --all 创建一个服务 1 vim /etc/systemd/system/foo.service content of foo.service 1 2 3 4 5 6 7 [Unit] Description=foo service [Service] ExecStart=/usr/local/bin/foo.sh [Install] WantedBy=multi-user.target 再创建一个对应的 timer, /etc/systemd/system/foo.timer 1 vim /etc/systemd/system/foo.timer content of foo.timer 1 2 3 4 5 6 7 8 9 10

fcitx

fcitx https://wiki.archlinux.org/title/Fcitx5 archlinux 安装 fcitx https://blog.csdn.net/GaaraZ/article/details/128618441 1 2 3 4 5 6 7 8 # include 1) fcitx5 2) fcitx5-configtool 3) fcitx5-gtk 4) fcitx5-qt sudo pacman -S fcitx5-im #--- sudo pacman -S fcitx5 kcm-fcitx fcitx-configtool fcitx-im fcitx-table-extra # kcm-fcitx: 图形界面的配置程序: KDE 中的 kcm-fcitx # fcitx-im: 输入法模块 # fcitx-table-extra: 输入法模块-五

DataGrip

DataGrip console 中使用变量 1 2 3 4 select * from public.actor where actor.actor_id < ${a} 导出建表语句 打开DataGrip、找到目标表 选中之后右键点击SQL Scripts→SQL Generator. 就可以看到建

android 自动充电

android 自动充电 Chanify 消息推送工具 https://github.com/chanify/chanify-ios/blob/main/README-zh_CN.md 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 # sample podman run -it \ -v /my/data:/root/.chanify \ wizjin/chanify:latest \ serve --name=<node name> --endpoint=http://<address>:<port> # podman podman run -it \ -d --name chanify \ -p 30080:80 \ -v chanify-data:/root/.chanify \ wizjin/chanify:latest \ serve --name=chanify0

ssh-agent, ssh agent, ssh forward

ssh-agent, ssh agent, ssh forward ssh agent forward A > B > C 主机 A:运行 ssh-agent,并且已经加载私钥 主机 B:跳板机 主机 C: 目标机,已经配置好公钥,并且运行 sshd 检查主机 A ssh-agent

bitwarden

bitwarden auto fill Chrome extension> bitwarden> settings> option> autofill> enable auto-fill on page load podman server https://hub.docker.com/r/vaultwarden/server 1 2 3 4 5 # docker pull vaultwarden/server:1.33.2-alpine podman pull vaultwarden/server:1.33.2-alpine podman run -d --name bitwarden -v bitwarden-data:/data/ -p 8000:80 docker.io/vaultwarden/server:latest docker run -d --name bitwarden --restart=always -v bitwarden-data:/data/ -p 8000:80 vaultwarden/server:1.28.1-alpine 测试一下,直接用浏览器访问 80 端口应该能看

epub pdf azw3 mobi

“epub pdf azw3 mobi” EPUB> PDF> azw3 Calibre 从 azw3 转换格式到 EPUB 只需要 1分半, 转 PDF 格式需要10分钟以上。 azw3 > EPUB https://divineengine.net/article/how-to-remove-drm-from-kindle-books-with-calibre/ mobi mobi 电子书格式能够流行普及起来,很大程度上依靠亚马逊这个巨大

socat

socat socat 测试端口连通性, test a remote port is reachable with socat 1 2 3 4 5 6 7 8 9 10 11 12 13 # test tcp port socat /dev/null TCP:192.168.1.15:22 socat - tcp4:192.168.1.15:22,connect-timeout=3 # test udp port # https://serverfault.com/questions/416205/testing-udp-port-connectivity # set up a server listening on UDP port 1234 socat UDP-RECV:1234 STDOUT # or socat STDIO UDP-LISTEN:1234 # test udp port socat

curl command

curl command curl [kɜrl] options 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 --version, print version -s, --silent, 不显示下载进度, 不显示 error message -S, --show-error 在使用 -s 时, 打印 curl error message

linux apps

linux apps kitty, terminal Ubuntu apt package gnome-shell-pomodoro: Pomodoro, https://gnomepomodoro.org/ pavucontrol, chrome audio output, https://askubuntu.com/questions/457978/no-sound-from-chrome-sound-works-fine-in-firefox-etc-13-10 baobab, 硬盘占用分析工具 indicator-sysmonitor, 任务栏里的系统资源监控 thunderbird, 邮件客户端, email client pacman ncdu, 磁盘空间占用分析/清理 bitwarden, password management binutils: A set of programs to assemble and manipulate

iproute2 > 路由表, routing table, ip route

iproute2 > 路由表, routing table, ip route commands 1 2 3 4 5 6 ip route # 简写, Abbreviations # route: ro, r. # show: list, sh, ls, l. ip route ls tab all ip route 1 Usage: ip route { list | flush } SELECTOR := 表示声明并定义 { xxx | xxx } 表示多选 - 必

tcpcopy, 流量复制

tcpcopy, 流量复制 公有云环境 https://github.com/session-replay-tools/tcpcopy/issues/336 云环境下,安全策略可能会干扰测试的进行 采用如下步骤可以规避麻烦: 测试机器和 intercept 部署到一台机器 tcpcopy端 -c 参数采用 tcpcopy

Git basic commands, git 常用命令

Git basic commands 目前比较流行的版本管理系统 相比同类软件,Git有很多优点。其中很显著的一点,就是版本的分支 (branch) 和合并 (merge) 十分方便。 有些传统的版本管理软件,