分类 折腾=-= 下的文章

很简单:卸载/冻结
com.oplus.appdetail
最好把广告商店
com.heytap.market
也干掉。

不怕死的用户

直接全冻:
["com.heytap.browser","com.nearme.instant.platform","com.oplus.logkit","com.oplus.thirdkit","com.oplus.upgradeguide","com.oplus.ota","com.oplus.sau","com.oplus.nhs","com.oplus.vdc","com.oplus.pay","com.oplus.pantanal.ums","com.coloros.securityguard","com.baidu.input_oppo","com.oplus.statistics.rom","com.android.ext.adservices.api","com.snda.wifilocating","com.coloros.weather.service","com.oplus.romupdate","com.coloros.bootreg","com.heytap.pictorial","com.oplus.acc.gac","com.oplus.safecenter","com.coloros.video","com.oplus.appdetail","com.heytap.market","com.oplus.olc"]

路径前情提要

本文中指定在/ZHITAIPC005/aria2 下进行频繁读写操作。
配置目录则按照Linux推荐规范在/etc/aria2/

安装aria2

sudo apt install aria2c

编写配置文件

sudo nano /etc/aria2/aria2.conf

xfox@EliteDesk800G3:/ZHITAIPC005$ sudo cat /etc/aria2/aria2.conf
# 启动时加载的任务文件
input-file=/ZHITAIPC005/aria2/aria2.session

# 退出时保存的任务文件
save-session=/ZHITAIPC005/aria2/aria2.session

# 预分配文件方式 固态无需
file-allocation=none
# 缓存大小,单位字节(64M 是推荐值,可调整)
disk-cache=64M

# 临时缓存目录
dir=/ZHITAIPC005/aria2/temp/

# 启用断点续传
continue=true

# 日志文件路径
log=/ZHITAIPC005/aria2/aria2.log

# 日志级别:debug, info, notice, warn, error
log-level=info

# 下载完成后的存储目录(自定义)
completed-dir=/ZHITAIPC005/aria2/downloads

# 启用 RPC 服务
enable-rpc=true

# RPC 服务监听端口
rpc-listen-port=6800

# 设置 RPC 授权令牌
rpc-secret=自己写=-=,可不要告诉我,不然我给你下满葫芦娃救爷爷。

# 允许所有来源访问
rpc-allow-origin-all=true

# 启用外部访问(需防火墙规则控制)
rpc-listen-all=true

# 最大并发下载数
max-concurrent-downloads=5

# 单文件分片数
split=16

# 分片的最小大小
min-split-size=10M

# 每个服务器的最大连接数
max-connection-per-server=5

# 下载失败的最大重试次数
max-tries=5

# 每次重试前的等待时间(秒)
retry-wait=5

# 启用 DHT
enable-dht=true
enable-dht6=false
# 启用本地对等发现
bt-enable-lpd=true

# IPv4 DHT 网络引导节点
dht-entry-point=dht.transmissionbt.com:6881

# IPv6 DHT 网络引导节点
dht-entry-point6=dht.transmissionbt.com:6881

# 种子验证前可做种
#bt-seed-unverified=true

# 保存种子元数据文件
bt-save-metadata=true

# BT强制加密, 默认: false
# 启用后将拒绝旧的 BT 握手协议并仅使用混淆握手及加密。可以解决部分运营商对 BT 下载的封锁,且有一定的防版权投诉与迅雷吸血效果。
# 此选项相当于后面两个选项(bt-require-crypto=true, bt-min-crypto-level=arc4)的快捷开启方式,但不会修改这两个选项的值。
bt-force-encryption=true

# BT加密需求,默认:false
# 启用后拒绝与旧的 BitTorrent 握手协议(\19BitTorrent protocol)建立连接,始终使用混淆处理握手。
#bt-require-crypto=true

# BT最低加密等级,可选:plain(明文),arc4(加密),默认:plain
#bt-min-crypto-level=arc4

