Re: Create an rsyncd.service fedora 16

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Nov 28, 2011 at 10:42 AM, David Highley
<dhighley@xxxxxxxxxxxxxxxxxxxxxxx> wrote:
> "David Highley wrote:"
>> Looked at the openvpn@.service script and see the type=forking
>> statement. We added this but with the above issue not able to tell if it
>> helped. The document on systemd.exec still leaves us wondering where and
>> which file to insert the StandardInput statement. Will look at more
>> scripts to see if we can determine the correct location.

"Type=forking" doesn't work with inetd-style daemons; by definition
they cannot fork.  openvpn isn't an inetd-style service, it uses the @
in a different manner, because it can be started with more than one
configuration file, as opposed to more than one socket like
rsyncd/inetd services.

StandardInput does go into the [Service] section of the .service file;
that was done correctly.

> Just to be clear we now have:
<snipped>

I double-checked a few details and there are some other things that
need to be fixed:

EnvironmentFile is incorrect.  EnvironmentFile is generally used for
things in /etc/sysconfig, and can only contain a list of environment
variables that are passed to the Exec lines.  (e.g. you might have
"PORT=8080" in /etc/sysconfig/foobar and "ExecStart=/usr/sbin/foobar
-p $PORT").  This line can be removed.

inetd-style services don't need an [Install] section in the .service
file at all; that's only necessary for services that use systemd's new
socket activation features.  So that section can also be removed.

"After=socket.target" is implicit in F16, it's a part of
DefaultDependencies.  So it can be safely removed, but doesn't hurt
anything if it stays.  (I mention this only because I removed it out
of habit in my below example, it doesn't matter if it stays or goes.)

So, your final files should look like:
https://gist.github.com/1401352

That should work just fine.  Remember, you need to operate on the
socket, not the service.  systemd will start the service itself when
users connect to it.  So, to enable the socket to start when your
computer starts, run:
systemctl enable rsyncd.socket

To start the rsyncd socket so accepts connections right now, run:
systemctl start rsyncd.socket

-T.C.
-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
Have a question? Ask away: http://ask.fedoraproject.org


[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux