sysconfig.txt reference
sysconfig.txt is a plain-text file on the BOOT partition of a freshly flashed card. On the first boot, Mo OS reads the supported settings and removes the file after processing. This is the supplied first-boot preconfiguration workflow; afterwards, use the normal Mo OS tools described in Users & security settings and Network.
This page describes the file shipped with Mo62A image V1.1.0 (built 2026-08-19). The current template is bin/sysconfig.txt in the Mo62A repository.
File format
- One setting per line, written as
key=value. Everything after the first=is the value, so a password may contain spaces or symbols. Do not add quotation marks. - A line that starts with
#is ignored. Remove the#to enable a setting. - Edit the file on any computer: the
BOOTpartition appears as a removable drive after flashing. See Pre-configure the board. - Unknown keys are ignored. Spaces before the key or value are removed, and a file saved with Windows line endings is accepted.
Settings
Login account
| Key | Default | Meaning |
|---|---|---|
user_name | debian (enabled) | Account to create. It joins the sudo group and can run sudo without a password. |
user_password | 123456 (enabled) | Password for that account. Change it before the first boot; the default is public. |
user_realname | off | Full name shown by the desktop. Defaults to the username. |
user_shell | off (bash) | Login shell: bash or zsh. An unavailable shell falls back to bash. |
user_ssh_key | off | An OpenSSH public key line, or an http://, https:// or file:// URL to download one from, installed in the account's ~/.ssh/authorized_keys. |
If the account already exists, for example when sysconfig.txt is applied to a reused card, the shell and password are updated and the account is kept.
Root account
| Key | Default | Meaning |
|---|---|---|
root_password | off | Sets a password for root, for the local console, serial console and su. Without it the root account stays locked. It does not enable root login over SSH with a password. |
root_ssh_key | off | Public key, or a URL to one, that allows root login over SSH with that key. |
Host name
| Key | Default | Meaning |
|---|---|---|
hostname | off (Mo62A) | Host name of the board, also announced as HOSTNAME.local on the local network. |
Locale and time zone
| Key | Default | Meaning |
|---|---|---|
locale | off (en_US.UTF-8) | System locale, for example en_US.UTF-8 or de_DE.UTF-8. The locale must be listed in /etc/locale.gen. |
timezone | off (Etc/UTC) | Time zone name from the system list, for example Europe/Berlin or Asia/Shanghai. |
Wi-Fi
| Key | Default | Meaning |
|---|---|---|
wifi_ssid | off | Network name to join on the first boot. |
wifi_password | off | Its password. Required when wifi_ssid is set; otherwise Wi-Fi is skipped. |
wifi_country | off (CN) | Two-letter regulatory domain, for example CN, US or DE. |
The connection is saved as a NetworkManager profile named WiFi-SSID and reconnects automatically on later boots.
Static Ethernet address
| Key | Default | Meaning |
|---|---|---|
static_ip | off (DHCP) | IPv4 address for the wired port. Setting it switches the port from DHCP to a static address. |
static_mask | off | Netmask, either a prefix length such as 24 or dotted form such as 255.255.255.0. |
static_gateway | off | Default gateway. |
static_dns | off | DNS server address. |
Example
A file that creates a personal account with key login, names the board and sets the time zone:
user_name=alice
user_password=choose-a-strong-password
user_realname=Alice Example
user_ssh_key=ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAA... alice@workstation
hostname=mo62a-lab
timezone=Europe/Berlin
Check what was applied
The first boot writes /var/log/mo-62a-auto-config.log. Review it for errors and check the resulting accounts, network connections and system settings; the final removal message alone does not prove every requested setting succeeded. Example log excerpt:
[mo-62a-config] Starting (2026-04-13T19:38:17+00:00); config=/boot/firmware/sysconfig.txt
[mo-62a-config] Parsed 3 active setting(s)
[mo-62a-config] Setting hostname to mo62a-demo
[mo-62a-config] Creating user USERNAME (shell /bin/bash)
[mo-62a-config] Config applied and /boot/firmware/sysconfig.txt removed (2026-04-13T19:38:18+00:00)
The account name is replaced with USERNAME in this excerpt. Removing sysconfig.txt does not securely erase its previous contents from flash media. Use a temporary setup password and change it after setup; avoid keeping copies containing credentials. After the first boot, ls /boot/firmware/sysconfig.txt reports that the file no longer exists. To apply a new sysconfig.txt, flash the card again; the settings are not re-read on later boots.
Troubleshooting
| Symptom | What to check |
|---|---|
| The account was not created | Read /var/log/mo-62a-auto-config.log. The file must be on the BOOT partition, named exactly sysconfig.txt, with user_name enabled. |
| Login with the chosen password fails | Make sure the line had no quotation marks or trailing spaces. Reset the password from the local desktop or serial console with sudo passwd USERNAME. |
| Wi-Fi did not connect | wifi_password is required with wifi_ssid. Check the SSID spelling and the country code, then connect manually as described in Network. |
| The SSH key was not installed | The value must be a complete public key line or a reachable URL. Install it later with ssh-copy-id; see Remote access. |
| The file is still on the card | The first boot did not complete. Check /var/log/mo-62a-firstboot-install.log. |
Related pages
- Install the OS: flashing the image and editing the file.
- Storage & boot: what else happens on the first boot.
- Users & security settings: changing accounts and passwords later.