# 分离仅做种任务,默认:false
# 从正在下载的任务中排除已经下载完成且正在做种的任务,并开始等待列表中的下一个任务。
bt-detach-seed-only=true


## 客户端伪装 ##

# 自定义 User Agent
user-agent=Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.4577.63 Safari/537.36 Edg/93.0.961.47

# BT 客户端伪装
# PT 下载需要保持 user-agent 和 peer-agent 两个参数一致
# 部分 PT 站对 Aria2 有特殊封禁机制,客户端伪装不一定有效,且有封禁账号的风险。
# 伪装为 qBittorrent
user-agent=qBittorrent/4.3.7
peer-agent=qBittorrent/4.3.7
peer-id-prefix=-QB1234-

Systemd后台保活

sudo nano /etc/systemd/system/aria2.service

[Unit]
Description=Aria2 Download Manager
After=network.target

[Service]
#User=aria2                                     
#Group=aria2                                   
ExecStart=/usr/bin/aria2c --conf-path=/etc/aria2/aria2.conf
ExecReload=/bin/kill -HUP $MAINPID
Restart=always
LimitNOFILE=65536

[Install]
WantedBy=multi-user.target

新建aria2专用用户、目录、文件

mkdir /ZHITAIPC005/aria2/
mkdir /ZHITAIPC005/aria2/downloads
mkdir /ZHITAIPC005/aria2/temp
touch /ZHITAIPC005/aria2/aria2.log
touch /ZHITAIPC005/aria2/aria2.session
chmod 600 /ZHITAIPC005/aria2/aria2.session

sudo useradd -r -m -d /ZHITAIPC005/aria2/ -s /usr/sbin/nologin aria2

启动服务:

sudo systemctl daemon-reload
sudo systemctl enable aria2.service
sudo systemctl start aria2.service

https://fcitx-im.org/wiki/Hall_of_Shame_for_Linux_IME_Support
里面最恶心的一条:Some preedit text might be typed in to input box
一些预编辑文本可能会被输入到输入框中,hzh
2024-12-16T13:41:30.png
以下表格为部分摘录并不完整


点击展开/隐藏

NameVersionUpstream bug reportDescriptionWorkaround
FirefoxAt least since 3.6https://bugzilla.mozilla.org/show_bug.cgi?id=641445Cannot input in flash within plugincontainer by XIMUse im module, or set dom.ipc.plugins.enabled.libflashplayer.so to false in about:config
FirefoxSeems since 10https://bugzilla.mozilla.org/show_bug.cgi?id=787943
https://bugs.freedesktop.org/show_bug.cgi?id=39367
Menu sometimes cannot popup correctly with XIMUse im module
FirefoxAt least 8https://bugzilla.mozilla.org/show_bug.cgi?id=699022Caret position not get reported when there is no preedit.
FirefoxAt least since 50https://bugzilla.mozilla.org/show_bug.cgi?id=1182596Firefox reset input method when it is not needed.
ChromiumFixed in 45http://code.google.com/p/chromium/issues/detail?id=113805Chromium put preedit text in primary clipboard
Chromium http://code.google.com/p/chromium/issues/detail?id=142823Some preedit text might be typed in to input boxUse im module
GTK33.0 - 3.1.5https://bugzilla.gnome.org/show_bug.cgi?id=645993XIM works badly.Use im module
Opera10.0 - 10.50 Cannot input with IM

解决方案

为什么不使用ibus? 因为ibus-rime在我的设备环境下不弹出候选词框,除非你是盲僧否则没必要尝试。

Fedora41 Fcitx输入法配置

参考了:
安装Fcitx5
Fedora 38: Wayland/KDE 系统设定与 fcitx5/rime 输入法
Fedora配置Rime中州韵输入法
输入env一看默认配置写了xim,而且KDE设置里直接改选Fcitx5压根不生效,整套默认配置就是依托答辩,操作系统的输入法做到开箱即用对于中国人来说还是很难。😅
为了确保与我相同环境的人(Fedora41 KDE wayland)一定能在配置后用上正常的rime输入法,除非你知道自己在做什么否则完全按照我的方案来。
下面的配置方式是过盈式的,一些包可能会默认自动进行部分原本需要手动设置的参数。

