[SSSD-users] sssd users and systemd services?

Dmitri Pal dpal at redhat.com
Tue Sep 16 14:11:25 UTC 2014


On 09/15/2014 01:53 PM, Nordgren, Bryce L -FS wrote:
>> Do I get it right that you are not actually trying to run systemd itself as a user
>> but to start a service by systemd that will run as an SSSD user.
>> You might have chicken and egg problem because the user might not be available
>> until SSSD is started and running. So I think the service you are trying to start should
>> be dependent on SSSD and make sure that SSSD is running.
>>
>> Sorry if I misunderstood what you are trying to do.
>> Dmitri
> Sorry for not getting back to you earlier, I missed your response. Correct: I'm not altering who runs system itself, but trying to run my "ipython-notebook" service as my own domain user account.
>
> I can't even get it to work manually, after I've logged in using the account with which I'm trying to run the service. Sorry the following is ellipsized, I can only get to the non-ellipsized parts with journalctl and a pager, but they really don't add value. The important part is code=exited, status=217/USER, which is a systemd code, not an ipython code:
>
> [bnordgren at lugosi ~]$ sudo systemctl start ipython-notebook
> [bnordgren at lugosi ~]$ sudo systemctl status ipython-notebook
> ipython-notebook.service - IPython notebook service
>     Loaded: loaded (/etc/systemd/system/ipython-notebook.service; enabled)
>     Active: failed (Result: exit-code) since Mon 2014-09-15 11:45:32 MDT; 7s ago
>    Process: 15558 ExecStart=/bin/ipython notebook (code=exited, status=217/USER)
>
> Sep 15 11:45:32 lugosi.usfs-i2.umt.edu systemd[1]: Starting IPython notebook ...
> Sep 15 11:45:32 lugosi.usfs-i2.umt.edu systemd[1]: Started IPython notebook s...
> Sep 15 11:45:32 lugosi.usfs-i2.umt.edu systemd[1]: ipython-notebook.service: ...
> Sep 15 11:45:32 lugosi.usfs-i2.umt.edu systemd[1]: Unit ipython-notebook.serv...
> [bnordgren at lugosi ~]$ sudo cat /etc/systemd/system/ipython-notebook.service
> [Unit]
> Description=IPython notebook service
> After=syslog.target network.target
>
> [Service]
> Type=simple
> User=bnordgren
> ExecStart=/bin/ipython notebook
> KillMode=process
> Environment=PYTHONPATH=/home/bnordgren/src/pylsce
>
> [Install]
> WantedBy=multi-user.target
> [bnordgren at lugosi ~]$ getent passwd bnordgren
> bnordgren:*:10001:10000:Nordgren, Bryce L -FS:/home/bnordgren:/bin/bash
>   [bnordgren at lugosi ~]$ /bin/ipython notebook
> [NotebookApp] Using existing profile dir: u'/home/bnordgren/.ipython/profile_default'
> [NotebookApp] Serving notebooks from /home/bnordgren/notebooks
> [NotebookApp] The IPython Notebook is running at: http://[all ip addresses on your system]:8888/ipython/
> [NotebookApp] Use Control-C to stop this server and shut down all kernels.
>
>
>
>
>
>
>
>
> This electronic message contains information generated by the USDA solely for the intended recipients. Any unauthorized interception of this message or the use or disclosure of the information it contains may violate the law and subject the violator to civil or criminal penalties. If you believe you have received this message in error, please notify the sender and delete the email immediately.
I am not sure this is the best list for this question. May be you should 
ask systemd guys.

-- 
Thank you,
Dmitri Pal

Sr. Engineering Manager IdM portfolio
Red Hat, Inc.



More information about the sssd-users mailing list