On 12/29/2015 09:16 PM, Chaiken, Alison wrote:
bobafetthotmail <[email protected]> writes:
Finally found a workaround, bypassing systemctl.

[ . . . ]

ln -s /etc/folder2ram/folder2ram.service
/lib/systemd/system/local-fs.target.wants/folder2ram.service

[ . . . ]

On 12/13/2015 07:09 PM, bobafetthotmail wrote: Hi, it's me again. :)

I made a systemd unit called "folder2ram.service", with these
contents:

------
[Unit]
Description=folder2ram systemd service

[Service]
Type=oneshot
ExecStart=/sbin/folder2ram -mountall
ExecStop=/sbin/folder2ram -umountall
RemainAfterExit=yes

[Install]
WantedBy=multi-user.target

I'm curious: did you try

   WantedBy=local-fs.target

in your unit file rather than multi-user.target? Once you've created the symlink by hand, does 'systemctl disable' then work?

FWIW, I've had no problem creating my own unit files and enabling them on Jessie.

Best wishes,
Alison

---
Alison Chaiken                      [email protected], 650-279-5600
http://{ she-devel.com, exerciseforthereader.org }
"Democracy is the original crowd-sourcing." -- Philip Tetlock,
_Superforecasting_


Yes, my current is with "WantedBy=local-fs.target" also because that's better for what the script does (the less programs are active when it swaps things, the better).

"Systemctl disable folder2ram" says that it has removed the symlink, but it doesn't remove it.

Only way to disable my unit is delete the symlink by hand.

-Albert

_______________________________________________
systemd-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/systemd-devel

Reply via email to