安装必要的软件包

sudo dnf install \ 
  fcitx5 \
  fcitx5-{autostart,configtool} \
  fcitx5-{gtk,qt} \
  fcitx5-{rime,chinese-addons} \
  fcitx5-table-{extra,other}

写入配置文件

cat > ~/.config/plasma-workspace/env/im.sh <<'EOF'
#fcitx5
export INPUT_METHOD=fcitx5
export XMODIFIERS=@im=fcitx5
export GTK_IM_MODULE=fcitx5
export QT_IM_MODULE=fcitx5
EOF

接下来重启,现在你已经可以使用Fcitx5-rime了!

这个问题出现在几天前,我从互联网寻找了很多解决方案,包括但不限于:卸载重装CS2/Steam 或者两个都卸载重装,删除部分文件并校验游戏完整性,但是这些方案对我都不奏效。
最后在客服的帮助下我找到了这个:https://steamcommunity.com/app/221410/discussions/0/4027969835237318998/

主要内容就是:
sudo sysctl -w vm.max_map_count=16777216
设置每个进程可以拥有的最大虚拟内存映射数量。
通过cat /proc/sys/vm/max_map_count我可以看到当前我的内核参数里这个值是65530
我觉得这可能确实有点用,因为我曾经在尝试用Proton 运行DayZ时调整过该参数,修改后确实能让DayZ跑起来。
然后实践证明没什么卵用。

本来我不想换手机,但是最近被设备权限导致的一些问题恶心到了。痛定思痛,务必把设备权限拿回自己的手里,简单查询了一下确定OnePlus Ace3V 可以解锁Bootloader lock且价格合适之后我就下单花了1455买了,昨天买今天到,顺丰效率很高。
随机赠送了充电头和红色USB A2C线材,充电器型号为:VCBAOBCH ,手机代号:JHPC
到手后立即

sudo apt install adb fastboot 
adb reboot bootloader
fastboot flashing unlock

解锁完整个人都舒了口气,接下来迁移旧机数据,随后备份init.img 再刷入KernelSU即可将权限拿回自己手里。

问题原因

Linux(包括 Debian 12)默认将硬件时钟(RTC)设置为 UTC 时间(协调世界时),而 Windows 11 则会将硬件时钟视为 本地时间(Local Time)。因此,当你从 Windows 切换到 Debian 时,Linux 会将硬件时钟视为 UTC,并根据你的时区调整显示时间;同样,从 Debian 切换到 Windows 时,Windows 会将硬件时钟视为本地时间,从而导致时间显示错误。

要解决这个问题,你可以选择以下两种方法之一:要么让 Linux 也使用本地时间,要么让 Windows 使用 UTC 时间。

解决方案一:将 Linux 设置为使用本地时间

如果你更常使用 Windows,或者更习惯 Windows 处理本地时间的方式,你可以让 Debian 12 也将硬件时钟视为本地时间。这样在切换操作系统时,时间显示将保持一致。

步骤

  1. 在 Debian 12 中执行以下命令,将硬件时钟设置为本地时间:

    timedatectl set-local-rtc 1 --adjust-system-clock
  2. 运行以下命令,验证设置是否生效:

    timedatectl
  3. 你应该在输出中看到类似以下内容:

    RTC in local TZ: yes

这意味着你的 Linux 系统现在会使用本地时间,而不是 UTC 时间。

注意事项

虽然这种方法简单有效,但可能会对依赖于 UTC 时间的服务产生影响。例如,一些日志系统或时间同步服务可能会在这种设置下产生错误的时间戳。因此,如果你在 Linux 下运行这些服务,请谨慎选择该方案。

解决方案二:将 Windows 设置为使用 UTC

