$ dbus-run-session gnome-shell --nested --wayland
Right click on the VM and click clone
recovery drive
Boot the new VM
Login to MS Windows
Create a 4GB emulated USB storage device in Libvirt Manager
Click the Start Button
Search create a recovery drive
Click the search result of the same name
I unchecked Back up system files to the recovery drive.
Finish creating the recovery drive
It actually only used 430MB, but MS’s documentation suggested 4GB
Shutdown the VM
MS’s mbr2gpt
is incapable of correcting this.
Boot a Live Linux ISO with GParted
Add empty space to the beginning and end of the storage device
I added 257MB of empty space to the beginning for the future UEFI partation
I added 1MB of empty space to the end
It took a while to move the Windows Partition 257MB to the right
Shutdown the VM
MS’s mbr2gpt
also fails until this is corrected.
Boot the MS Windows recovery drive
Troubleshoot -> Command Prompt
Rewrite the Boot Sector
> bootsect /nt60 all /mbr
Add the entry into MS Windows’s Boot Menu
> bcdboot C:\windows /s C:
Shutdown the VM
Boot the new VM
Select the MS Windows boot menu boot entry with Volume 1
Login to MS Windows
Open CMD as Administrator
View boot menu entries
> bcdedit
Find the identifier
of the old entry, not {current}
or {bootmgr}
Delete the old entry
> bcdedit /delete {eb9a84dd-716a-11eb-8036-f51dc98f7c33}
The operation completed successfully.
Shutdown the VM
Boot the MS Windows recovery drive
Troubleshoot -> Command Prompt
Check and repair the MS Windows filesystem, or mbr2gpt
will surely fail
> chkdsk /F C:
Now actually run the conversion
> mbr2gpt /convert
mbr2gpt
annoyting shrinks the MS Windows partition and places the UEFI partition at the end.
Shutdown the VM
Boot a Live Linux ISO with GParted
Delete the UEFI partition
Create a new partition at the beginning with the fat32
filesystem
Resize the MS Windows filesystem and partition to fill the empty space at the end
Apply these changes
Now set the esp
and boot
flags for the newly created UEFI partition
Shutdown the VM
Boot the MS Windows recovery drive
Troubleshoot -> Command Prompt
List disk volume
s
> diskpart
DISKPART> select disk 0
DISKPART> list volume
You will see the UEFI partition’s filesystem is now mounted
Mount the filesystem
DISKPART> select volume 2
DISKPART> assign letter Z:
DISKPART> exit
Write the data to the UEFI partition’s filesystem
> bcdboot C:\windows /l en-us /s Z: /f UEFI
Delete the new VM in Libvirt Manger
Do not delete the OS image
Create a new VM with UEFI boot using this image
]]>Stop the array:
# mdadm --stop /dev/md0
Assemble the array with no-ppl
:
# mdadm --assemble /dev/md0 --update=no-ppl /dev/sdg1 /dev/sde1 /dev/sdh1 /dev/sdf1 /dev/sdc1
Add the new drive:
# mdadm --add /dev/md0 /dev/sdd1
Grow the array and set consistency policy back to ppl :
# mdadm --grow /dev/md0 --consistency-policy=ppl --raid-devices=6
tmpfs
I needed to install some packages on the live session, but pacman
complained that there wasn’t enough space.
# mount -o remount,size=4G /run/archiso/cowspace
Install the needed tools:
# pacman -Syu dosfstools mtools libisoburn
Two text files are needed:
$ touch meta-data
$ nano user-data
#cloud-config
users:
- name: root
ssh_authorized_keys:
- ssh-rsa <RSA KEY>
write_files:
- content: |
[Security]
PreSharedKey=<WIFI KEY>
path: /var/lib/iwd/blah.psk
Create a FAT image with the label CIDATA
:
$ mkfs.fat -C -n CIDATA cloud-init.img 2048
Copy the previously made files to the filesystem of the image file:
$ mcopy -i cloud-init.img meta-data user-data ::
Add this image to the installer ISO:
$ xorriso -indev archlinux-x86_64.iso -outdev archlinux-x86_64-with-cidata.iso -append_partition 3 0x0c cloud-init.img -boot_image any replay
Copy the image to the flash drive:
# pv archlinux-x86_64-with-cidata.iso > /dev/sdX
$ sudo pacman -Syu noto-fonts noto-fonts-cjk noto-fonts-emoji noto-fonts-extra
.desktop
file to your local applications direcory:
$ cp /usr/share/applications/org.gnome.Terminal.desktop ~/.local/share/applications/
Edit ~/.local/share/applications/org.gnome.Terminal.desktop
Add new-tmux-session
to Actions
:
Actions=new-window;preferences;new-tmux-session;
Add the new action:
[Desktop Action new-tmux-session]
Name=New tmux Session
Exec=gnome-terminal --command tmux new
Github Pages
. It uses Jykell
to generate a static site. Find out more at pages.github.com.
I am using theme jekyll/minima. I have integrated master
into my website repository because the current released version, 2.5.1
, doesn’t have skins; 3.x will have skins. The site would be very white without this skin.
To add a new post I just add a new markdown or html file to the _post
directory with a little header. I can even do this from the GitHub web interface. The repository can also be cloned and served with jekyll
to view locally as you work on it.
define language for syntax highlighting on old posts
]]>~/.local/share/xorg/
GDM users should check the systemd journal.
Reference: Arch Linux Wiki
]]>HandleLidSwitch=ignore
Apply Changes:
# systemctl restart systemd-logind.service
Reference: Arch Linux Wiki
]]>