Re: [sane-devel] systemd and saned

2017-11-15 Thread ToddAndMargo

On 11/15/2017 12:33 AM, Guillaume Courtois wrote:

https://www.freedesktop.org/software/systemd/man/systemd.service.html
from example 1

    "Since no ExecStop= was specified, systemd will send SIGTERM
    to all processes started from this service, and after
    a timeout also SIGKILL. This behavior can be modified, see
    systemd.kill(5) for details."

I couldn't find anyuthing on ExecReload


That seems normal, if no stop action is given, systemd will kill 
remaining processes.

All init scripts do the same.



I got this back from Ask Fedora:


$ sudo systemctl reload bluetooth
Failed to reload bluetooth.service: Job type reload is not applicable 
for unit bluetooth.service.

See system logs and 'systemctl status bluetooth.service' for details.


--
~~
Computers are like air conditioners.
They malfunction when you open windows
~~


--
sane-devel mailing list: sane-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel
Unsubscribe: Send mail with subject "unsubscribe your_password"
to sane-devel-requ...@lists.alioth.debian.org


Re: [sane-devel] systemd and saned

2017-11-14 Thread ToddAndMargo

On 11/14/2017 01:18 AM, Guillaume Courtois wrote:

Le 14/11/2017 03:45, ToddAndMargo a écrit :

On 11/12/2017 01:06 AM, Guillaume Courtois wrote:

Le 12/11/2017 10:03, ToddAndMargo a écrit :

On 11/12/2017 12:59 AM, Guillaume Courtois wrote:

Usually stop is called right after start if you
do not have a

 RemainAfterExit=yes


Sure about that ? Seems strange to me.


But I do not see a stop here.


Yep, definitively missing.


If you have a "stop" and "RemainAfterExit=no", it
will call "stop" right after it calls "start".
That is probably why they left off the "stop"


I mean, if you put nothing it will not trigger a stop when you launch 
it.


So for me the RemainAfterExit=yes is implicit.
But surely, if you add RemainAfterExit=no you must have a stop script.

Also, if you do a systemctl stop service_name, it uses the stop 
command too.


I am looking to see if the lack of a stop line affects
systemctl's "stop" and "reload" functions


I'd say yes, but maybe a unit to manage a socket does not need a stop 
function ?


https://www.freedesktop.org/software/systemd/man/systemd.service.html
from example 1

"Since no ExecStop= was specified, systemd will send SIGTERM
to all processes started from this service, and after
a timeout also SIGKILL. This behavior can be modified, see
systemd.kill(5) for details."

I couldn't find anyuthing on ExecReload

--
~~
Computers are like air conditioners.
They malfunction when you open windows
~~


--
sane-devel mailing list: sane-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel
Unsubscribe: Send mail with subject "unsubscribe your_password"
to sane-devel-requ...@lists.alioth.debian.org

Re: [sane-devel] systemd and saned

2017-11-11 Thread ToddAndMargo

On 11/10/2017 09:28 PM, ToddAndMargo wrote:


I just posted:

RFE: please include the systemd's config files
https://bugzilla.redhat.com/show_bug.cgi?id=1512252

It is very unlikely to go through as RHEL is not very good
on keeping up with things.



--
sane-devel mailing list: sane-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel
Unsubscribe: Send mail with subject "unsubscribe your_password"
to sane-devel-requ...@lists.alioth.debian.org


Re: [sane-devel] systemd and saned

2017-11-11 Thread Louis Lagendijk
On Fri, 2017-11-10 at 21:28 -0800, ToddAndMargo wrote:
> Dear Sane List,
> 
> Google is failing me here.
> 
> I need to get saned running as a service under systemd.
> Does anyone have a paper on how to do this?
> 
That may depend on your distribution. The saned man-page gives an
example (it actually gives 2 examples, depending on whether your saned
is compiled with systemd support)

Louis


-- 
sane-devel mailing list: sane-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel
Unsubscribe: Send mail with subject "unsubscribe your_password"
 to sane-devel-requ...@lists.alioth.debian.org


Re: [sane-devel] systemd and saned

2017-11-11 Thread Guillaume Courtois


Oups, I did not send it to the list :-(

Le 11/11/2017 17:21, Guillaume Courtois a écrit :

Hi,

Yes, you have to create a systemd unit. It's pretty simple, I'm
surprised you don't find any example on the internet.
Basically, you create the file in the right format
(your_service.service), put it in /etc/systemd/system and do systemctl
enable your_service then systemctl start your_service and that's all.

On my debian sid, I already have this :

/lib/systemd/system# cat saned@.service
[Unit]
Description=Scanner Service
Requires=saned.socket

[Service]
ExecStart=/usr/sbin/saned
User=saned
Group=saned
StandardInput=null
StandardOutput=syslog
StandardError=syslog
Environment=SANE_CONFIG_DIR=/etc/sane.d
# Environment=SANE_CONFIG_DIR=/etc/sane.d SANE_DEBUG_DLL=255

[Install]
Also=saned.socket

Bye.

Le 11/11/2017 06:28, ToddAndMargo a écrit :

Dear Sane List,

Google is failing me here.

I need to get saned running as a service under systemd.
Does anyone have a paper on how to do this?

Do I need to write my own systemd script?

Many thanks,
-T


# find /usr/lib/systemd -iname \*saned\*


# yum --enablerepo=* whatprovides saned
sane-backends-1.0.24-9.el7.x86_64 : Scanner access software
Repo    : @sl
Matched from:
Filename    : /usr/sbin/saned

# rpm -qa sane-backends
sane-backends-1.0.24-9.el7.x86_64

--
~~
Computers are like air conditioners.
They malfunction when you open windows
~~


0x6C853BC3.asc
Description: application/pgp-keys
-- 
sane-devel mailing list: sane-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel
Unsubscribe: Send mail with subject "unsubscribe your_password"
 to sane-devel-requ...@lists.alioth.debian.org