Hi Rene,

Rene <ikhu...@gmail.com> writes:

> On the other hand, in linux there is `--system` argument, how does this
> argument work?, Is there a script that uses it?. To test `--system`, I
> removed it from my linux system and when loging in with my user it does not
> detect any command.
>
> BOOT_IMAGE=/gnu/store/fiqgyafknihbvmz4j62ddb67p79kfcbk-linux-libre-4.19.13/bzImage
>  --root=my-root --system=/var/guix/profiles/system-87-link 
> --load=/var/guix/profiles/system-87-link/boot

To see how the Linux kernel argument "--system" is used, check out the
"boot-time-system" procedure in gnu/build/activation.scm.  Ultimately
this is used by the activation-service-type, defined in
gnu/services.scm.

In short, when the system boots, the activation service will atomically
flip the "/run/current-system" symlink. and then run all the activation
scripts defined by services that extend the activation service.  The
value of "--system" can be overridden by setting the GUIX_NEW_SYSTEM
environment variable; in fact, we do that in the switch-to-system
procedure in guix/scripts/system.scm, which is used when running
commands like "guix system reconfigure", "guix system roll-back," and
"guix system switch-generation".

Hopefully that helps!

-- 
Chris

Attachment: signature.asc
Description: PGP signature

Reply via email to