Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

start documentation/settings for enabling systemd #29

Merged
merged 2 commits into from
Oct 9, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions conf/local.conf
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,9 @@ PACKAGE_FEED_URIS ??= "http://<FEEDSERVER>"

# Enable serial console on Raspberry PI systems
ENABLE_UART = "1"

# Uncomment the following to enable systemd
#DISTRO_FEATURES_append = " systemd"
#VIRTUAL-RUNTIME_init_manager = "systemd"
#DISTRO_FEATURES_BACKFILL_CONSIDERED = "sysvinit"
#VIRTUAL-RUNTIME_initscripts = ""
26 changes: 26 additions & 0 deletions docs/init-system.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Init System

SysVinit and Systemd are common init systems. SysVinit is the default, but Systemd can
be enabled be adding the following to local.conf:

```
DISTRO_FEATURES_append = " systemd"
VIRTUAL-RUNTIME_init_manager = "systemd"
DISTRO_FEATURES_BACKFILL_CONSIDERED = "sysvinit"
VIRTUAL-RUNTIME_initscripts = ""
```

Systemd takes considerably more space than SysVinit. With a rPI2 build, the following
are the rootfs sizes for core-image-minimal:

* SysVinit
* space used in ext4 filesystem on running system using df: 4.7MB
* adding sizes of files in image from buildhistory: 4.3MB
* number of files in image: 696
* Systemd
* space used in ext4 filesystem on running system using df: 33.2MB
* adding sizes of files in image from buildhistory: 22MB
* number of files in image: 1,806

There is a significant size cost with systemd, so in some cases it may make sense to
use sysvinit if image size is a priority.