The contents of my service file srvtemplate-data-i4-s1.conf is
[Unit]Description=test service for usersAfter=network.target local-fs.target[Service]Type=forkingRemainAfterExit=noPIDFile=/data/i4/srvt.pidLimitCORE=infinityEnvironmentFile=%I...[Install]WantedBy=multi-user.target
I am starting my service as follows passing it an environment file but it fails with error as below.
# systemctl start srvtemplate-data-i4-s1.conf@-data-i4-env.service
Failed to start srvtemplate-data-i4-s1.conf@-data-i4-s1-env.service: Unit srvtemplate-data-i4-s1.conf@-data-i4-env.service failed to load: No such file or directory.
The files are actually present
# ls -lrt /usr/lib/systemd/system/srvt*
-rw-r--r-- 1 root root 815 Dec 13 07:31 /usr/lib/systemd/system/srvtemplate-data-i4-s1.conf@.service
# ls /data/i4/env
/data/i4/env
# cat /data/i4/env
SRV_CONF="/data/i4/s1.conf"
But systemd not able to find the files.
When I do systemd reload and then fire the ablove start command it works fine.
systemctl daemon-reload
But still why is systemd not able to find the files and what can I do so that start command succeeds without firing the reload command?
