https://wiki.archlinux.org/api.php?action=feedcontributions&user=Andre.laszlo&feedformat=atomArchWiki - User contributions [en]2024-03-28T20:24:53ZUser contributionsMediaWiki 1.41.0https://wiki.archlinux.org/index.php?title=Acer_Swift_3_SF314-511&diff=771143Acer Swift 3 SF314-5112023-03-04T23:07:56Z<p>Andre.laszlo: fix typo</p>
<hr />
<div>[[Category:Acer]]<br />
{| class="wikitable" style="float: right;"<br />
|-<br />
! Hardware !! PCI/USB ID !! Working?<br />
|-<br />
| Touchpad || || {{Yes}}<br />
|-<br />
| Keyboard || || {{Yes}}<br />
|-<br />
| GPU || {{ic|8086:9a49}} || {{Yes}}<br />
|-<br />
| WiFi || {{ic|8086:a0f0}} || {{Yes}}<br />
|-<br />
| Webcam || {{ic|0408:a094}} || {{Yes}}<br />
|-<br />
| Bluetooth || {{ic|8087:0026}} || {{Yes}}<br />
|-<br />
| Audio || {{ic|8086:a0c8}} || {{Yes}}<br />
|-<br />
| Fingerprint reader || {{ic|04f3:0c7f}} || [https://aur.archlinux.org/packages/libfprint-egis-0575 Experimental]<br />
|}<br />
<br />
== Webcam ==<br />
<br />
This Acer Swift 3 model uses the same Quanta Computer "User Facing" camera as the Swift 1 which works out of the box.<br />
<br />
== Accessibility ==<br />
<br />
The firmware interface on the Acer Swift 3 is simple and keyboard-oriented, so it should be trivial to use with OCR devices.<br />
<br />
== Firmware ==<br />
<br />
{{Pkg|fwupd}} supports the touchpad, memory technology device, CPU, SSD, TPM, ESRT, and graphics card<br />
<br />
=== Secure Boot ===<br />
<br />
[[Secure Boot]] is enabled by default in the BIOS. In order to disable it, a BIOS administrator password must be set.<br />
<br />
== Function Keys ==<br />
<br />
{| class="wikitable"<br />
|-<br />
! Key !! Visible?<sup>1</sup> !! Marked?<sup>2</sup> !! Effect<br />
|-<br />
| {{ic|Fn+F1}} || {{Yes}} || {{Yes}} || {{ic|XF86Sleep}}<br />
|-<br />
| {{ic|Fn+F2}} || {{Yes}} || {{Yes}} || {{ic|XF86RFKill}}<br />
|-<br />
| {{ic|Fn+F3}} || {{Yes}} || {{Yes}} || {{ic|XF86MonBrightnessDown}}<br />
|-<br />
| {{ic|Fn+F4}} || {{Yes}} || {{Yes}} || {{ic|XF86MonBrightnessUp}}<br />
|-<br />
| {{ic|Fn+F5}} || {{No}} || {{Yes}} || Unknown<br />
|-<br />
| {{ic|Fn+F6}} || {{No}} || {{Yes}} || Turns off display<br />
|-<br />
| {{ic|Fn+F7}} || {{No}} || {{Yes}} || Disables touchpad<br />
|-<br />
| {{ic|Fn+F8}} || {{No}} || {{Yes}} || Toggles keyboard backlight<br />
|-<br />
| {{ic|Fn+F9}} || {{Yes}} || {{Yes}} || {{ic|XF86AudioMute}}<br />
|-<br />
| {{ic|Fn+F10}} || {{Yes}} || {{Yes}} || {{ic|XF86AudioLowerVolume}}<br />
|-<br />
| {{ic|Fn+F11}} || {{Yes}} || {{Yes}} || {{ic|XF86AudioRaiseVolume}}<br />
|-<br />
| {{ic|Fn+F12}} || {{No}} || {{Yes}} || Unknown<br />
|-<br />
| {{ic|Fn+Del}} || {{Yes}} || {{Yes}} || {{ic|Insert}}<br />
|-<br />
| {{ic|Fn+RightCtrl}} || {{Yes}} || {{Yes}} || {{ic|Menu}}<br />
|-<br />
| {{ic|Fn+Home}} || {{Yes}} || {{Yes}} || {{ic|Prior}}<br />
|-<br />
| {{ic|Fn+End}} || {{Yes}} || {{Yes}} || {{ic|Next}}<br />
|}<br />
<br />
# The key is visible to {{ic|xev}} and similar tools.<br />
# The physical key has a symbol on it, which describes its function.</div>Andre.laszlohttps://wiki.archlinux.org/index.php?title=Acer_Swift_3_SF314-511&diff=771142Acer Swift 3 SF314-5112023-03-04T23:05:07Z<p>Andre.laszlo: update info on experimental libfprint driver</p>
<hr />
<div>[[Category:Acer]]<br />
{| class="wikitable" style="float: right;"<br />
|-<br />
! Hardware !! PCI/USB ID !! Working?<br />
|-<br />
| Touchpad || || {{Yes}}<br />
|-<br />
| Keyboard || || {{Yes}}<br />
|-<br />
| GPU || {{ic|8086:9a49}} || {{Yes}}<br />
|-<br />
| WiFi || {{ic|88086:a0f0}} || {{Yes}}<br />
|-<br />
| Webcam || {{ic|0408:a094}} || {{Yes}}<br />
|-<br />
| Bluetooth || {{ic|8087:0026}} || {{Yes}}<br />
|-<br />
| Audio || {{ic|8086:a0c8}} || {{Yes}}<br />
|-<br />
| Fingerprint reader || {{ic|04f3:0c7f}} || [https://aur.archlinux.org/packages/libfprint-egis-0575 Experimental]<br />
|}<br />
<br />
== Webcam ==<br />
<br />
This Acer Swift 3 model uses the same Quanta Computer "User Facing" camera as the Swift 1 which works out of the box.<br />
<br />
== Accessibility ==<br />
<br />
The firmware interface on the Acer Swift 3 is simple and keyboard-oriented, so it should be trivial to use with OCR devices.<br />
<br />
== Firmware ==<br />
<br />
{{Pkg|fwupd}} supports the touchpad, memory technology device, CPU, SSD, TPM, ESRT, and graphics card<br />
<br />
=== Secure Boot ===<br />
<br />
[[Secure Boot]] is enabled by default in the BIOS. In order to disable it, a BIOS administrator password must be set.<br />
<br />
== Function Keys ==<br />
<br />
{| class="wikitable"<br />
|-<br />
! Key !! Visible?<sup>1</sup> !! Marked?<sup>2</sup> !! Effect<br />
|-<br />
| {{ic|Fn+F1}} || {{Yes}} || {{Yes}} || {{ic|XF86Sleep}}<br />
|-<br />
| {{ic|Fn+F2}} || {{Yes}} || {{Yes}} || {{ic|XF86RFKill}}<br />
|-<br />
| {{ic|Fn+F3}} || {{Yes}} || {{Yes}} || {{ic|XF86MonBrightnessDown}}<br />
|-<br />
| {{ic|Fn+F4}} || {{Yes}} || {{Yes}} || {{ic|XF86MonBrightnessUp}}<br />
|-<br />
| {{ic|Fn+F5}} || {{No}} || {{Yes}} || Unknown<br />
|-<br />
| {{ic|Fn+F6}} || {{No}} || {{Yes}} || Turns off display<br />
|-<br />
| {{ic|Fn+F7}} || {{No}} || {{Yes}} || Disables touchpad<br />
|-<br />
| {{ic|Fn+F8}} || {{No}} || {{Yes}} || Toggles keyboard backlight<br />
|-<br />
| {{ic|Fn+F9}} || {{Yes}} || {{Yes}} || {{ic|XF86AudioMute}}<br />
|-<br />
| {{ic|Fn+F10}} || {{Yes}} || {{Yes}} || {{ic|XF86AudioLowerVolume}}<br />
|-<br />
| {{ic|Fn+F11}} || {{Yes}} || {{Yes}} || {{ic|XF86AudioRaiseVolume}}<br />
|-<br />
| {{ic|Fn+F12}} || {{No}} || {{Yes}} || Unknown<br />
|-<br />
| {{ic|Fn+Del}} || {{Yes}} || {{Yes}} || {{ic|Insert}}<br />
|-<br />
| {{ic|Fn+RightCtrl}} || {{Yes}} || {{Yes}} || {{ic|Menu}}<br />
|-<br />
| {{ic|Fn+Home}} || {{Yes}} || {{Yes}} || {{ic|Prior}}<br />
|-<br />
| {{ic|Fn+End}} || {{Yes}} || {{Yes}} || {{ic|Next}}<br />
|}<br />
<br />
# The key is visible to {{ic|xev}} and similar tools.<br />
# The physical key has a symbol on it, which describes its function.</div>Andre.laszlohttps://wiki.archlinux.org/index.php?title=Acer_Swift_3_SF314-511&diff=771141Acer Swift 3 SF314-5112023-03-04T23:02:51Z<p>Andre.laszlo: key status update</p>
<hr />
<div>[[Category:Acer]]<br />
{| class="wikitable" style="float: right;"<br />
|-<br />
! Hardware !! PCI/USB ID !! Working?<br />
|-<br />
| Touchpad || || {{Yes}}<br />
|-<br />
| Keyboard || || {{Yes}}<br />
|-<br />
| GPU || {{ic|8086:9a49}} || {{Yes}}<br />
|-<br />
| WiFi || {{ic|88086:a0f0}} || {{Yes}}<br />
|-<br />
| Webcam || {{ic|0408:a094}} || {{Yes}}<br />
|-<br />
| Bluetooth || {{ic|8087:0026}} || {{Yes}}<br />
|-<br />
| Audio || {{ic|8086:a0c8}} || {{Yes}}<br />
|-<br />
| Fingerprint reader || {{ic|04f3:0c7f}} || {{Experimental}}<br />
|}<br />
<br />
== Webcam ==<br />
<br />
This Acer Swift 3 model uses the same Quanta Computer "User Facing" camera as the Swift 1 which works out of the box.<br />
<br />
== Accessibility ==<br />
<br />
The firmware interface on the Acer Swift 3 is simple and keyboard-oriented, so it should be trivial to use with OCR devices.<br />
<br />
== Firmware ==<br />
<br />
{{Pkg|fwupd}} supports the touchpad, memory technology device, CPU, SSD, TPM, ESRT, and graphics card<br />
<br />
=== Secure Boot ===<br />
<br />
[[Secure Boot]] is enabled by default in the BIOS. In order to disable it, a BIOS administrator password must be set.<br />
<br />
== Function Keys ==<br />
<br />
{| class="wikitable"<br />
|-<br />
! Key !! Visible?<sup>1</sup> !! Marked?<sup>2</sup> !! Effect<br />
|-<br />
| {{ic|Fn+F1}} || {{Yes}} || {{Yes}} || {{ic|XF86Sleep}}<br />
|-<br />
| {{ic|Fn+F2}} || {{Yes}} || {{Yes}} || {{ic|XF86RFKill}}<br />
|-<br />
| {{ic|Fn+F3}} || {{Yes}} || {{Yes}} || {{ic|XF86MonBrightnessDown}}<br />
|-<br />
| {{ic|Fn+F4}} || {{Yes}} || {{Yes}} || {{ic|XF86MonBrightnessUp}}<br />
|-<br />
| {{ic|Fn+F5}} || {{No}} || {{Yes}} || Unknown<br />
|-<br />
| {{ic|Fn+F6}} || {{No}} || {{Yes}} || Turns off display<br />
|-<br />
| {{ic|Fn+F7}} || {{No}} || {{Yes}} || Disables touchpad<br />
|-<br />
| {{ic|Fn+F8}} || {{No}} || {{Yes}} || Toggles keyboard backlight<br />
|-<br />
| {{ic|Fn+F9}} || {{Yes}} || {{Yes}} || {{ic|XF86AudioMute}}<br />
|-<br />
| {{ic|Fn+F10}} || {{Yes}} || {{Yes}} || {{ic|XF86AudioLowerVolume}}<br />
|-<br />
| {{ic|Fn+F11}} || {{Yes}} || {{Yes}} || {{ic|XF86AudioRaiseVolume}}<br />
|-<br />
| {{ic|Fn+F12}} || {{No}} || {{Yes}} || Unknown<br />
|-<br />
| {{ic|Fn+Del}} || {{Yes}} || {{Yes}} || {{ic|Insert}}<br />
|-<br />
| {{ic|Fn+RightCtrl}} || {{Yes}} || {{Yes}} || {{ic|Menu}}<br />
|-<br />
| {{ic|Fn+Home}} || {{Yes}} || {{Yes}} || {{ic|Prior}}<br />
|-<br />
| {{ic|Fn+End}} || {{Yes}} || {{Yes}} || {{ic|Next}}<br />
|}<br />
<br />
# The key is visible to {{ic|xev}} and similar tools.<br />
# The physical key has a symbol on it, which describes its function.</div>Andre.laszlohttps://wiki.archlinux.org/index.php?title=Acer_Swift_3_SF314-511&diff=771140Acer Swift 3 SF314-5112023-03-04T23:02:00Z<p>Andre.laszlo: Created a page for this specific model, since it seems to differ quite a lot from the existing one.</p>
<hr />
<div>[[Category:Acer]]<br />
{| class="wikitable" style="float: right;"<br />
|-<br />
! Hardware !! PCI/USB ID !! Working?<br />
|-<br />
| Touchpad || || {{Yes}}<br />
|-<br />
| Keyboard || || {{Yes}}<br />
|-<br />
| GPU || {{ic|8086:9a49}} || {{Yes}}<br />
|-<br />
| WiFi || {{ic|88086:a0f0}} || {{Yes}}<br />
|-<br />
| Webcam || {{ic|0408:a094}} || {{Yes}}<br />
|-<br />
| Bluetooth || {{ic|8087:0026}} || {{Yes}}<br />
|-<br />
| Audio || {{ic|8086:a0c8}} || {{Yes}}<br />
|-<br />
| Fingerprint reader || {{ic|04f3:0c7f}} || {{Experimental}}<br />
|}<br />
<br />
== Webcam ==<br />
<br />
This Acer Swift 3 model uses the same Quanta Computer "User Facing" camera as the Swift 1 which works out of the box.<br />
<br />
== Accessibility ==<br />
<br />
The firmware interface on the Acer Swift 3 is simple and keyboard-oriented, so it should be trivial to use with OCR devices.<br />
<br />
== Firmware ==<br />
<br />
{{Pkg|fwupd}} supports the touchpad, memory technology device, CPU, SSD, TPM, ESRT, and graphics card<br />
<br />
=== Secure Boot ===<br />
<br />
[[Secure Boot]] is enabled by default in the BIOS. In order to disable it, a BIOS administrator password must be set.<br />
<br />
== Function Keys ==<br />
<br />
{| class="wikitable"<br />
|-<br />
! Key !! Visible?<sup>1</sup> !! Marked?<sup>2</sup> !! Effect<br />
|-<br />
| {{ic|Fn+F1}} || {{Yes}} || {{Yes}} || {{ic|XF86Sleep}}<br />
|-<br />
| {{ic|Fn+F2}} || {{Yes}} || {{Yes}} || {{ic|XF86RFKill}}<br />
|-<br />
| {{ic|Fn+F3}} || {{Yes}} || {{Yes}} || {{ic|XF86MonBrightnessDown}}<br />
|-<br />
| {{ic|Fn+F4}} || {{Yes}} || {{Yes}} || {{ic|XF86MonBrightnessUp}}<br />
|-<br />
| {{ic|Fn+F5}} || {{Yes}} || {{Yes}} || Unknown<br />
|-<br />
| {{ic|Fn+F6}} || {{Yes}} || {{Yes}} || Turns off display<br />
|-<br />
| {{ic|Fn+F7}} || {{Yes}} || {{Yes}} || Disables touchpad<br />
|-<br />
| {{ic|Fn+F8}} || {{No}} || {{Yes}} || Toggles keyboard backlight<br />
|-<br />
| {{ic|Fn+F9}} || {{Yes}} || {{Yes}} || {{ic|XF86AudioMute}}<br />
|-<br />
| {{ic|Fn+F10}} || {{Yes}} || {{Yes}} || {{ic|XF86AudioLowerVolume}}<br />
|-<br />
| {{ic|Fn+F11}} || {{Yes}} || {{Yes}} || {{ic|XF86AudioRaiseVolume}}<br />
|-<br />
| {{ic|Fn+F12}} || {{Yes}} || {{Yes}} || Unknown<br />
|-<br />
| {{ic|Fn+Del}} || {{Yes}} || {{Yes}} || {{ic|Insert}}<br />
|-<br />
| {{ic|Fn+RightCtrl}} || {{Yes}} || {{Yes}} || {{ic|Menu}}<br />
|-<br />
| {{ic|Fn+Home}} || {{Yes}} || {{Yes}} || {{ic|Prior}}<br />
|-<br />
| {{ic|Fn+End}} || {{Yes}} || {{Yes}} || {{ic|Next}}<br />
|}<br />
<br />
# The key is visible to {{ic|xev}} and similar tools.<br />
# The physical key has a symbol on it, which describes its function.</div>Andre.laszlohttps://wiki.archlinux.org/index.php?title=User:Andre.laszlo&diff=457360User:Andre.laszlo2016-11-21T11:42:52Z<p>Andre.laszlo: </p>
<hr />
<div>Developer, currently living in Göteborg, Sweden.<br />
<br />
I've been an Arch user since 2009.<br />
<br />
[http://www.laszlo.nu My blog]<br />
<br />
[[Special:contributions/Andre.laszlo|My Contributions]]</div>Andre.laszlohttps://wiki.archlinux.org/index.php?title=User:Andre.laszlo&diff=457359User:Andre.laszlo2016-11-21T11:42:45Z<p>Andre.laszlo: </p>
<hr />
<div>Developer, currently living in Göteborg, Sweden.<br />
<br />
I've been an Arch user since 2009.<br />
<br />
[http://www.laszlo.nu My blog]<br />
[[Special:contributions/Andre.laszlo|My Contributions]]</div>Andre.laszlohttps://wiki.archlinux.org/index.php?title=Docker&diff=457357Docker2016-11-21T11:39:26Z<p>Andre.laszlo: Update broken url</p>
<hr />
<div>[[Category:Virtualization]]<br />
[[ja:Docker]]<br />
[[ru:Docker]]<br />
[[zh-tw:Docker]]<br />
{{Related articles start}}<br />
{{Related|systemd-nspawn}}<br />
{{Related|Linux Containers}}<br />
{{Related|Lxc-systemd}}<br />
{{Related|Vagrant}}<br />
{{Related articles end}}<br />
[http://www.docker.io Docker] is a utility to pack, ship and run any application as a lightweight container.<br />
<br />
== Installation ==<br />
<br />
{{Note|<br />
*Docker doesn't support i686 [https://github.com/docker/docker/issues/136].<br />
*Docker needs the {{ic|loop}} module on first usage. The following steps may be required before starting docker:<br />
# tee /etc/modules-load.d/loop.conf <<< "loop"<br />
# modprobe loop <br />
You may need to reboot before the module is available.<br />
}}<br />
<br />
[[Install]] the {{Pkg|docker}} package or, for the development version, the {{Aur|docker-git}} package. Next [[start]] and enable {{ic|docker.service}} and verify operation:<br />
<br />
# docker info<br />
<br />
If you want to be able to run docker as a regular user, add yourself to the docker group:<br />
<br />
{{Warning| Anyone added to the 'docker' group is root equivalent. More information [https://github.com/docker/docker/issues/9976 here] and [http://docs.docker.com/engine/articles/security/ here].}}<br />
<br />
# gpasswd -a ''user'' docker<br />
<br />
Then re-login or to make your current user session aware of this new group, you can use:<br />
<br />
$ newgrp docker<br />
<br />
== Configuration ==<br />
<br />
=== Storage driver ===<br />
<br />
Storage driver, a.k.a. graph driver has huge impact on performance. It's job is to store layers of container images efficiently, that is when several images share a layer, only one layer uses disk space. The default, most compatible option, `devicemapper` offers suboptimal performance, which is outright terrible on rotating disks. Additionally, `devicemappper` is not recommended in production.<br />
<br />
As Arch linux ships new kernels, there's no point using the compatibility option. A good, modern choice is {{ic|overlay2}}.<br />
<br />
To see current storage driver, run {{ic|# docker info {{!}} head}}.<br />
<br />
To set your own choice of storage driver, create a [[Drop-in snippet]] and use {{ic|-s}} option to {{ic|dockerd}}:<br />
{{hc|/etc/systemd/system/docker.service.d/override.conf|2=<br />
[Service]<br />
ExecStart=<br />
ExecStart=/usr/bin/dockerd -H fd:// -s overlay2<br />
}}<br />
<br />
Recall that {{ic|1=ExecStart=}} line is needed to drop inherited {{ic|ExecStart}}.<br />
<br />
Further information on options is available on the [https://docs.docker.com/engine/userguide/storagedriver/selectadriver/ user guide].<br />
<br />
=== Opening remote API ===<br />
<br />
To open the Remote API to port {{ic|4243}} manually, run:<br />
<br />
# docker daemon -H tcp://0.0.0.0:4243 -H unix:///var/run/docker.sock<br />
<br />
{{ic|-H tcp://0.0.0.0:4243}} part is for opening the Remote API.<br />
<br />
{{ic|-H unix:///var/run/docker.sock}} part for host machine access via terminal.<br />
<br />
===== Remote API with systemd =====<br />
<br />
To start the remote API with the docker daemon, create a [[Drop-in snippet]] with the following content:<br />
<br />
{{hc|/etc/systemd/system/docker.service.d/override.conf|2=<br />
[Service]<br />
ExecStart=<br />
ExecStart=/usr/bin/dockerd -H tcp://0.0.0.0:4243 -H unix:///var/run/docker.sock<br />
}}<br />
<br />
=== Daemon socket configuration ===<br />
<br />
The ''docker'' daemon listens to a [[Wikipedia:Unix domain socket|Unix socket]] by default. To listen on a specified port instead, create a [[Drop-in snippet]] with the following content:<br />
<br />
{{hc|/etc/systemd/system/docker.service.d/socket.conf|2=<br />
[Socket]<br />
ListenStream=0.0.0.0:2375<br />
}}<br />
<br />
=== Proxies ===<br />
<br />
Proxy configuration is broken down into two. First is the host configuration of the Docker daemon, second is the configuration required for your container to see your proxy.<br />
<br />
==== Proxy configuration ====<br />
<br />
Create a [[Drop-in snippet]] with the following content:<br />
{{hc|/etc/systemd/system/docker.service.d/proxy.conf|2=<br />
[Service]<br />
Environment="HTTP_PROXY=192.168.1.1"<br />
}}<br />
<br />
{{Note|This assumes {{ic|192.168.1.1}} is your proxy server, do not use {{ic|127.0.0.1}}.}}<br />
<br />
Verify that the configuration has been loaded:<br />
<br />
# systemctl show docker --property Environment<br />
Environment=HTTP_PROXY=192.168.1.1<br />
<br />
==== Container configuration ====<br />
<br />
The settings in the {{ic|docker.service}} file will not translate into containers. To achieve this you must set {{ic|ENV}} variables in your {{ic|Dockerfile}} thus:<br />
<br />
FROM base/archlinux<br />
ENV http_proxy="<nowiki>http://192.168.1.1:3128</nowiki>"<br />
ENV https_proxy="<nowiki>https://192.168.1.1:3128</nowiki>"<br />
<br />
[https://docs.docker.com/reference/builder/#env Docker] provide detailed information on configuration via {{ic|ENV}} within a Dockerfile.<br />
<br />
=== Configuring DNS ===<br />
<br />
By default, docker will make {{ic|resolv.conf}} in the container match {{ic|/etc/resolv.conf}} on the host machine, filtering out local addresses (e.g. {{ic|127.0.0.1}}). If this yields an empty file, then [https://developers.google.com/speed/public-dns/ Google DNS servers] are used. If you are using a service like [[dnsmasq]] to provide name resolution, you may need to add an entry to the {{ic|/etc/resolv.conf}} for docker's network interface so that it isn't filtered out.<br />
<br />
=== Images location ===<br />
<br />
By default, docker images are located at {{ic|/var/lib/docker}}. They can be moved to other partitions. <br />
First, [[stop]] the {{ic|docker.service}}. <br />
<br />
If you have run the docker images, you need to make sure the images are unmounted totally. Once that is completed, you may move the images from {{ic|/var/lib/docker}} to the target destination.<br />
<br />
Then add a [[Drop-in snippet]] for the {{ic|docker.service}}, adding the {{ic|-g}} parameter to the {{ic|ExecStart}}:<br />
<br />
{{hc|/etc/systemd/system/docker.service.d/imagelocation.conf|2=<br />
[Service]<br />
ExecStart= <br />
ExecStart=/usr/bin/dockerd -g ''/path/to/new/location/docker'' -H fd://}}<br />
<br />
== Docker 0.9.0 -- 1.2.x and LXC ==<br />
<br />
Since version 0.9.0 Docker provides a new way to start containers without relying on a LXC library called ''libcontainer''.<br />
<br />
The lxc exec driver and the -lxc-conf option may also be removed in the near future [https://github.com/docker/docker/pull/5797], hence, you will not be able to use {{ic|lxc-attach}} with containers managed by Docker 0.9.0+ by default. It is required to make docker daemon run with {{ic|-e lxc}} as an argument.<br />
<br />
Create [[Drop-in snippet]] for the {{ic|docker.service}} with the following content:<br />
{{hc|/etc/systemd/system/docker.service.d/lxc.conf|2=<br />
[Service]<br />
ExecStart=<br />
ExecStart=/usr/bin/docker -d -e lxc<br />
}}<br />
<br />
== Images ==<br />
=== Arch Linux ===<br />
==== x86_64 ====<br />
The following command pulls the [https://hub.docker.com/r/base/archlinux/ base/archlinux] x86_64 image.<br />
<br />
# docker pull base/archlinux<br />
<br />
==== i686 ====<br />
The default Arch Linux image in Docker Registry is for x86_64 only. i686 image must be built manually.<br />
<br />
==== Build Image ====<br />
Instead, check [https://registry.hub.docker.com/u/base/archlinux/ docker base/archlinux registry] and click the {{ic|mkimage-arch.sh}} link to download {{ic|mkimage-arch.sh}} and {{ic|mkimage-arch-pacman.conf}} to the same directory as raw files. Next, make the script executable and run it: <br />
<br />
$ chmod +x mkimage-arch.sh<br />
$ cp /etc/pacman.conf ./mkimage-arch-pacman.conf # or get a pacman.conf from somewhere else<br />
$ ./mkimage-arch.sh<br />
# docker run -t -i --rm archlinux /bin/bash # try it<br />
<br />
For slow network connections or CPU, the build timeout can be extended: <br />
$ sed -i 's/timeout 60/timeout 120/' mkimage-arch.sh<br />
<br />
=== Debian ===<br />
<br />
Build Debian image with {{Pkg|debootstrap}}:<br />
<br />
# mkdir jessie-chroot<br />
# debootstrap jessie ./jessie-chroot http://http.debian.net/debian/<br />
# cd jessie-chroot<br />
# tar cpf - . | docker import - debian<br />
# docker run -t -i --rm debian /bin/bash<br />
<br />
== Arch Linux image with snapshot repository ==<br />
Arch Linux on Docker can become problematic when multiple images are created and updated each having different package versions. To keep Docker containers with consistent package versions, a [https://registry.hub.docker.com/u/pritunl/archlinux/ Docker image with a snapshot repository] is available. This allows installing new packages from the official repository as it was on the day that the snapshot was created.<br />
<br />
$ docker pull pritunl/archlinux:latest<br />
$ docker run --rm -t -i pritunl/archlinux:latest /bin/bash<br />
<br />
Alternatively, you could use [[Arch Linux Archive]] by freezing {{ic|/etc/pacman.d/mirrorlist}} <br />
Server=https://archive.archlinux.org/repos/2020/01/02/$repo/os/$arch<br />
<br />
== Clean Remove Docker + Images ==<br />
<br />
In case you want to remove Docker entirely you can do this by following the steps below:<br />
<br />
{{Note| Don't just copy paste those commands without making sure you know what you are doing!}}<br />
<br />
Check for running containers:<br />
<br />
# docker ps<br />
<br />
List all containers running on the host for deletion:<br />
<br />
# docker ps -a<br />
<br />
Stop a running container:<br />
<br />
# docker stop <CONTAINER ID><br />
<br />
Killing still running containers:<br />
<br />
# docker kill <CONTAINER ID><br />
<br />
Delete all containers listed by ID:<br />
<br />
# docker rm <CONTAINER ID><br />
<br />
List all Docker images:<br />
<br />
# docker images<br />
<br />
Delete all images by ID:<br />
<br />
# docker rmi <IMAGE ID><br />
<br />
Delete all Docker data (purge directory):<br />
<br />
# rm -R /var/lib/docker<br />
<br />
== Useful tips ==<br />
<br />
To grab the IP address of a running container:<br />
<br />
{{hc|<nowiki>$ docker inspect --format '{{ .NetworkSettings.IPAddress }}' <container-name OR id> </nowiki>|<br />
172.17.0.37}}<br />
<br />
== Troubleshooting ==<br />
=== Cannot start a container with systemd 232 ===<br />
Append {{ic|1=systemd.legacy_systemd_cgroup_controller=yes}} as [[kernel parameter]], see [https://github.com/opencontainers/runc/issues/1175 bug report] for details.<br />
<br />
=== Docker info errors out ===<br />
<br />
If running {{ic|docker info}} gives an error that looks like this:<br />
<br />
FATA[0000] Get http:///var/run/docker.sock/v1.17/info: read unix /var/run/docker.sock: connection reset by peer. Are you trying to connect to a TLS-enabled daemon without TLS? <br />
<br />
then you might not have the {{ic|bridge}} module loaded. You can check for it by running {{ic|lsmod | grep bridge}}. If it is not loaded, you can try to load it with {{ic|modprobe}} or simply reboot (a reboot might be required if you have upgraded your kernel recently without rebooting and the bridge module was built for the more recent kernel.)<br />
<br />
See [https://github.com/docker/docker/issues/6853 this issue on GitHub for more information].<br />
<br />
=== Deleting Docker Images in a BTRFS Filesystem ===<br />
Deleting docker images in a [[btrfs]] filesystem leaves the images in {{ic|/var/lib/docker/btrfs/subvolumes/}} with a size of 0. When you try to delete this you get a permission error.<br />
# docker rm bab4ff309870<br />
# rm -Rf /var/lib/docker/btrfs/subvolumes/*<br />
rm: cannot remove '/var/lib/docker/btrfs/subvolumes/85122f1472a76b7519ed0095637d8501f1d456787be1a87f2e9e02792c4200ab': Operation not permitted<br />
<br />
This is caused by btrfs which created subvolumes for the docker images. So the correct command to delete them is:<br />
# btrfs subvolume delete /var/lib/docker/btrfs/subvolumes/85122f1472a76b7519ed0095637d8501f1d456787be1a87f2e9e02792c4200ab<br />
<br />
=== docker0 Bridge gets no IP / no internet access in containers ===<br />
<br />
Docker enables IP forwarding by itself, but by default systemd overrides the respective sysctl setting. The following disables this override (for all interfaces):<br />
<br />
# cat > /etc/systemd/network/ipforward.network <<EOF<br />
[Network]<br />
IPForward=ipv4<br />
EOF<br />
<br />
# cat > /etc/sysctl.d/99-docker.conf <<EOF<br />
net.ipv4.ip_forward = 1<br />
EOF<br />
<br />
# sysctl -w net.ipv4.ip_forward=1<br />
<br />
Finally [[restart]] the {{ic|systemd-networkd}} and {{ic|docker}} services.<br />
<br />
=== Default number of allowed processes/threads too low ===<br />
<br />
If you run into error messages like<br />
<br />
# e.g. Java<br />
java.lang.OutOfMemoryError: unable to create new native thread<br />
# e.g. C, bash, ...<br />
fork failed: Resource temporarily unavailable<br />
<br />
then you might need to adjust the number of processes allowed by systemd. Default (see system.conf) is 500, which is pretty small for running several docker containers. You need to create a drop-in service file for this:<br />
<br />
# mkdir /etc/systemd/system/docker.service.d<br />
# cat > /etc/systemd/system/docker.service.d/tasks.conf <<EOF<br />
[Service]<br />
TasksMax=infinity<br />
EOF<br />
# systemctl daemon-reload<br />
# systemctl restart docker.service<br />
<br />
== See also ==<br />
<br />
* [https://docs.docker.com/engine/installation/linux/archlinux/ Arch Linux on docs.docker.com]<br />
* [http://opensource.com/business/14/7/docker-security-selinux Are Docker containers really secure?] — opensource.com</div>Andre.laszlohttps://wiki.archlinux.org/index.php?title=RVM&diff=442261RVM2016-07-20T13:44:14Z<p>Andre.laszlo: Fix broken link for ruby 1.8 issues</p>
<hr />
<div>[[Category:Development]]<br />
[[de:RVM]]<br />
[[ja:RVM]]<br />
{{Related articles start}}<br />
{{Related|Rbenv}}<br />
{{Related|Chruby}}<br />
{{Related|Ruby}}<br />
{{Related articles end}}<br />
[http://rvm.io/ RVM] (Ruby Version Manager) is a command line tool which allows us to easily install, manage and work with multiple [[Ruby]] environments from interpreters to sets of gems.<br />
<br />
There exists a similar application that you may also want to consider: [[rbenv]].<br />
<br />
== Installing RVM ==<br />
<br />
The install process is very easy, and is the same for any distro, including Arch Linux. You have two choices, one system-wide, another as a user. The first is for production servers, or if you are alone on your machine, you'll need root privileges. The second is recommended for multiple users on the same machine (like a development test box). If you do not know which to choose then start with a single user installation.<br />
<br />
The upstream instructions for installing RVM should just work. The install script is aware enough to tell you what packages you need to install on Arch Linux to make different rubies work. This usually involves gcc and some other stuff needed to compile ruby.<br />
<br />
As an observation, '''installing RVM with gem is not recommended anymore'''. This article uses the [http://rvm.io/rvm/install/ recommended documentation] with minor tweaks to make it work on Arch Linux.<br />
<br />
=== Pre-requisites ===<br />
<br />
Before starting, you will need to [[install]] the {{pkg|git}} and {{pkg|curl}} packages.<br />
<br />
=== Single-user installation ===<br />
<br />
{{Note|This will install to your home directory only (~/.rvm), and won't touch the standard Arch ruby package, which is in /usr.}}<br />
<br />
For most purposes, the recommended installation method is single-user, which is a self-contained RVM installation in a user's home directory.<br />
<br />
Use the script that rvm docs recommends to install. Make sure to run this script as the user for whom you want RVM installed (i.e. your normal user that you use for development).<br />
<br />
To check the script before running it, do:<br />
<br />
$ curl -L get.rvm.io > rvm-install<br />
<br />
Inspect the file, and then run it with:<br />
<br />
$ bash < ./rvm-install<br />
<br />
After the script has finished, then add the following line to the end of your ~/.bash_login or ~/.bashrc (or ~/.zprofile or whatever):<br />
<br />
$ <nowiki>[[ -s "$HOME/.rvm/scripts/rvm" ]]</nowiki> && source "$HOME/.rvm/scripts/rvm"<br />
<br />
Now, close out your current shell or terminal session and open a new one. (You may attempt reloading your ~/.bash_login with the following command:<br />
<br />
$ source ~/.bash_login<br />
<br />
However, closing out your current shell or terminal and opening a new one is the preferred way for initial installations.)<br />
<br />
=== Multi-user installation ===<br />
<br />
{{Note|This will install to /usr/local/rvm, and won't touch the standard Arch ruby package, which is in /usr. }}<br />
<br />
System-wide installation is a similar procedure to the single user install. However, instead run the install script with sudo. '''Do not run the installer directly as root!'''<br />
<br />
$ sudo bash -s stable<br />
<br />
(to install a specific version replace ''stable'' with, for example, ''-- --version 1.13.0'')<br />
<br />
After the script has finished, add yourself and your users to the 'rvm' group. (The installer does not auto-add any users to the rvm group. Admins must do this.) For each one, repeat:<br />
<br />
# usermod -a -G rvm <user><br />
<br />
'''Group memberships are only evaluated at login time'''. Log the users out, then back in. You too: close out your current shell or terminal session and open a new one. (You may attempt reloading your ~/.bash_login with the following command:<br />
<br />
$ source ~/.bash_login<br />
<br />
However, closing out your current shell or terminal and opening a new one is the preferred way for initial installations. Alternatively, you can use the "newgrp rvm" command and check with "id" to see whether the shell has picked up the new group membership of your user)<br />
<br />
{{Note|Remember to change the line [ [ -s $HOME/.rvm/scripts/rvm ] ] && source $HOME/.rvm/scripts/rvm to the system-wide location changing $HOME to /usr/local/}}<br />
<br />
RVM will be automatically configured for every user on the system (in opposite to the single-user installation); this is accomplished by loading /etc/profile.d/rvm.sh on login. Arch Linux defaults to parsing /etc/profile which contains the logic to load all files residing in the /etc/profile.d/ directory.<br />
<br />
Before installing gems with multi-user rvm, make sure that /etc/gemrc does not have the line "gem: --user-install". If it does you need to comment it out otherwise the gems will install to the wrong place.<br />
<br />
'''You only use the sudo command during the install process'''. In multi-user configurations, any operations which require sudo access must use the ''rvmsudo'' command which preserves the RVM environment and passes this on to sudo. There are very few cases where rvmsudo is required once the core install is completed, except for when updating RVM itself. There is never a reason to use sudo post-install. rvmsudo should only be needed for updating with<br />
<br />
$ rvmsudo rvm get head<br />
<br />
===== A cautionary action =====<br />
<br />
In order to prevent the installation breakage by this cause, you may add this configuration to your /etc/sudoers file with command: {{ic|#su -c visudo}}<br />
<br />
{{bc|1=<br />
## Cmnd alias specification<br />
Cmnd_Alias RVM = /usr/local/rvm/rubies/<ruby_interpreter>/bin/gem, \<br />
/usr/local/rvm/rubies/<another_ruby_interpreter>/bin/gem, \<br />
/usr/local/rvm/bin/rvm<br />
<br />
## User privilege specification<br />
root ALL=(ALL) ALL<br />
<br />
## Uncomment to allow members of group wheel to execute any command<br />
%wheel ALL=(ALL) ALL, !RVM<br />
}}<br />
<br />
Where ''<ruby_interpreter>'' would be —for example— ruby-1.9.2-p290.<br />
<br />
== Post Installation ==<br />
<br />
After the installation, check everything worked with this command:<br />
<br />
$ type rvm | head -n1<br />
<br />
The response should be:<br />
<br />
$ rvm is a function<br />
<br />
If you receive rvm: not found, you may need to source your ~/.bash_login (or wherever you put the line above):<br />
<br />
$ . ~/.bash_login<br />
<br />
Check if the rvm function is working:<br />
<br />
$ rvm notes<br />
<br />
Finally, see if there are any dependency requirements for your installation by running:<br />
<br />
$ rvm requirements<br />
<br />
(Follow the returned instructions if any.)<br />
<br />
'''Very important''': whenever you upgrade RVM in the future, you should always run ''rvm notes'' and ''rvm requirements'' as this is usually where you will find details on any major changes and/or additional requirements '''to ensure your installation stays working'''.<br />
<br />
=== Some extras ===<br />
<br />
You may put in your ~/.bashrc the following lines to get some useful features:<br />
{{bc|1=<br />
# Display the current RVM ruby selection<br />
PS1="\$(/usr/local/rvm/bin/rvm-prompt) $PS1"<br />
<br />
# RVM bash completion<br />
<nowiki>[[ -r /usr/local/rvm/scripts/completion ]]</nowiki> && . /usr/local/rvm/scripts/completion<br />
}}<br />
<br />
Or if you're running as a single user:<br />
{{bc|1=<br />
# RVM bash completion<br />
<nowiki>[[ -r "$HOME/.rvm/scripts/completion" ]]</nowiki> && source "$HOME/.rvm/scripts/completion"<br />
}}<br />
<br />
== Using RVM ==<br />
<br />
The RVM documentation is ''quite'' comprehensive and explanatory. However, here are some RVM usage examples to get you started.<br />
<br />
=== Rubies ===<br />
<br />
==== Installing environments ====<br />
<br />
To see what Ruby environments are available to install, run:<br />
<br />
$ rvm list known<br />
<br />
To install one, run:<br />
<br />
$ rvm install <ruby_version><br />
<br />
For example, to install Ruby 1.9.2 one would run the following command:<br />
<br />
$ rvm install 1.9.2<br />
<br />
This should download, configure and install Ruby 1.9.2 in the place you installed RVM. For example, if you did a single user install, it will be in ~/.rvm/rubies/1.9.2.<br />
<br />
You can define a default ruby interpreter by doing:<br />
<br />
$ rvm use <ruby_version> --default<br />
<br />
If not, the default environment will be the system ruby in /usr —if you have installed one using pacman— or none.<br />
<br />
==== Switching environments ====<br />
<br />
To switch from one environment to another simply run:<br />
<br />
$ rvm use <ruby_version><br />
<br />
For example to switch to Ruby 1.8.7 one would run the following command:<br />
<br />
$ rvm 1.8.7<br />
<br />
(As you see, the flag ''use'' is not really necessary.)<br />
<br />
You should get a message telling you the switch worked. It can be confirmed by running:<br />
<br />
$ ruby --version<br />
<br />
Note that this environment will only be used in the current shell. You can open another shell and select a different environment for that one in parallel.<br />
<br />
In case you have set a default interpreter as explained above, you can do the switch with:<br />
<br />
$ rvm default<br />
<br />
==== System ruby ====<br />
<br />
If you wish the ruby interpreter that is outside RVM (i.e. the one installed in /usr by the standard Arch Linux package), you can switch to it using:<br />
<br />
$ rvm system<br />
<br />
==== Listing environments ====<br />
<br />
To see all installed Ruby environments, run the following command:<br />
<br />
$ rvm list<br />
<br />
If you've installed a few rubies, this might generate a list like so:<br />
<br />
rvm Rubies<br />
jruby-1.5.0 [ [i386-java] ]<br />
=> ruby-1.8.7-p249 [ i386 ]<br />
ruby-1.9.2-head [ i386 ]<br />
System Ruby<br />
system [ i386 ]<br />
<br />
The ASCII arrow indicates which environment is currently enabled. In this case, it is Ruby 1.8.7. This could be confirmed by running:<br />
<br />
$ ruby --version<br />
ruby 1.8.7 (2010-01-10 patchlevel 249) [i686-linux]<br />
<br />
=== Gemsets ===<br />
<br />
RVM has a valued feature called gemsets which enables you to store different sets of gems in compartmentalized independent ruby setups. This means that ruby, gems and irb are all separate and self-contained from the system and each other.<br />
<br />
==== Creating ====<br />
<br />
Gemsets must be created before being used. To create a new gemset for the current ruby, do this:<br />
<br />
$ rvm use <ruby_version><br />
$ rvm gemset create <gemset_name><br />
<br />
Alternatively, if you prefer the shorthand syntax offered by rvm use, employ the --create option like so:<br />
<br />
$ rvm use <ruby_version>@<gemset_name> --create<br />
<br />
You can also specify a default gemset for a given ruby interpreter, by doing:<br />
<br />
$ rvm use <ruby_version>@<gemset_name> --default<br />
<br />
==== Using ====<br />
<br />
Tip: remove gems that reside in system prior to the RVM installation with:<br />
$ gem list --local | awk '{print "gem uninstall " $1}' | bash<br />
<br />
and check what's left:<br />
<br />
$ gem list --local<br />
<br />
To use a gemset:<br />
<br />
$ rvm gemset use <gemset_name><br />
<br />
You can switch to a gemset as you start to use a ruby, by appending @<gemset_name> to the end of the ruby selector string:<br />
<br />
$ rvm use <ruby_version>@<gemset_name><br />
<br />
===== Notes =====<br />
<br />
When you install a ruby environment, it comes with two gemsets out of the box, their names are ''default'' and ''global''. You will usually find in the latter some pre-installed common gems, while the former always starts empty. <br />
<br />
A little bit about where the default and global gemsets differ: When you do not use a gemset at all, you get the gems in the default set. If you use a specific gemset (say @testing), it will inherit gems from that ruby's @global. The global gemset is to allow you to share gems to all your gemsets.<br />
<br />
==== Gems! ====<br />
<br />
Within a gemset, you can utilize usual RubyGems commands<br />
$ gem install <gem><br />
to add,<br />
$ gem uninstall <gem><br />
to remove gems, and<br />
$ gem list<br />
to view installed ones.<br />
<br />
If you are deploying to a server, or you do not want to wait around for rdoc and ri to install for each gem, you can disable them for gem installs and updates. Just add these two lines to your ~/.gemrc or /etc/gemrc:<br />
<br />
install: --no-document<br />
update: --no-document<br />
<br />
==== Listing ====<br />
<br />
To see the name of the current gemset:<br />
<br />
$ rvm gemset name<br />
<br />
To list all named gemsets for the current ruby interpreter:<br />
<br />
$ rvm gemset list<br />
<br />
To list all named gemsets for all interpreters:<br />
<br />
$ rvm gemset list_all<br />
<br />
==== Deleting ====<br />
<br />
This action removes the current gemset:<br />
<br />
$ rvm gemset use <gemset_name><br />
$ rvm gemset delete <gemset_name><br />
<br />
By default, rvm deletes gemsets from the currently selected Ruby interpreter. To delete a gemset from a different interpreter, say 1.9.2, run your command this way:<br />
<br />
$ rvm 1.9.2 do gemset delete <gemset_name><br />
<br />
==== Emptying ====<br />
<br />
This action removes all gems installed in the gemset:<br />
<br />
$ rvm gemset use <gemset_name><br />
$ rvm gemset empty <gemset_name><br />
<br />
=== RVM ===<br />
<br />
==== Updating ====<br />
<br />
To upgrade to the most recent release version:<br />
<br />
$ rvm get latest<br />
<br />
Upgrading to the latest repository source version (the most bugfixes):<br />
<br />
$ rvm get head<br />
<br />
Remember to use rvmsudo for multi-user setups. Update often!<br />
<br />
==== Uninstalling ====<br />
<br />
Executing<br />
<br />
$ rvm implode<br />
<br />
is going to wipe out the RVM installation —cleanly—.<br />
<br />
=== Further Reading ===<br />
<br />
This is just a simple introduction to switching ruby versions with RVM and managing different set of gems in different environments. There is lots more that you can do with it! For more information, consult the very comprehensive RVM documentation. [https://rvm.beginrescueend.com/rvm/basics/ This page] is a good place to start.<br />
<br />
== Troubleshooting ==<br />
<br />
Unfortunately, some ruby patchlevels just do not play nicely with Arch Linux, and many times RVM does not choose the latest patchlevel version to install. So, you'll need to manually check on the [http://www.ruby-lang.org/en/news/ ruby website], and force RVM to install it.<br />
<br />
==== "data definition has no type or storage class" ====<br />
<br />
This appears to be specific to 1.8.7, but if you get this error while compiling the following steps will fix your problem:<br />
<br />
$ cd src/ruby-1.8.7-p334/ext/dl<br />
$ rm callback.func<br />
$ touch callback.func<br />
$ ruby mkcallback.rb >> callback.func<br />
$ rm cbtable.func<br />
$ touch cbtable.func<br />
$ ruby mkcbtable.rb >> cbtable.func<br />
<br />
Naturally, substitute the actual build path to your source, which will be something like ~/.rvm/src/.<br />
<br />
==== Ruby 1.8.x won't compile with RVM ====<br />
<br />
This is a known issue on Arch Linux, and is caused by a problem with openssl. Arch uses openssl 1.0, lower patchlevels of 1.8.7 assumes 0.9. <br />
<br />
Certain patch levels may not build (p352 for example), p299 should work fine and can be installed using the following command:<br />
<br />
$ rvm remove 1.8.7<br />
$ rvm install 1.8.7-p299<br />
<br />
Another approach is to install local openssl via RVM:<br />
<br />
$ rvm pkg install openssl<br />
$ rvm remove 1.8.7<br />
$ rvm install 1.8.7 -C --with-openssl-dir=$HOME/.rvm/usr<br />
<br />
It may be necessary to patch 1.8.7:<br />
<br />
$ wget https://gist.githubusercontent.com/waseem/0e8607e443bcd0b3e60cfad56cd9999b/raw/2083ae1cc7643174bb291fce8c25b1b643d91af7/ssl.patch<br />
$ rvm remove 1.8.7<br />
$ rvm install --patch ./ssl.patch ruby-1.8.7-p352<br />
<br />
==== Ruby 1.9.1 won't compile with RVM ====<br />
<br />
Like with 1.8.x, earlier patchlevels do not like the OpenSSL 1.0. Then you can use the very same solution above, by installing openssl locally on RVM.<br />
<br />
$ rvm pkg install openssl<br />
$ rvm remove 1.9.1<br />
$ rvm install 1.9.1 -C --with-openssl-dir=$HOME/.rvm/usr<br />
<br />
The patchlevels >p378 have a problem with gem paths, when $GEM_HOME is set. The problem is known and fixed in 1.9.2. (http://redmine.ruby-lang.org/issues/3584). If you really need 1.9.1 please use p378.<br />
<br />
$ rvm install 1.9.1-p378 -C --with-openssl-dir=$HOME/.rvm/usr<br />
<br />
==== Ruby 2.2.2 won't compile with RVM ====<br />
<br />
Like with 1.8.x and 1.9.1, earlier patchlevels do not like the OpenSSL 1.0. Then you can use the very same solution above, by installing openssl locally on RVM.<br />
<br />
$ rvm pkg install openssl<br />
$ rvm remove 2.2.2<br />
$ rvm install 2.2.2 -C --with-openssl-dir=$HOME/.rvm/usr<br />
<br />
== See Also ==<br />
<br />
* [http://rvm.io/ RVM project website].<br />
* [[RubyOnRails#Option_C:_The_Perfect_Rails_Setup|The Perfect Rails Setup]].</div>Andre.laszlohttps://wiki.archlinux.org/index.php?title=MongoDB&diff=257757MongoDB2013-05-19T10:29:37Z<p>Andre.laszlo: Added link to bson spec</p>
<hr />
<div>[[Category:Database management systems]]<br />
MongoDB (from hu'''mongo'''us) is an open source document-oriented database system developed and supported by [http://www.10gen.com/ 10gen]. It is part of the NoSQL family of database systems. Instead of storing data in tables as is done in a "classical" relational database, MongoDB stores structured data as JSON-like documents with dynamic schemas (MongoDB calls the format [http://bsonspec.org/ BSON]), making the integration of data in certain types of applications easier and faster.<br />
<br />
==Installing MongoDB==<br />
Install {{Pkg|mongodb}}<br />
# pacman -S mongodb<br />
Start MongoDB<br />
# systemctl start mongodb<br />
(Optional) Add MongoDB to the list of daemons that start on system startup<br />
# systemctl enable mongodb<br />
<br />
==Access the database shell==<br />
To access the Database shell you have type in your terminal<br />
# mongo<br />
<br />
==Troubleshooting==<br />
===MongoDB won't start===<br />
Check if the lock file exists<br />
# ls -lisa /var/lib/mongodb<br />
<br />
If it does, stop the mongodb service, and delete the file. Then start the service again.<br />
# rm /var/lib/mongodb/mongod.lock<br />
<br />
If it still won't start, run a repair on the database, specifying the dbpath (/var/lib/mongodb/ is the default --dbpath in Arch Linux)<br />
# mongod --dbpath /var/lib/mongodb/ --repair<br />
<br />
After running the repair as root, the files got chowned to root, whilst Arch Linux runs it under a different user. You then need to chown<br />
back the files. [http://earlz.net/view/2011/03/11/0015/mongodb-and-arch-linux Further reference]<br />
<br />
# cd /var/log/mongod<br />
# sudo chown -R mongodb:mongodb .<br />
# cd /var/lib/mongodb<br />
# sudo chown -R mongodb:mongodb .</div>Andre.laszlohttps://wiki.archlinux.org/index.php?title=User:Andre.laszlo&diff=127297User:Andre.laszlo2011-01-08T17:45:03Z<p>Andre.laszlo: Created page with "Computer science and engineering student at Chalmers university, Göteborg, Sweden. I've been an Arch user since 2009. [http://www.laszlo.nu My blog] (mostly in swedish)"</p>
<hr />
<div>Computer science and engineering student at Chalmers university, Göteborg, Sweden.<br />
<br />
I've been an Arch user since 2009.<br />
<br />
[http://www.laszlo.nu My blog] (mostly in swedish)</div>Andre.laszlohttps://wiki.archlinux.org/index.php?title=/dev/shm&diff=127296/dev/shm2011-01-08T17:41:35Z<p>Andre.laszlo: Added information about the % suffix of the size parameter.</p>
<hr />
<div>[[Category: Kernel (English)]]<br />
[[Category: File systems (English)]]<br />
The following introduction was taken from [http://www.cyberciti.biz/tips/what-is-devshm-and-its-practical-usage.html nixCraft's article on /dev/shm]:<br />
<br />
:"''<b>/dev/shm</b> is nothing but implementation of traditional shared memory concept. It is an efficient means of passing data between programs. One program will create a memory portion, which other processes (if permitted) can access. This will result into speeding up things on Linux. shm / shmfs is also known as tmpfs, which is a common name for a temporary file storage facility on many Unix-like operating systems. It is intended to appear as a mounted file system, but one which uses virtual memory instead of a persistent storage device. If you type mount command you will see /dev/shm as a tempfs file system. Therefore, it is a file system, which keeps all files in virtual memory. Everything in tmpfs is temporary in the sense that no files will be created on your hard drive. If you unmount a tmpfs instance, everything stored therein is lost. By default almost all Linux distros configured to use /dev/shm.''"<br />
<br />
==Settings==<br />
Alter {{filename|/etc/fstab}}'s entry for {{filename|/dev/shm}} and apply settings with {{codeline|mount -a}}, or reboot:<br />
none /dev/shm tmpfs defaults,size=768M,noexec,nodev,nosuid 0 0<br />
<br />
;size: Accepts 'k', 'm' or 'g' and their capitalized versions as units. The size parameter also accepts a suffix % to limit this tmpfs instance to that percentage of your physical RAM. The default is 50%.<br />
;noexec,nodev,nosuid: Universal options for most file-systems affecting permissions. See: {{codeline|man mount}}<br />
<br />
==Usage==<br />
Generally speaking, IO intensive tasks that benefit from fast, No-HDD-read/write-space, such as video encoding, gaming, etc. can make extensive use out of {{filename|shm}}. However, that's not to say that simpler applications can't recieve substantial gains from offloading data onto shared memory. [[Firefox]], for example, shows that having its [[Speed-up Firefox using tmpfs|profile relocated into ram]] makes a big difference.<br />
<br />
===Improving compile times===<br />
==== Script-based Method ====<br />
This is a small script that links [[makepkg]]'s build space to a sub-directory in {{filename|shm}}. Be sure to run it where the [[PKGBUILD]] is located. Also keep in mind that when it detects that a package is ''already'' cached in RAM, the script purges the package's cached build directory.<br />
{{file|name=makepkg-shm|content=<br />
#!/bin/bash<br />
BUILDSCRIPT=PKGBUILD<br />
srcdir=src<br />
<nowiki><br />
. $BUILDSCRIPT || (echo "Error: Failed to source \`$BUILDSCRIPT'"; exit 1)<br />
volatile=/dev/shm/$USER/makepkg/$pkgname<br />
<br />
if [[ -f $srcdir/.tmpfs ]]; then<br />
rm -rf $volatile $srcdir<br />
echo "Success: Purged \`$srcdir' and \`$volatile'"<br />
elif [[ -e $srcdir && `readlink $srcdir` != $volatile ]]; then<br />
echo "Error: \`$srcdir' exists and is not a link to \`$volatile', aborting"; exit 2<br />
else<br />
install -dm700 $volatile<br />
ln -s $volatile $srcdir<br />
touch $srcdir/.tmpfs<br />
echo "Success: \`$srcdir' linked to \`$volatile'"<br />
fi<br />
</nowiki><br />
}}<br />
<br />
Save it as {{filename|~/bin/makepkg-shm}}, for example, and make it executable:<br />
$ chmod +x ~/bin/makepkg-shm<br />
<br />
Or get it from the [http://aur.archlinux.org/packages.php?ID=41579 AUR].<br />
<br />
==== .bashrc-based Method ====<br />
<br />
Another method is to simply add a few lines to {{Filename|~/.bashrc}} which simply copies the directory containing the PKGBUILD, files to /dev/shm which can be accomplished by appending the following to said file:<br />
<br />
bi () {<br />
cp -a $1 /dev/shm<br />
cd /dev/shm/$1<br />
here=`pwd`<br />
echo you are here $here<br />
}<br />
<br />
$1 is the first arg which is the dir name you wish to copy. Example:<br />
<br />
bi /path/to/pkgbuild_files/firefox-pgo<br />
you are here /dev/shm/firefox-pgo</div>Andre.laszlo