今回は第576回で紹介したGPD MicroPCにUbuntu 20.
第576回との違い
GPD MircoPCは現在でも入手でき、
今回は第576回を継承しつつ新たにGPD MicroPCを購入された方向けにUbuntu 20.
SSDの入れ替え
必須ではありませんが、
SSDを交換する際のGPD MicroPCの分解方法は検索すればいくらでも見つかるので省略しますが、
これで無事に分解できたのですが、
Ubuntu 20.04 LTSのインストール
交換したSSDにUbuntu 20.
いずれにせよUbuntu 20.

各種設定
第576回の
テーマ
CapsLockキーをCtrlキーにする場合は、

ハイバネートとハイブリッドスリープ
GPD MicroPCはその特性上常用するようなものではなく、
まずはスワップファイルを拡張します。昔はハイバネートを使用する場合はメモリと同容量のスワップパーティションが必要といわれていましたが、
拡張と表現していますが、
$ swapoff -a $ sudo fallocate -l 8g /swapfile $ sudo mkswap /swapfile
ここでスワップファイルのUUIDが表示されるため、
/etc/
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
の行に追加します。例は次のとおりです。
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash resume=UUID=6ce18d51-bc98-4218-966b-e216817f097e"
前述のとおりスワップファイルを拡張した際にUUIDが表示されているので、
設定完了後次のコマンドを実行してください。
$ sudo update-grub
ここで一度再起動します。
root権限がなくてもハイバネートできるよう、
[Re-enable hibernate by default in upower]
Identity=unix-user:*
Action=org.freedesktop.upower.hibernate
ResultActive=yes
[Re-enable hibernate by default in logind]
Identity=unix-user:*
Action=org.freedesktop.login1.hibernate;org.freedesktop.login1.handle-hibernate-key;org.freedesktop.login1;org.freedesktop.login1.hibernate-
multiple-sessions;org.freedesktop.login1.hibernate-ignore-inhibit
ResultActive=yes
さて、
$ systemctl hibernate
しかし再起動しても新たにログインしたのと同じ状態になってしまいます。したがってpm-utilsパッケージに含まれている/usr/
次のコマンドを実行してください。
$ sudo apt install pm-utils $ sudo cp /lib/systemd/system/systemd-hibernate.service /etc/systemd/system $ sudo cp /lib/systemd/system/systemd-hybrid-sleep.service /etc/systemd/system
見てのとおり、
/etc/
[Unit]
Description=Hibernate
Documentation=man:systemd-suspend.service(8)
DefaultDependencies=no
Requires=sleep.target
After=sleep.target
[Service]
Type=oneshot
ExecStart=/usr/sbin/pm-hibernate
/etc/
[Unit]
Description=Hybrid Suspend+Hibernate
Documentation=man:systemd-suspend.service(8)
DefaultDependencies=no
Requires=sleep.target
After=sleep.target
[Service]
Type=oneshot
ExecStart=/usr/sbin/pm-suspend-hybrid
一番下の行を書き換えているだけです。
次のコマンドのとおり、
$ sudo systemctl daemon-reload $ systemctl hibernate
ハイブリッドスリープを実行する場合は、
$ systemctl hybrid-sleep
コマンドラインではなくGNOME Shellからハイバネートやハイブリッドスリープを実行する場合はHibernate Status Buttonをインストールするといいでしょう

Fcitxを使用する場合
IBusの代わりにFcitxを使用することもできます。この場合はMozcのキーバインドを変更する必要がないので設定がシンプルになります。問題点としてはGNOME Shell上で
次のコマンドを実行してください。
$ sudo add-apt-repository ppa:ikuya-fruitsbasket/fcitx $ sudo apt install fcitx fcitx-mozc $ im-config -n fcitx
再起動してログインするとFcitxが起動するようになります。
Fcitxの設定を表示し、

「全体の設定」

IBusのアイコンは右上に表示されたままですが、
