chromebook 主系统中时间主要是使用 tlsdate 来同步时间,因此我们只需要机器开启了开发者模式,以 root 身份进入 shell 即可修改对应的配置文件。
# tlsdate 文件
/etc/tlsdate/tlsdated.conf
# 修改其中的 host 对应的地址,默认应该是 clients3.google.com,其中 proxy 与非 proxy 都需要替换
sed -i 's/clients3.google.com/www.net.cn/g' /etc/tlsdate/tlsdated.conf
# 人工执行 tlsdate 校准时间
tlsdate www.net.cnchromebook 在启用了 arcvm 特性后,安卓子系统的时间不再与主系统同步,因此需要人工指定子系统的 ntp 服务器地址。
# 登录 chromeOS shell 后
adb shell settings put global ntp_server ntp.aliyun.com
# 重启机器后安卓子系统就会自动校正时间chromebook 默认根分区是存在只读限制的,需要通过移除 rootfs 验证后才能正常读写根分区
# 使用 root 登录 chromeOS shell
cd /usr/share/vboot/bin/ && ./make_dev_ssd.sh --remove_rootfs_verification
# 接下来会有提示指定特定 partitions 来移除 rootfs 验证,我的本子是 4,因此后续命令为
./make_dev_ssd.sh --remove_rootfs_verification --partitions 4# chrome 打开以下链接
chrome://flags#crostini-ime-support
# 然后将该值设定为 Enable 后重启 chromeOS 即可在 crostini 中使用 chromeOS 的输入法# 参考链接
https://github.com/dv-anomaly/ttf-wps-fonts
# 执行命令
git clone https://github.com/dv-anomaly/ttf-wps-fonts.git
cd ttf-wps-fonts
sudo bash install.sh# chrome 打开以下链接
chrome://flags#scheduler-configuration
# 将 [Scheduler Configuration] 设定为 [Disables Hyper-Threading on relevant CPUs]
# 最后重启 chroneOS# 策略文件位于
/sys/devices/system/cpu/cpu*/cpufreq/scaling_governor
# 查看方法(需要以 root 身份登录 chromeOS shell
cat /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor
# 修改 CPU 调频策略(我的机器是 8 核,所以范围是 {0..7},其他核心数量自行修改
for i in {0..7};
do echo performance > /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor;
done
# 关于几种调频策略
1. performance:只注重效率,将 CPU 频率固定工作在其支持的最高运行频率上,而不动态调节。
2. powersave:将 CPU 频率设置为最低的所谓“省电”模式,CPU 会固定工作在其支持的最低运行频率上。
3. ondemand:按需快速动态调整CPU频率,一有CPU计算量的任务,就会立即达到最大频率运行,等执行完毕就立即回到最低频率。
# 根据个人经验,调整为 performance 后机器不会再掉帧了,当然发热也随之上升了...如果机器是 arm 架构的话就勇敢的改把,毕竟发热也大不了多少,但是流畅是货真价实的体现出来了腾讯云购买轻量服务器,选择自动部署 Cloud-Studio。然后 IP 访问即可。
使用腾讯云的 cloud-studio
使用 TeamCode 的 Cloud-IDE
使用 GitHub 的 CodeSpace
本机部署 Code-Server :不推荐,因为 ChromeOS 新版本无法本机部署,只能寄托于 arcvm 跟 crostini 来安装。
Chrome 浏览器地址栏输入chrome://flag 然后搜索Insecure origins treated as secure
将该选项的Disable 修改为Enable
在选项下方的框中输入你的 Cloud-Studio 地址,例如
http://111.222.333.444可选项:右键 → 保存并分享 → 将网页作为应用安装
chromebook 开启 arcvm 后,大概会吃掉 2-3G 左右的运存,当不需要使用 Android 应用的时候,可以通过下面方式临时关闭 arcvm 来释放内存,从而减少卡顿
# 使用键盘切换到 tty2
快捷键 Ctrl + Shift + →
# 使用 root 账号登录
输入 root
# 执行命令关闭
crosvm stop /run/vm/*/*恢复方式:锁定屏幕后解锁,会自动运行