src/wiki/unix/linux.m4
2022-11-24 22:47:54 -05:00

127 lines
5.9 KiB
Plaintext

_header(`Linux')
<UL>
_bentr(`_link(`How to Linux', `http://tldp.yolinux.com/HOWTO/subdir/HOWTO-INDEX.html')')
_bentr(`_link(`How to Use User Mode Linux', `https://christine.website/blog/howto-usermode-linux-2019-07-07')')
_bentr(`<A HREF="https://www.cs.cmu.edu/~awb/linux.history.html">LINUX's History</A>')
_bentr(`_link(`The Linux Kernel documentation', `https://www.kernel.org/doc/html/v4.17/index.html')')
_bentr(`_link(`LINUX is obsolete', `https://groups.google.com/g/comp.os.minix/c/wlhw16QWltI')')
_bentr(`_link(`Linux From Scratch', `http://www.linuxfromscratch.org/')')
_bentr(`_link(`Move your Linux from BIOS to UEFI in place', `https://www.redhat.com/sysadmin/bios-uefi')')
<LI><A HREF="https://www.collabora.com/news-and-blog/blog/2020/08/27/using-the-linux-kernel-case-insensitive-feature-in-ext4/">Using the Linux kernel's Case-insensitive feature in Ext4</A></LI>
</UL>
_subheader(`ACPI')
_bibliography(`
_bentr(`_ref(`#ACPI')')
')
<P>
logind (as part of SystemD), elogind, acpid, and many desktop environments can manage ACPI events automatically, and sometimes this is configured by default as part of a Linux software distribution.
</P>
_subsubheader(`acpid(8)')
_bibliography(`
_bentr(`_link(`acpid', `https://sourceforge.net/projects/acpid2/')')
')
<P>
_man(`acpid(8)') is a daemon that can automatically manage ACPI events on Linux.
</P>
_subheader(`Audio')
<P>
Most audio servers recommend that they be run in userspace with user privileges, with PulseAudio going so far as to exiting when run as root without additional configuration.
The Alpine wiki currently recommends _man(`pipewire(1)'), with postmarketOS, which is based on Alpine, coming pre-configured with PipeWire.
PipeWire is relatively new and the typical audio server used is PulseAudio; _ref(`#debian') and many popular Debian-based distributions come pre-configured with PulseAudio.
</P>
_subsubheader(`ALSA')
_bibliography(`
_bentr(`<A HREF="https://wiki.alpinelinux.org/wiki/Main_Page/Adding_sound">Adding sound</A> (Alpine Linux Wiki)')
_bentr(`<A HREF="https://bbs.archlinux.org/viewtopic.php?id=256857">ALSA lib conf Evaluate error</A>')
_bentr(`<A HREF="https://dev.to/setevoy/linux-alsa-lib-pcmdmixc1108sndpcmdmixopen-unable-to-open-slave-38on">ALSA lib pcm_dmix.c:1108:(snd_pcm_dmix_open) unable to open slave</A>')
')
<P>
The Alpine wiki ("Adding sound") says to install _code(`alsa-conf'), _code(`alsa-lib'), and _code(`alsa-utils'),
add yourself to the _code(`audio') group, and then do some more configuration that I've never needed to do:
Use _man(`alsamixer(1)') to find a working sound card (press _code(`F6') from the first screen ALSAMixer presents)
and edit _code(`/usr/share/alsa/alsa.conf') and change _code(`defaults.ctl.card') and _code(`defaults.pcm.card') to the sound card that works.
</P>
<P>
The Alpine wiki doesn't mention this but you'll need to enable the _code(`alsa') OpenRC service and either start it or reboot.
I also installed _code(`gstreamer') but I don't know why.
</P>
<P>
ALSA is clunky, many people prefer to use a frontend such as Pipewire or PulseAudio that exposes its own interface while remaining compatible with ALSA.
</P>
_subsubheader(`OSS')
<P>
Deprecated, unfortunately.
</P>
_subsubheader(`PipeWire')
_bibliography(`
_bentr(`<A HREF="https://wiki.alpinelinux.org/wiki/PipeWire">PipeWire</A> (Alpine Linux Wiki)')
_bentr(`<A HREF="https://gitlab.freedesktop.org/pipewire/pipewire/-/wikis/home">PipeWire</A> (FreeDesktop Wiki)')
')
<P>
Provided by the _code(`pipewire') package on Alpine.
</P>
<PRE>
RTKit error: org.freedesktop.DBus.Error.ServiceUnknown
</PRE>
<P>
This means you need _program(`rtkit') installed and running through your initialization system.
</P>
_subsubheader(`PulseAudio')
<P>
On Alpine you'll need the _program(`pulseaudio'), _program(`pulseaudio-alsa'), and _program(`alsa-plugins-pulse') packages for PulseAudio with ALSA compatibility.
Start _man(`pulseaudio(1)') when you want audio, ideally in your _file(`.xinitrc').
</P>
_subheader(`Distributions')
<P>
Linux is usually obtained as part of a software distribution put together to form a useable operating system.
</P>
_subsubheader(_ref(`#alpine'))
_subsubheader(_ref(`#arch'))
_subsubheader(_ref(`#debian'))
_subheader(`initramfs')
_bibliography(`
_bentr(`_link(`Initial ramdisk', `https://en.wikipedia.org/wiki/Initial_ramdisk') (Wikipedia)')
_bentr(`_link(`initramfs', `https://wiki.debian.org/initramfs') (Debian Wiki)')
_bentr(`_link(`initramfs', `https://wiki.ubuntu.com/Initramfs') (Ubuntu Wiki)')
')
<P>
_file(`initramfs') is a _ref(`#archives#cpio') archive that contains a small Linux filesystem with just enough utility to mount the actual operating system's root filesystem.
</P>
_subheader(`logind')
_bibliography(`
_bentr(`<A HREF="https://github.com/elogind/elogind">elogind</A>')
_bentr(`<A HREF="https://wiki.gentoo.org/wiki/Elogind">elogind</A> (Gentoo Wiki)')
_bentr(`<A HREF="https://www.freedesktop.org/software/systemd/man/org.freedesktop.login1.html">org.freedesktop.login1</A>')
_bentr(`<A HREF="https://nixos.wiki/wiki/Logind">logind</A> (NixOS Wiki)')
')
<P>
logind (_code(`systemd-logind.service(8)')) is a component of SystemD that exposes information about active users on the system via the org.freedesktop.login1 D-Bus interface which is used by the popular desktop environments GNOME and KDE.
It also handles _ref(`#ACPI') events.
It can be configured in _code(`logind.conf(5)').
</P>
<P>
On systems without SystemD and with conflicting software, _code(`elogind(8)') may be used.
</P>
_subheader(`util-linux')
_bibliography(`
_bentr(`_link(`util-linux', `https://en.wikipedia.org/wiki/Util-linux') (Wikipedia)')
')
<P>
_code(`util-linux') is distributed on all popular Linux distributions and contains utilities users may expect to be already present on their systems, like _man(`more(1)') or _man(`hexdump(1)').
</P>
_subheader(`Xenia')
_bibliography(`
_bentr(`_link(`A hacker fox!', `http://yerf.metafur.org/date/1996-07-14')')
')
<P>
Xenia was an entry for the Linux logo competition which Tux eventually won.
</P>