Categories
Tech Tips

How to reset lost root password on Raspberry Pi running Arch Linux

Assumption: SD is not encrypted

Plug SD onto another working computer, look for the “cmdline.txt” file and edit it by appending “init=/bin/sh” after “rootwait”. Save the file, remove the SD and plug it back to the RPi and boot.

You’ll be dropped into a shell. Change your passwd, then hit CTRL-ALT-DEL to trigger a reboot. Switch off the RPi when the shutdown completes, just before the boot starts. Unplug the SD and plug it onto the other working computer. Remove “init=/bin/sh” from “cmdline.txt” file.

Plug the SD back onto the RPi, boot and you can now login with the newly reset password.

Categories
Tech Tips

How to stop IBus from removing your xmodmap mappings


If the use of IBus removes your xmodmap keymaps in X, try enabling the “Use system keyboard layout” option under the “Advanced” tab in the IBus Preferences.

Versions:
– ibus 1.5.5-1
– xorg-xmodmap 1.0.8-1

Categories
Tech Tips

How to make dhclient send hostname to DHCP server


My Arch Linux recently switched from dhcpcd to dhclient as the DHCP client. The DHCP server isn’t assigning a FQDN to this client and it turns out that dhclient isn’t telling the server what’s the client’s hostname.

Solution:

Create config file /etc/dhclient.conf with content:

send host-name = gethostname();