unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
From: Leo Famulari <leo@famulari.name>
To: Hilco Wijbenga <hilco.wijbenga@gmail.com>
Cc: help-guix@gnu.org
Subject: Re: SystemD & Symbolic Links
Date: Mon, 26 Dec 2016 22:48:44 -0500	[thread overview]
Message-ID: <20161227034844.GA14923@jasmine> (raw)
In-Reply-To: <CAE1pOi3KnbwJ9dTuDn462iXgR4rCtfDn0AGFPnziLjPqYY7Qqg@mail.gmail.com>

On Mon, Dec 26, 2016 at 03:14:42PM -0800, Hilco Wijbenga wrote:
> Hi all,

Welcome!

> I would like to use GUIX to organise my home directory but
> unfortunately when I install GUIX it does not work because SystemD
> (228 in my case) refuses to allow symlinks.

Systemd didn't support symlinked unit files until version 231:

https://github.com/systemd/systemd/commit/f777b4345e8c57e739bda746f78757d0fb136ac7

> Specifically, "systemctl enable guix-daemon" fails with "Failed to
> execute operation: Too many levels of symbolic links" (see [1]). Is
> there a workaround for this? I suppose I could simply copy
> guix-daemon.service into /etc/systemd/system instead of linking to it
> but I'm not sure how many other things will fail because of this
> symlink limitation.

I recommend copying the service file as you suggested. It's exactly what
I do on Debian, both before systemd 231 and after, and it works fine for
me.

If the ExecStart value contains a path to '/gnu/store/...', you should
replace that path with
'/var/guix/profiles/per-user/root/guix-profile/bin/guix-daemon'.

Using the absolute path to /gnu/store only works properly if the service
file is a symlink to root's profile, in which case the executable path
would get updated as root updates their packages. My suggested
replacement will have the same effect.

If you do that, make sure to recreate the rest of the ExecStart value
after the path to the guix-daemon.

PS What OS are you using? I'm wondering if it's too early to rely on
systemd 231 being widely deployed.

PPS It's "Guix", without all capital letters :)

  reply	other threads:[~2016-12-27  3:48 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-26 23:14 SystemD & Symbolic Links Hilco Wijbenga
2016-12-27  3:48 ` Leo Famulari [this message]
2016-12-27  4:40   ` Hilco Wijbenga
2016-12-27 10:02     ` ng0
2016-12-27 22:18     ` Leo Famulari
2016-12-28 20:46       ` Joshua Branson
2016-12-30 20:41         ` Leo Famulari

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161227034844.GA14923@jasmine \
    --to=leo@famulari.name \
    --cc=help-guix@gnu.org \
    --cc=hilco.wijbenga@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).