Software Update and Package Management
Your device running KerOS supports two update methods:
Package-based updates (recommended):
Using APT (Advanced Package Tool), you can update or install individual software packages. This method only updates the required components and keeps your data intact.
More details about a full software update using APT below
Firmware reinstallation (via SWUpdate):
This method replaces the entire system image with a new firmware version. It is similar to reinstalling an operating system on a computer.
Using this method erases all user data and customizations.
Unless you specifically need to reinstall the full firmware, Kerlink strongly recommends using APT for regular updates and maintenance. See firmware reinstallation if you want to proceed.
Getting Started with APT
APT is the package manager used on KerOS to install, upgrade, and remove software packages. It works with:
- The official Kerlink repository (preconfigured by default)
- Third-party repositories
- Local .deb package files
For full details, see the official APT documentation.
Installing Packages
From the Kerlink official repository
The official repository is already configured on your device.
Update the APT package list:
sudo apt update
Install a package:
sudo apt install <package_name>
Example with tcpdump:
sudo apt update && sudo apt install tcpdump
You can also search for package containing a string:
sudo apt search something
From a local package file
If you obtained a Debian package file (e.g. mypackage.deb), install it with:
sudo apt install ./mypackage.deb
From a third party repository
To install a new package from a third-party repository, please refer to the online APT documentation.
Upgrading Packages
Upgrade a single package
sudo apt update && sudo apt install --only-upgrade <package_name>
Upgrade the entire system
To synchronize all packages with the latest available versions:
sudo apt update && sudo apt dist-upgrade
Handling Configuration File Conflicts
When upgrading, if a package needs to update a configuration file you have modified, APT will ask what to do. You can predefine the behavior using dpkg options:
--force-confold: keep your current configuration, install the new one as .dpkg-dist.--force-confnew: always replace your file, keep the old one as .dpkg-old.--force-confdef: let dpkg decide automatically when possible (default).--force-confmiss: reinstall a configuration file if it is missing.
Example command for an automatic conflict resolution:
sudo apt-get -o Dpkg::Options::="--force-confdef" \
-o Dpkg::Options::="--force-confold" \
--assume-yes dist-upgrade
Automatic System Reboot after Package Installation
Certain package updates —particularly those involving the Linux kernel or low-level system libraries— require a system reboot to fully apply the changes. Our system includes a custom APT hook that automatically detects when a reboot is necessary.
The reboot mechanism ensures that critical updates —especially security patches— are properly activated, maintaining the system’s stability and compliance. The reboot will take place automatically.
Automatic Updates
By default on the firmware, automatic updates are deactivated and configuration files are not present.
To keep your system up-to-date without manual intervention, you can configure automatic updates with unattended-upgrades.
- Installed by default on KerOS ≥ 6.3
- Otherwise, can be installed manually:
sudo apt install unattended-upgrades
Configuration files:
- Default:
/etc/apt/apt.conf.d/50unattended-upgrades - Local customizations:
/etc/apt/apt.conf.d/52unattended-upgrades-local
To avoid configuration files conflict, do not modify Keros default configuration, prefer overriding using local customization
Example configuration:
Unattended-Upgrade::Origins-Pattern {
"origin=*";
}
Unattended-Upgrade::Remove-Unused-Dependencies "true";
Unattended-Upgrade::SyslogEnable "true";
To enable automatic upgrades, /etc/apt/apt.conf.d/20auto-upgrades must also include:
APT::Periodic::Update-Package-Lists "always";
APT::Periodic::Unattended-Upgrade "always";
Scheduling
APT automatically runs updates through systemd timers:
- apt-daily.timer: refreshes package lists
- apt-daily-upgrade.timer: installs updates
Check timers with:
sudo systemctl list-timers --all
Adjust scheduling:
sudo systemctl edit apt-daily.timer
sudo systemctl edit apt-daily-upgrade.timer
Repository Lifecycle
Kerlink provides two types of repositories:
-
Stable (default, recommended):
Contains the supported and validated software versions for production use. -
Testing:
Contains newer packages being validated for the next release. This repository allows you to test new packages.
Suitable only for lab testing environments, NOT recommended for production.
Checking or changing your repository
Configured repositories can be found in:
/etc/apt/sources.list.d/keros-deb.list
Example (default stable):
deb https://deb.keros.wanesy.com/<machine> stable main
To switch to testing, edit this file and replace with:
deb https://deb.keros.wanesy.com/<machine> testing main
Best Practices
- Always run
sudo apt updatebefore installing or upgrading packages. - Prefer the stable repository unless you need to test pre-release features.
- Use APT updates whenever possible; reserve SWUpdate firmware reinstallation for recovery or major upgrades.
- Regularly configure unattended-upgrades to keep your system secure and up-to-date.