Ahoj,
(English below)
TL;DR ve VPS lze nově používat distribuci Guix.
GNU Guix System [1] je linuxová distribuce založená na správci balíčků Guix. Funguje to velice podobně jako NixOS [2] a Nix, až na to, že Guix a celý systém se konfiguruje pomocí Guile Scheme. Ve Scheme jsou opravdu veškeré součásti systému, včetně init systému Shepherd [3].
Na rozdíl od klasických distribucí se Guix a NixOS konfigurují deklarativně: v konfiguračním souboru nadefinujeme kompletní podobu výsledného systému, tj. jaké má obsahovat uživatele/skupiny, služby a jejich nastavení. Ať už se jedná o aktualizaci nebo rollback, mezi různými verzemi systému se lze snadno přepínat buď za běhu, nebo při bootu v zavaděči, resp. u nás ve Start Menu [4]. Guix oproti NixOS obsahuje jen Free Software.
Protože ve vpsFree používáme NixOS [5] skoro na všechno, zajímalo mě taky, jak je na tom Guix. Bohužel Scheme pořádně neznám a ani mě to moc neláká -- je tam příliš mnoho závorek :) Před rokem se jeden člen snažil [6] šablonu pro Guix vytvořit, ale sám jsem neviděl cestu, jak na to. Až před pár dny jsem narazil na blog [7], který obsahoval potřebné informace. Hlavní problém byl, že ve VPS nemáme zavaděč a taky se nepřipojuje kořenový souborový systém -- je připojen už před spuštěním /sbin/init ve VPS. V konfiguraci však zavaděč i kořenový systém být musí, jinak se systém nesestaví.
Nakonec to není žádná věda: jako zařízení pro zavaděč stačí /dev/null [8] a volba --no-bootloader, s kořenovým systémem je to podobné [9].
Pokud by někdo měl zájem to vyzkoušet, VPS s Guixem si můžete vytvořit na node1.stg (staging). Jinde zatím nebude fungovat integrace pro nastavení sítě. Více informací viz KB:
https://kb.vpsfree.org/manuals/distributions/guix
Jsou tam ještě nějaké nedostatky, které už nejspíš řešit nebudu, aspoň ne teď. Základ včetně integrace do vpsAdminu a Start Menu je zdá se funkční. Sami pro Guix využití nemáme, dělal jsem to spíš ze zajímavosti. Jestli Guix někdo použijete, budeme rádi za zpětnou vazbu.
ENGLISH:
TL;DR VPS can now use Guix distribution.
GNU Guix System [1] is a linux distribution based on Guix package manager. It is very similar to NixOS [2] and Nix, except that Guix is configured using Guile Scheme. Indeed, most of the system components including the init system Shepherd [3] are written in Scheme.
Unlike other well-known linux distributions, Guix and NixOS are configured declaratively: users/groups and all services with their settings that should a part of the target system are defined in a config file. It is possible to switch between different system configurations, be it an upgrade or downgrade. System versions can be switched at runtime or from the bootloader -- in our case, from the Start Menu [10]. Unlike NixOS, Guix contains only Free Software, as it is a part of the GNU project.
At vpsFree.cz, we use NixOS [5] almost everywhere. I was thus interested to see the state Guix is in. Unfortunately, I'm not familiar with Scheme, there are far too many parentheses! A year ago, one of our members tried to create [6] template for Guix, but we haven't been able to make it work. A few days ago, I've discovered a blogpost [7] that helped me understand the missing pieces. Our main issue was that inside the VPS, there's no bootloader and no need to mount the root file system, as it is mounted even before its /sbin/init is started. Guix configuration however requires them to be configured.
In the end it's pretty straightforward. /dev/null is used [8] as a device for the bootloader together with option --no-bootloader. Mounting of the root file system can be bypassed in a similar way [9].
If someone would like to give it a go, you can create VPS with Guix on node1.stg (staging). For more information, see KB:
https://kb.vpsfree.org/manuals/distributions/guix
There are several known issues, but the base system appears to be operational. Network configuration is integrated with vpsAdmin and the Start Menu can be used to run older system generations. As we do not have any actual use for Guix ourselves, I'm going to leave it as it is for now. We'll be glad for any feedback if you'll run anything on Guix.
[3] https://kb.vpsfree.cz/navody/vps/start_menu
[4] https://www.gnu.org/software/shepherd/
[5] https://github.com/vpsfreecz/vpsfree-cz-configuration
[6] https://github.com/vpsfreecz/vpsadminos-image-build-scripts/pull/47
[7] https://www.thedroneely.com/posts/guix-in-a-linux-container/
[8] https://github.com/vpsfreecz/vpsadminos/blob/14ac41e78566cdddc28fa40e2d79756...
[9] https://github.com/vpsfreecz/vpsadminos/blob/14ac41e78566cdddc28fa40e2d79756...
[10] https://kb.vpsfree.org/manuals/vps/start_menu
Jakub
On 2023-08-30 17:00:07 +0200, Jakub Skokan wrote:
Ahoj,
(English below)
TL;DR ve VPS lze nově používat distribuci Guix.
Tohle je super zprava, diky moc!
GNU Guix System [1] je linuxová distribuce založená na správci balíčků Guix. Funguje to velice podobně jako NixOS [2] a Nix, až na to, že Guix a celý systém se konfiguruje pomocí Guile Scheme. Ve Scheme jsou opravdu veškeré součásti systému, včetně init systému Shepherd [3].
Na rozdíl od klasických distribucí se Guix a NixOS konfigurují deklarativně: v konfiguračním souboru nadefinujeme kompletní podobu výsledného systému, tj. jaké má obsahovat uživatele/skupiny, služby a jejich nastavení. Ať už se jedná o aktualizaci nebo rollback, mezi různými verzemi systému se lze snadno přepínat buď za běhu, nebo při bootu v zavaděči, resp. u nás ve Start Menu [4]. Guix oproti NixOS obsahuje jen Free Software.
Protože ve vpsFree používáme NixOS [5] skoro na všechno, zajímalo mě taky, jak je na tom Guix. Bohužel Scheme pořádně neznám a ani mě to moc neláká -- je tam příliš mnoho závorek :) Před rokem se jeden člen snažil [6] šablonu pro Guix vytvořit, ale sám jsem neviděl cestu, jak na to. Až před pár dny jsem narazil na blog [7], který obsahoval potřebné informace. Hlavní problém byl, že ve VPS nemáme zavaděč a taky se nepřipojuje kořenový souborový systém -- je připojen už před spuštěním /sbin/init ve VPS. V konfiguraci však zavaděč i kořenový systém být musí, jinak se systém nesestaví.
Nakonec to není žádná věda: jako zařízení pro zavaděč stačí /dev/null [8] a volba --no-bootloader, s kořenovým systémem je to podobné [9].
Pokud by někdo měl zájem to vyzkoušet, VPS s Guixem si můžete vytvořit na node1.stg (staging). Jinde zatím nebude fungovat integrace pro nastavení sítě. Více informací viz KB:
https://kb.vpsfree.org/manuals/distributions/guix
Jsou tam ještě nějaké nedostatky, které už nejspíš řešit nebudu, aspoň ne teď. Základ včetně integrace do vpsAdminu a Start Menu je zdá se funkční. Sami pro Guix využití nemáme, dělal jsem to spíš ze zajímavosti. Jestli Guix někdo použijete, budeme rádi za zpětnou vazbu.
Postupne konvertuju svoje stroje na Guix, a VPS je take na seznamu, takze se k tomu urcite dostanu (otazka, jak uz to tak byva, je kdy).
Takze jeste jednou diky moc. :)
ENGLISH:
TL;DR VPS can now use Guix distribution.
GNU Guix System [1] is a linux distribution based on Guix package manager. It is very similar to NixOS [2] and Nix, except that Guix is configured using Guile Scheme. Indeed, most of the system components including the init system Shepherd [3] are written in Scheme.
Unlike other well-known linux distributions, Guix and NixOS are configured declaratively: users/groups and all services with their settings that should a part of the target system are defined in a config file. It is possible to switch between different system configurations, be it an upgrade or downgrade. System versions can be switched at runtime or from the bootloader -- in our case, from the Start Menu [10]. Unlike NixOS, Guix contains only Free Software, as it is a part of the GNU project.
At vpsFree.cz, we use NixOS [5] almost everywhere. I was thus interested to see the state Guix is in. Unfortunately, I'm not familiar with Scheme, there are far too many parentheses! A year ago, one of our members tried to create [6] template for Guix, but we haven't been able to make it work. A few days ago, I've discovered a blogpost [7] that helped me understand the missing pieces. Our main issue was that inside the VPS, there's no bootloader and no need to mount the root file system, as it is mounted even before its /sbin/init is started. Guix configuration however requires them to be configured.
In the end it's pretty straightforward. /dev/null is used [8] as a device for the bootloader together with option --no-bootloader. Mounting of the root file system can be bypassed in a similar way [9].
If someone would like to give it a go, you can create VPS with Guix on node1.stg (staging). For more information, see KB:
https://kb.vpsfree.org/manuals/distributions/guix
There are several known issues, but the base system appears to be operational. Network configuration is integrated with vpsAdmin and the Start Menu can be used to run older system generations. As we do not have any actual use for Guix ourselves, I'm going to leave it as it is for now. We'll be glad for any feedback if you'll run anything on Guix.
[3] https://kb.vpsfree.cz/navody/vps/start_menu
[4] https://www.gnu.org/software/shepherd/
[5] https://github.com/vpsfreecz/vpsfree-cz-configuration
[6] https://github.com/vpsfreecz/vpsadminos-image-build-scripts/pull/47
[7] https://www.thedroneely.com/posts/guix-in-a-linux-container/
[8] https://github.com/vpsfreecz/vpsadminos/blob/14ac41e78566cdddc28fa40e2d79756...
[9] https://github.com/vpsfreecz/vpsadminos/blob/14ac41e78566cdddc28fa40e2d79756...
[10] https://kb.vpsfree.org/manuals/vps/start_menu
Jakub _______________________________________________ Community-list mailing list -- community-list@lists.vpsfree.cz To unsubscribe send an email to community-list-leave@lists.vpsfree.cz
On 2023-08-30 17:00:07 +0200, Jakub Skokan wrote:
Ahoj,
(English below)
TL;DR ve VPS lze nově používat distribuci Guix.
GNU Guix System [1] je linuxová distribuce založená na správci balíčků Guix. Funguje to velice podobně jako NixOS [2] a Nix, až na to, že Guix a celý systém se konfiguruje pomocí Guile Scheme. Ve Scheme jsou opravdu veškeré součásti systému, včetně init systému Shepherd [3].
Na rozdíl od klasických distribucí se Guix a NixOS konfigurují deklarativně: v konfiguračním souboru nadefinujeme kompletní podobu výsledného systému, tj. jaké má obsahovat uživatele/skupiny, služby a jejich nastavení. Ať už se jedná o aktualizaci nebo rollback, mezi různými verzemi systému se lze snadno přepínat buď za běhu, nebo při bootu v zavaděči, resp. u nás ve Start Menu [4]. Guix oproti NixOS obsahuje jen Free Software.
Protože ve vpsFree používáme NixOS [5] skoro na všechno, zajímalo mě taky, jak je na tom Guix. Bohužel Scheme pořádně neznám a ani mě to moc neláká -- je tam příliš mnoho závorek :) Před rokem se jeden člen snažil [6] šablonu pro Guix vytvořit, ale sám jsem neviděl cestu, jak na to. Až před pár dny jsem narazil na blog [7], který obsahoval potřebné informace. Hlavní problém byl, že ve VPS nemáme zavaděč a taky se nepřipojuje kořenový souborový systém -- je připojen už před spuštěním /sbin/init ve VPS. V konfiguraci však zavaděč i kořenový systém být musí, jinak se systém nesestaví.
Nakonec to není žádná věda: jako zařízení pro zavaděč stačí /dev/null [8] a volba --no-bootloader, s kořenovým systémem je to podobné [9].
Pokud by někdo měl zájem to vyzkoušet, VPS s Guixem si můžete vytvořit na node1.stg (staging). Jinde zatím nebude fungovat integrace pro nastavení sítě. Více informací viz KB:
Comments regarding the "known issues" section:
guix system reconfigure requires –allow-downgrades, why? Something is fishy with the channels.
Guix after fresh install is a bit funny sometimes. If one runs `guix pull' before trying the reconfigure, the --allow-downgrades is no longer necessary.
I did however run into different issue:
/ssh:root@37.205.14.33:/etc/config $ guix system reconfigure --no-bootloader system.scm The following derivation will be built: /gnu/store/fb4i299scqpgczwgphjmh85k0z0qgmwc-grub.cfg.drv
building /gnu/store/fb4i299scqpgczwgphjmh85k0z0qgmwc-grub.cfg.drv... /gnu/store/255b46p2w1b06shnh4wjfz2fzs7r3p8h-system /gnu/store/9nlha7hybazc09bqgrxplq5w480r02pp-grub.cfg
activating system... making '/gnu/store/255b46p2w1b06shnh4wjfz2fzs7r3p8h-system' the current system... setting up setuid programs in '/run/setuid-programs'... populating /etc from /gnu/store/xz25p33mwywcwv4xnpg2jkr39hci71hg-etc... shepherd: Starting service host-name... shepherd: Service host-name started. shepherd: Service host-name running with value #<unspecified>. shepherd: Service host-name has been started. shepherd: Starting service user-homes... shepherd: Service user-homes has been started. shepherd: Starting service sysctl... shepherd: Service sysctl could not be started. shepherd: Starting service vpsadminos-networking... guix system: warning: exception caught while executing 'start' on service 'vpsadminos-networking': Throw to key `%exception' with args `("#<&invoke-error program: "/gnu/store/m6c5hgqg569mbcjjbp8l8m7q82ascpdl-bash-5.1.16/bin/bash" arguments: ("/ifcfg.add") exit-status: 2 term-signal: #f stop-signal: #f>")'. guix system: warning: some services could not be upgraded hint: To allow changes to all the system services to take effect, you will need to reboot.
There is /ifcfg.del, however (@ (vpsadminos) vpsadminos-networking) does not use it as #:stop, and even if it did, I do not think that (#:one-shot?) services do invoke #:stop. I will send a patch for this in due time (turning the service into "sleep inf", so that #:stop will start to work).
halt (graceful shutdown) has been observed to sometimes hang, please report in case it's still a problem.
This is sadly sometimes problem on actual physical machines as well, so it might not be an issue with the template itself. Just FYI.
cgroups v1 are not mounted. cgroups do not seem to be needed by the base system, contact us in case it's a problem for some service or submit a patch to the template.
The only high-profile package that explicitly depends on the cgroup v1 is currently docker afaik, which in a world where podman exists is not that important. I plan to try to produce a patch moving guix to v2, which should solve this issue.
Jsou tam ještě nějaké nedostatky, které už nejspíš řešit nebudu, aspoň ne teď.
One more thing I noticed is that host-name setting from vpsadmin is not propagated into the /etc/config/config.scm, hardly a deal breaker. Are there more that you know about that are not documented?
Základ včetně integrace do vpsAdminu a Start Menu je zdá se funkční.
I agree, based on some toying around it seems to work fine, thanks again for making it happen. :)
Sami pro Guix využití nemáme, dělal jsem to spíš ze zajímavosti. Jestli Guix někdo použijete, budeme rádi za zpětnou vazbu.
ENGLISH:
TL;DR VPS can now use Guix distribution.
GNU Guix System [1] is a linux distribution based on Guix package manager. It is very similar to NixOS [2] and Nix, except that Guix is configured using Guile Scheme. Indeed, most of the system components including the init system Shepherd [3] are written in Scheme.
Unlike other well-known linux distributions, Guix and NixOS are configured declaratively: users/groups and all services with their settings that should a part of the target system are defined in a config file. It is possible to switch between different system configurations, be it an upgrade or downgrade. System versions can be switched at runtime or from the bootloader -- in our case, from the Start Menu [10]. Unlike NixOS, Guix contains only Free Software, as it is a part of the GNU project.
At vpsFree.cz, we use NixOS [5] almost everywhere. I was thus interested to see the state Guix is in. Unfortunately, I'm not familiar with Scheme, there are far too many parentheses! A year ago, one of our members tried to create [6] template for Guix, but we haven't been able to make it work. A few days ago, I've discovered a blogpost [7] that helped me understand the missing pieces. Our main issue was that inside the VPS, there's no bootloader and no need to mount the root file system, as it is mounted even before its /sbin/init is started. Guix configuration however requires them to be configured.
In the end it's pretty straightforward. /dev/null is used [8] as a device for the bootloader together with option --no-bootloader. Mounting of the root file system can be bypassed in a similar way [9].
If someone would like to give it a go, you can create VPS with Guix on node1.stg (staging). For more information, see KB:
https://kb.vpsfree.org/manuals/distributions/guix
There are several known issues, but the base system appears to be operational. Network configuration is integrated with vpsAdmin and the Start Menu can be used to run older system generations. As we do not have any actual use for Guix ourselves, I'm going to leave it as it is for now. We'll be glad for any feedback if you'll run anything on Guix.
[3] https://kb.vpsfree.cz/navody/vps/start_menu
[4] https://www.gnu.org/software/shepherd/
[5] https://github.com/vpsfreecz/vpsfree-cz-configuration
[6] https://github.com/vpsfreecz/vpsadminos-image-build-scripts/pull/47
[7] https://www.thedroneely.com/posts/guix-in-a-linux-container/
[8] https://github.com/vpsfreecz/vpsadminos/blob/14ac41e78566cdddc28fa40e2d79756...
[9] https://github.com/vpsfreecz/vpsadminos/blob/14ac41e78566cdddc28fa40e2d79756...
[10] https://kb.vpsfree.org/manuals/vps/start_menu
Jakub _______________________________________________ Community-list mailing list -- community-list@lists.vpsfree.cz To unsubscribe send an email to community-list-leave@lists.vpsfree.cz
Thanks for the feedback!
On 8/30/23 18:45, wolf wrote:
On 2023-08-30 17:00:07 +0200, Jakub Skokan wrote: [...] Comments regarding the "known issues" section:
guix system reconfigure requires –allow-downgrades, why? Something is fishy with the channels.
Guix after fresh install is a bit funny sometimes. If one runs `guix pull' before trying the reconfigure, the --allow-downgrades is no longer necessary.
That didn't work for me. I ran guix pull and system reconfigure from the same shell, but system reconfigure still used some older commit. No idea why. I was able to workaround it with:
guix describe -f channels > /etc/guix/channels.scm guix system reconfigure [...] rm -f /etc/guix/channels.scm guix pull
...since then it works, but it doesn't make sense to me.
If it worked for you out of the box, I guess I'm fine with it x)
I did however run into different issue:
/ssh:root@37.205.14.33:/etc/config $ guix system reconfigure --no-bootloader system.scm The following derivation will be built: /gnu/store/fb4i299scqpgczwgphjmh85k0z0qgmwc-grub.cfg.drv building /gnu/store/fb4i299scqpgczwgphjmh85k0z0qgmwc-grub.cfg.drv... /gnu/store/255b46p2w1b06shnh4wjfz2fzs7r3p8h-system /gnu/store/9nlha7hybazc09bqgrxplq5w480r02pp-grub.cfg activating system... making '/gnu/store/255b46p2w1b06shnh4wjfz2fzs7r3p8h-system' the current system... setting up setuid programs in '/run/setuid-programs'... populating /etc from /gnu/store/xz25p33mwywcwv4xnpg2jkr39hci71hg-etc... shepherd: Starting service host-name... shepherd: Service host-name started. shepherd: Service host-name running with value #<unspecified>. shepherd: Service host-name has been started. shepherd: Starting service user-homes... shepherd: Service user-homes has been started. shepherd: Starting service sysctl... shepherd: Service sysctl could not be started. shepherd: Starting service vpsadminos-networking... guix system: warning: exception caught while executing 'start' on service 'vpsadminos-networking': Throw to key `%exception' with args `("#<&invoke-error program: \"/gnu/store/m6c5hgqg569mbcjjbp8l8m7q82ascpdl-bash-5.1.16/bin/bash\" arguments: (\"/ifcfg.add\") exit-status: 2 term-signal: #f stop-signal: #f>")'. guix system: warning: some services could not be upgraded hint: To allow changes to all the system services to take effect, you will need to reboot.
There is /ifcfg.del, however (@ (vpsadminos) vpsadminos-networking) does not use it as #:stop, and even if it did, I do not think that (#:one-shot?) services do invoke #:stop. I will send a patch for this in due time (turning the service into "sleep inf", so that #:stop will start to work).
I'd prefer if we could e.g. prevent the service from being restarted. Or make the script idempotent, so that it wouldn't fail. It makes no sense to bring down the network just because bash in shebang was updated. While /ifcfg.del exists, there's no real reason to call it, ever.
halt (graceful shutdown) has been observed to sometimes hang, please report in case it's still a problem.
This is sadly sometimes problem on actual physical machines as well, so it might not be an issue with the template itself. Just FYI.
This part was pretty annoying. Unlike other init systems, shepherd does not accept signals to properly shutdown. All it can do is respond to SIGINT by restarting itself. There's no way to halt using a signal, e.g. SIGPWR. So we invoke halt from inside the VPS, but even that is sometimes problematic as you say.
cgroups v1 are not mounted. cgroups do not seem to be needed by the base system, contact us in case it's a problem for some service or submit a patch to the template.
The only high-profile package that explicitly depends on the cgroup v1 is currently docker afaik, which in a world where podman exists is not that important. I plan to try to produce a patch moving guix to v2, which should solve this issue.
The available cgroup version depends on the host. So far we have cgroups v1 everywhere, migration to v2 is planned:
https://kb.vpsfree.org/manuals/vps/cgroups
Guix works with cgroups v2, I use it on my dev machine.
Jakub
PS: Please do not CC: news list, it is only for annoucements.
On 2023-08-30 19:19:25 +0200, Jakub Skokan wrote:
Thanks for the feedback!
On 8/30/23 18:45, wolf wrote:
On 2023-08-30 17:00:07 +0200, Jakub Skokan wrote: [...] Comments regarding the "known issues" section:
guix system reconfigure requires –allow-downgrades, why? Something is fishy with the channels.
Guix after fresh install is a bit funny sometimes. If one runs `guix pull' before trying the reconfigure, the --allow-downgrades is no longer necessary.
That didn't work for me. I ran guix pull and system reconfigure from the same shell, but system reconfigure still used some older commit. No idea why.
Hm, maybe you did not run `hash guix'?
Actually I re-created the VPS on staging, and, from fresh deploy, this is sufficient to run the reconfigure without --allow-downgrades:
ssh root@37.205.14.33 -t '. /etc/profile; guix pull; hash guix; guix system reconfigure --no-bootloader /etc/config/system.scm'
I wanted to put it here, maybe it will be of use to someone.
I was able to workaround it with:
guix describe -f channels > /etc/guix/channels.scm guix system reconfigure [...] rm -f /etc/guix/channels.scm guix pull
...since then it works, but it doesn't make sense to me.
If it worked for you out of the box, I guess I'm fine with it x)
I did however run into different issue:
/ssh:root@37.205.14.33:/etc/config $ guix system reconfigure --no-bootloader system.scm The following derivation will be built: /gnu/store/fb4i299scqpgczwgphjmh85k0z0qgmwc-grub.cfg.drv building /gnu/store/fb4i299scqpgczwgphjmh85k0z0qgmwc-grub.cfg.drv... /gnu/store/255b46p2w1b06shnh4wjfz2fzs7r3p8h-system /gnu/store/9nlha7hybazc09bqgrxplq5w480r02pp-grub.cfg activating system... making '/gnu/store/255b46p2w1b06shnh4wjfz2fzs7r3p8h-system' the current system... setting up setuid programs in '/run/setuid-programs'... populating /etc from /gnu/store/xz25p33mwywcwv4xnpg2jkr39hci71hg-etc... shepherd: Starting service host-name... shepherd: Service host-name started. shepherd: Service host-name running with value #<unspecified>. shepherd: Service host-name has been started. shepherd: Starting service user-homes... shepherd: Service user-homes has been started. shepherd: Starting service sysctl... shepherd: Service sysctl could not be started. shepherd: Starting service vpsadminos-networking... guix system: warning: exception caught while executing 'start' on service 'vpsadminos-networking': Throw to key `%exception' with args `("#<&invoke-error program: \"/gnu/store/m6c5hgqg569mbcjjbp8l8m7q82ascpdl-bash-5.1.16/bin/bash\" arguments: (\"/ifcfg.add\") exit-status: 2 term-signal: #f stop-signal: #f>")'. guix system: warning: some services could not be upgraded hint: To allow changes to all the system services to take effect, you will need to reboot.
There is /ifcfg.del, however (@ (vpsadminos) vpsadminos-networking) does not use it as #:stop, and even if it did, I do not think that (#:one-shot?) services do invoke #:stop. I will send a patch for this in due time (turning the service into "sleep inf", so that #:stop will start to work).
I'd prefer if we could e.g. prevent the service from being restarted. Or make the script idempotent, so that it wouldn't fail. It makes no sense to bring down the network just because bash in shebang was updated. While /ifcfg.del exists, there's no real reason to call it, ever.
There is #:transient?, but I do not know how well/if it interacts with #:one-shot and system reconfiguration. The script being idempotent is the correct solution, you are right.
halt (graceful shutdown) has been observed to sometimes hang, please report in case it's still a problem.
This is sadly sometimes problem on actual physical machines as well, so it might not be an issue with the template itself. Just FYI.
This part was pretty annoying. Unlike other init systems, shepherd does not accept signals to properly shutdown. All it can do is respond to SIGINT by restarting itself. There's no way to halt using a signal, e.g. SIGPWR. So we invoke halt from inside the VPS, but even that is sometimes problematic as you say.
cgroups v1 are not mounted. cgroups do not seem to be needed by the base system, contact us in case it's a problem for some service or submit a patch to the template.
The only high-profile package that explicitly depends on the cgroup v1 is currently docker afaik, which in a world where podman exists is not that important. I plan to try to produce a patch moving guix to v2, which should solve this issue.
The available cgroup version depends on the host. So far we have cgroups v1 everywhere, migration to v2 is planned:
https://kb.vpsfree.org/manuals/vps/cgroups
Guix works with cgroups v2, I use it on my dev machine.
You mean in foreign mode or in the GuixSD setup? I did not figure out easy built-in way to switch GuixSD to v2, so if there is one, I would love to know.
Jakub
PS: Please do not CC: news list, it is only for annoucements.
Sorry about that, I am used to reply-all on mailing lists, and did not notice that news were CCed.
Community-list mailing list -- community-list@lists.vpsfree.cz To unsubscribe send an email to community-list-leave@lists.vpsfree.cz
On 8/31/23 01:38, wolf wrote:
On 2023-08-30 19:19:25 +0200, Jakub Skokan wrote:
Thanks for the feedback!
On 8/30/23 18:45, wolf wrote:
On 2023-08-30 17:00:07 +0200, Jakub Skokan wrote: [...] Comments regarding the "known issues" section:
guix system reconfigure requires –allow-downgrades, why? Something is fishy with the channels.
Guix after fresh install is a bit funny sometimes. If one runs `guix pull' before trying the reconfigure, the --allow-downgrades is no longer necessary.
That didn't work for me. I ran guix pull and system reconfigure from the same shell, but system reconfigure still used some older commit. No idea why.
Hm, maybe you did not run `hash guix'?
Actually I re-created the VPS on staging, and, from fresh deploy, this is sufficient to run the reconfigure without --allow-downgrades:
ssh root@37.205.14.33 -t '. /etc/profile; guix pull; hash guix; guix system reconfigure --no-bootloader /etc/config/system.scm'
I wanted to put it here, maybe it will be of use to someone.
Yep, that's it, I missed both . /etc/profile and hash guix. I didn't know what hash does and I didn't think it would be important x) KB article updated!
There is /ifcfg.del, however (@ (vpsadminos) vpsadminos-networking) does not use it as #:stop, and even if it did, I do not think that (#:one-shot?) services do invoke #:stop. I will send a patch for this in due time (turning the service into "sleep inf", so that #:stop will start to work).
I'd prefer if we could e.g. prevent the service from being restarted. Or make the script idempotent, so that it wouldn't fail. It makes no sense to bring down the network just because bash in shebang was updated. While /ifcfg.del exists, there's no real reason to call it, ever.
There is #:transient?, but I do not know how well/if it interacts with #:one-shot and system reconfiguration. The script being idempotent is the correct solution, you are right.
I would wait for /run on tmpfs to be implemented:
https://issues.guix.gnu.org/64775
When that's done, we could modify /ifcfg.add as:
[ -f /run/vpsadminos-network ] && exit 0 touch /run/vpsadminos-network # ...the rest of the script...
to prevent re-running it. It won't work now when /run is persisted on disk. Until then, this activation error should be harmless anyways.
cgroups v1 are not mounted. cgroups do not seem to be needed by the base system, contact us in case it's a problem for some service or submit a patch to the template.
The only high-profile package that explicitly depends on the cgroup v1 is currently docker afaik, which in a world where podman exists is not that important. I plan to try to produce a patch moving guix to v2, which should solve this issue.
The available cgroup version depends on the host. So far we have cgroups v1 everywhere, migration to v2 is planned:
https://kb.vpsfree.org/manuals/vps/cgroups
Guix works with cgroups v2, I use it on my dev machine.
You mean in foreign mode or in the GuixSD setup? I did not figure out easy built-in way to switch GuixSD to v2, so if there is one, I would love to know.
I dunno, I tried Guix only inside container/VPS. I saw cgroups v2 support in the source:
https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/system/file-systems.scm#...
In our case, cgroups v2 seem to be pre-mounted by LXC when the host is using v2.
Jakub
community-list@lists.vpsfree.cz