{{Note|Arch uses [[systemd]] by default. If you use OpenRC, please mention so while asking for help.}}

{{Note|Arch uses [[systemd]] by default. If you use OpenRC, please mention so while asking for help.}}

−

OpenRC is an alternate init system developed by Gentoo developers. OpenRC is a dependency based init system that works with the system provided init program, normally {{Ic|/sbin/init}}. It is not a replacement for {{Ic|/sbin/init}}.

+

OpenRC is an alternate init system developed by Gentoo developers. OpenRC is a dependency based init system that works with the system provided init program, normally sysvinit. It is not a replacement for sysvinit.

== Installation ==

== Installation ==

−

OpenRC is available in the [[AUR]]. You can choose to install either {{AUR|openrc}} or {{AUR|openrc-git}} package. You will also need to install {{AUR|openrc-arch-services-git}} (provides service files for use with openrc on arch) and {{AUR|openrc-sysvinit}} (a slightly patched version of traditional sysvinit).

+

OpenRC is available in the [[AUR]]. You can choose to install either {{AUR|openrc}} or {{AUR|openrc-git}} package. You will also need to install {{AUR|openrc-arch-services-git}} (provides service files for use with openrc on arch) and {{AUR|openrc-sysvinit}} (a slightly patched version of traditional sysvinit). For the sake of compatibility with initscripts, {{AUR|openrc-sysvinit}} installs the sysvinit init binary as {{ic|/sbin/init-openrc}}.

The packages will be installed under {{Ic|/etc/openrc}} instead of the default location of {{Ic|/etc}}, so that users can switch to [[initscripts]] or [[systemd]] when desired.

The packages will be installed under {{Ic|/etc/openrc}} instead of the default location of {{Ic|/etc}}, so that users can switch to [[initscripts]] or [[systemd]] when desired.

Line 12:

Line 12:

== Configuration ==

== Configuration ==

−

For booting with OpenRC add {{Ic|1=init=/sbin/init-openrc}} to the kernel line in your bootloader configuration. If you want to go back to systemd replace it with {{ic|1=init=/usr/lib/systemd/systemd}}.

+

For booting with OpenRC add {{Ic|1=init=/sbin/init-openrc}} to the kernel line in your bootloader configuration. If you want to switch back to systemd, change it to {{ic|1=init=/usr/lib/systemd/systemd}}.

{{Warning| The openrc package lacks networking support. You can use {{Pkg|net-tools}} or [[netcfg]] to deal with that.}}

+

=== Network ===

+

There are multiple ways to get a network up and running. One way is by configuring the {{ic|/etc/openrc/conf.d/network}} file. Both the {{ic|ip}} ({{Pkg|iproute2}}) and the {{ic|ifconfig}} ({{Pkg|net-tools}}) commands are supported.

−

If you use syslog-ng , check etc/syslog-ng/syslog-ng.conf

+

Below is an example configuration using {{ic|ip}}.

−

Look for {{bc| unix-dgram("/run/systemd/journal/syslog")}} , comment it out

−

and add this line instead : {{bc|unix-dgram("/dev/log");}}

−

{{Note|If you do not do this, NOTHING will be logged !}}

+

{{bc|

+

<nowiki>ip_eth0="192.168.1.2/24"

+

defaultiproute="via 192.168.1.1"

+

ifup_eth0="ip link set \$int mtu 1500"</nowiki>}}

−

The logging of openrc appears to be off by default

+

The network service is added to the boot runlevel by default, so no further action is required.

−

edit /etc/openrc/rc.conf , and uncomment this line :

+

+

You can also use [[NetworkManager]], [[Dhcpcd]] or {{AUR|netcfg}} by enabling the respective services.

+

+

Take a look at [[Network Configuration]] for a detailed look at networking in general.

+

+

=== Logging ===

+

+

====syslog-ng====

+

If you use syslog-ng, comment out the following line in {{ic|/etc/syslog-ng/syslog-ng.conf}}:

+

{{bc|unix-dgram("/run/systemd/journal/syslog")}}

+

and add this line instead: {{bc|unix-dgram("/dev/log");}}

+

{{Note|Without making this change syslog-ng will fail to run and as a result nothing will be logged!}}

+

+

====Boot logging====

+

OpenRC's boot logging is disabled by default. To enable it, uncomment the following line in {{ic|/etc/openrc/rc.conf}}:

Revision as of 12:41, 5 August 2013

Note: Arch uses systemd by default. If you use OpenRC, please mention so while asking for help.

OpenRC is an alternate init system developed by Gentoo developers. OpenRC is a dependency based init system that works with the system provided init program, normally sysvinit. It is not a replacement for sysvinit.

Installation

OpenRC is available in the AUR. You can choose to install either openrcAUR or openrc-gitAUR package. You will also need to install openrc-arch-services-gitAUR (provides service files for use with openrc on arch) and openrc-sysvinitAUR (a slightly patched version of traditional sysvinit). For the sake of compatibility with initscripts, openrc-sysvinitAUR installs the sysvinit init binary as /sbin/init-openrc.

The packages will be installed under /etc/openrc instead of the default location of /etc, so that users can switch to initscripts or systemd when desired.

Configuration

For booting with OpenRC add init=/sbin/init-openrc to the kernel line in your bootloader configuration. If you want to switch back to systemd, change it to init=/usr/lib/systemd/systemd.