You are not logged in.

#26 2012-12-05 02:47:08

ould
Member
Registered: 2007-05-22
Posts: 124

Re: xbmc, systemd -> shutdown, reboot

Šaran wrote:

Use this in combination with this. Also install upower and add xbmc --standalone to .xinitrc.
Using xbmc service file will not register your session and therefore poklit won't be able to do it's job.

I will give that a try instead. I figured starting it as a service would work better but not having any luck that way. Funnily enough I had it set up your way when I was still using console-kit. lol.

Offline

#27 2012-12-06 13:02:36

dejavu
Member
Registered: 2008-05-26
Posts: 103

Re: xbmc, systemd -> shutdown, reboot

Using a xbmc build which includes the systemd commit already, but for me suspending still doesn't work. Tried it within a gnome-shell session and also by logging in and starting X manually. Also upower and polkit are installed.
Any further tip?
Best Regards

EDIT:
Solved it by using the file linked in post number 6 in https://bbs.archlinux.org/viewtopic.php?pid=1189842.
So with this it is possible again to start xbmc with a service file and having suspend functionality. Also as described in that thread you can modify the script to use the old udisk.

EDIT2:
After some testing I came to following conclusion regarding suspending and mounting by using Xbmc Frodo, polkit and udisks:
In a regular session e.g.: Gnome shell and gdm no further configuration is needed.
When no regular session is created and xbmc is started by using a service file, following polkit rules make suspending and mounting possible:

10-xbmc.rules in /etc/polkit-1/rules.d

polkit.addRule(function(action, subject) {
    if (action.id.match("org.freedesktop.login1.") && subject.isInGroup("power")) {
        return polkit.Result.YES;
    }
});

polkit.addRule(function(action, subject) {
    if (action.id.indexOf("org.freedesktop.udisks") == 0 && subject.isInGroup("storage")) {
        return polkit.Result.YES;
    }
});

Note: Rules found in this forum and thanks goes to the original authors!

Best Regards

Last edited by dejavu (2012-12-07 15:05:45)

Offline

#28 2012-12-28 22:56:33

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: xbmc, systemd -> shutdown, reboot

@dejavu - Thanks for the post.  Can you recommend a method to troubleshoot?  I have your files installed via the xbmc-beta package in the AUR but neither reboot nor shutdown functions on my box.


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#29 2012-12-29 23:20:18

dejavu
Member
Registered: 2008-05-26
Posts: 103

Re: xbmc, systemd -> shutdown, reboot

Hey,
- User has to be in the power and storage group.
- Packages udisks, upower and polkit have to be installed.
Hope that helps...

Last edited by dejavu (2012-12-29 23:21:19)

Offline

#30 2012-12-30 11:51:35

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: xbmc, systemd -> shutdown, reboot

@dejavu - Thanks.  User was not in the power group.  Works fine now.  I will update the xbmc-beta package's readme.install with this info.


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#31 2012-12-31 11:02:30

greenfish
Member
From: eating fish in /dev/null
Registered: 2008-08-30
Posts: 229

Re: xbmc, systemd -> shutdown, reboot

dejavu wrote:

Hey,
- User has to be in the power and storage group.
- Packages udisks, upower and polkit have to be installed.
Hope that helps...

Thank You. I can now finally restart/shutdown xbmc after systemd upgrade.

Happy New Year


ARCH64 archSKYNET server AMD  Phenom(tm) II X2 550 HDD 6TB Ram 8GB
Hobbies: Running, Pistol Marksmanship, Classic Music

Offline

#32 2013-01-23 18:13:25

elisiano
Member
Registered: 2012-04-27
Posts: 5

Re: xbmc, systemd -> shutdown, reboot

I seem to be in the same situation and I also followed the instructions in comment #27 by dejavu (and of course upower and polkit are installed) but it doesn't work.
I'm also frustrated by the absence of anything relevant in the logs.

In the logs:
[...]
19:02:39 T:139957927421888    INFO: Selected UPower as PowerSyscall
[...]
19:02:46 T:139957927421888   DEBUG: UPower: Recieved an unknown signal NameAcquired
[...]


Any hints how I could dig some more details?

Thanks, Elisiano

Offline

#33 2013-02-06 06:57:46

denn
Member
From: Russia
Registered: 2012-10-24
Posts: 5

Re: xbmc, systemd -> shutdown, reboot

elisiano wrote:

I seem to be in the same situation and I also followed the instructions in comment #27 by dejavu (and of course upower and polkit are installed) but it doesn't work.
I'm also frustrated by the absence of anything relevant in the logs.

In the logs:
[...]
19:02:39 T:139957927421888    INFO: Selected UPower as PowerSyscall

Looks like you are using sysvinit, not systemd. If true, simply replace "org.freedesktop.login1" with "org.freedesktop.UPower" in the first polkit rule.

Last edited by denn (2013-02-06 06:58:17)

Offline

Board footer

Powered by FluxBB