如果你更常使用 Linux 或者希望遵循 UTC 时间的国际标准,可以选择让 Windows 11 使用 UTC 时间。这样,两个操作系统都将以 UTC 为基础进行时间显示,避免冲突。

步骤

  1. 按下 Win + R,输入 regedit,并按回车,打开 Windows 注册表编辑器。
  2. 导航到以下路径:

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\TimeZoneInformation
  3. 在右侧区域,右键单击空白区域,选择 新建 > DWORD(32位)值,并将其命名为 RealTimeIsUniversal
  4. 双击该值,将其数值数据设置为 1,然后点击 确定
  5. 重启 Windows 使更改生效。

注意事项

这种方法对 Windows 的使用几乎没有影响,特别是如果你不依赖 Windows 的时间戳精确性(如对本地时间的依赖较少)。Windows 和 Linux 都会以 UTC 为基准,保证两个系统时间一致。

总结

在双系统中纠正时间错误有两种解决方法,分别是让 Linux 使用本地时间 或者 Windows 使用 UTC 时间。根据你日常使用的操作系统以及对时间精度的需求,你可以选择适合你的方案:

  • 如果你更常使用 Windows,选择 解决方案一
  • 如果你更常使用 Linux,或者希望两个系统都基于 UTC 时间,选择 解决方案二

这样,无论你在两个系统之间如何切换,都能确保时间显示正确。


必看:NvidiaGraphicsDrivers ——Debian Wiki

启用专有/争议存储库

命令忘了,手动编辑吧=-=手动编辑是不可能的,一行命令能解决我为什么要再打开编辑器?
sudo apt-add-repository non-free
sudo apt-add-repository contrib
你还可以使用--remove参数禁用某个存储库,比如main

安装驱动

sudo apt install nvidia-driver firmware-misc-nonfree

启用wayland

使用NVIDIA驱动程序启用内核模式设置

echo 'GRUB_CMDLINE_LINUX="$GRUB_CMDLINE_LINUX nvidia-drm.modeset=1"' | sudo tee /etc/default/grub.d/nvidia-modeset.cfg
sudo update-grub
## 避免休眠问题
sudo apt install nvidia-suspend-common  #可能已被安装
sudo systemctl enable nvidia-suspend.service
sudo systemctl enable nvidia-hibernate.service
sudo systemctl enable nvidia-resume.service

验证是否已启用PreserveVideoMemoryAllocations NVIDIA模块参数

cat /proc/driver/nvidia/params | grep PreserveVideoMemoryAllocations
我们希望他输出1
这时候你大概还没有在安装后重启操作系统,所以这个文件压根还不存在。为了一劳永逸,你可以执行如下命令提前解决,反正多重复一次也没什么关系。
echo 'options nvidia NVreg_PreserveVideoMemoryAllocations=1' | sudo tee /etc/modprobe.d/nvidia-power-management.conf
sudo reboot #重启直接选择Wayland登录,如果你刚安装好的的操作系统没被你动过别的地方那么Wayland应该可用正常使用。

本文标题很长,但是没有废话:请再次确定你的设备情况是否与我相同
解决Debian12 N卡驱动更新到bookworm-backports 版本BIOS 使用dGPU(独显直连)模式时被迫从wayland切换到X11导致开机无法自动切换到KDE登录界面的问题

为什么我不得不使用X11

我通过backports更新到了最新的Nvidia driver 版本:
NVIDIA Driver Version:535.183.06
NVML Version:12.535.183.06
这个版本即使设置nvidia_drm.modeset=1 wayland登录仍然会卡在黑屏+鼠标的界面动弹不得。
即使时过去的Stable版本驱动可使用wayland,也不可避免出现多窗口时闪屏的问题且无法修复。
所以我不得不使用x11。

解决问题

sudo nvidia-settings
选择X Server Display Configuration
确定此页面配置信息无误后点击右下角Save to X Configuration File
点击保存即可。
接下来关机重启X11登录试试吧!