You are not logged in.

#1 2011-10-05 17:29:59

warfruit
Member
Registered: 2011-10-05
Posts: 6

[SOLVED] gdm suspends my machine, how can I stop it?

Hello

I've been searching for a while for an answer to this, your help would be much appreciated.  If my machine is left at the gdm screen, it will suspend after 30 mins, which is deeply inconvenient as I connect remotely to it quite often.

I can turn off the power saving in my own account, and if I leave that account logged in then it's fine, but gdm will still suspend. 

Can anybody help me out with this?  I've tried a few hacky tips I've read online but had no success, and I'd rather know the 'right' way.

Thanks smile

Last edited by warfruit (2011-10-05 20:24:25)

Offline

#2 2011-10-05 19:00:12

sunckell
Member
Registered: 2009-11-16
Posts: 6

Re: [SOLVED] gdm suspends my machine, how can I stop it?

I've been looking around for this also.  Seems that GDM uses some defaults.

Here is a bug report for another distro stating the issue:
https://bugs.launchpad.net/ubuntu/+sour … bug/860227

I'm sure there is a gsettings command that will set sleep-inactive-ac-type 'suspend' to off.   But as I am guessing you are, my computer is suspended right now and can't login to test the correct command.

If no one else posts the command, I'll do it in a couple hours when I get home.

Offline

#3 2011-10-05 19:12:55

warfruit
Member
Registered: 2011-10-05
Posts: 6

Re: [SOLVED] gdm suspends my machine, how can I stop it?

Thanks, I appreciate the reply!  I booted to runlevel 3 this morning to avoid the problem, so I can still talk to my box.. here's some keys I pulled out as root in a ssh session:

org.gnome.settings-daemon.plugins.power:

sleep-inactive-ac        false
sleep-inactive-ac-timeout    0
sleep-inactive-ac-type        'suspend'
sleep-inactive-battery        false
sleep-inactive-battery-timeout    1800
sleep-inactive-battery-type    'suspend'

I haven't really messed with gsettings before.  Does this look okay?  Or are we subject so some other issue smile

Thanks

Offline

#4 2011-10-05 19:20:42

sunckell
Member
Registered: 2009-11-16
Posts: 6

Re: [SOLVED] gdm suspends my machine, how can I stop it?

I am pretty sure, the settings for root aren't what we need to look at here.

I think there is the gdm user (not sure what the login shell is for this user) but the settings need to be verified under the gdm user.

so it'll look something like this:

[root@localhost]# su - gdm
[gdm@localhost]$ gsettings set org.gnome.settings-daemon.plugins.power sleep-inactive-ac-type off


I'm not sure if it should be off/disabled.  I was going to look at what it was set to under my account (I turned it off in the power settings for my account too) and set it to that value.


BTW.  here is a good url fromt he wiki about gsettings: http://blog.fpmurphy.com/2011/03/custom … shell.html

Offline

#5 2011-10-05 19:31:47

warfruit
Member
Registered: 2011-10-05
Posts: 6

Re: [SOLVED] gdm suspends my machine, how can I stop it?

Thanks for the link, I'll check that out smile

I had to enable the gdm account briefly to be able to su to it, but once I did I found this:

[gdm@kryten ~]$ dbus-launch gsettings range org.gnome.settings-daemon.plugins.power sleep-inactive-ac-type
enum
'blank'
'suspend'
'shutdown'
'hibernate'
'interactive'
'nothing'

So I've tried:

[gdm@kryten ~]$ dbus-launch gsettings set org.gnome.settings-daemon.plugins.power sleep-inactive-ac-type 'nothing'

I then rebooted so I'd hit runlevel 5 .. I'm now watching the clock to see what happens in 30 mins ;-)

Offline

#6 2011-10-05 20:12:53

warfruit
Member
Registered: 2011-10-05
Posts: 6

Re: [SOLVED] gdm suspends my machine, how can I stop it?

So far so good, up 45 mins.  Horray!

Thanks for your help with this one, sunckell.

Offline

#7 2011-10-09 01:51:16

kfrance
Member
From: Provo Utah
Registered: 2008-06-28
Posts: 14

Re: [SOLVED] gdm suspends my machine, how can I stop it?

How did you enable the gdm user account? "su -s /bin/bash gdm" allowed me to logon as gdm user but when I try to run "dbus-launch gsettings set org.gnome.settings-daemon.plugins.power sleep-inactive-ac-type 'nothing'" I get "unable to create '/root/.cache/dconf'; dconf will not work properly." It seems that it is looking for /var/lib/gdm/.cache/dconf folder but is using the wrong $HOME, but when I do "echo $HOME" is comes back with /var/lib/gdm.

Offline

#8 2011-10-09 06:26:49

adrianx
Member
From: South Africa
Registered: 2010-03-22
Posts: 70

Re: [SOLVED] gdm suspends my machine, how can I stop it?

# xhost +
# su - gdm -s /bin/bash
$ dbus-launch

https://wiki.archlinux.org/index.php/Gnome#Login_screen

Offline

#9 2011-10-09 16:04:39

sweetthdevil
Member
Registered: 2009-10-20
Posts: 415

Re: [SOLVED] gdm suspends my machine, how can I stop it?

Hi I am trying to achieve the same result but I also have the error, see terminal output below

[gdm@myhost sweetth]$ # xhost +
[gdm@myhost sweetth]$ # su - gdm -s /bin/bash
[gdm@myhost sweetth]$ dbus-launch
No protocol specified
DBUS_SESSION_BUS_ADDRESS=unix:abstract=/tmp/dbus-eZ66GG3r0c,guid=66509ecdb4a7d2be8ab9039800001448
DBUS_SESSION_BUS_PID=4417
[gdm@myhost sweetth]$ dbus-launch gsettings set org.gnome.settings-daemon.plugins.power sleep-inactive-ac-type 'nothing'
No protocol specified

** (process:4422): CRITICAL **: unable to create '/home/sweetth/.cache/dconf'; dconf will not work properly.

** (process:4422): WARNING **: GDBus.Error:org.freedesktop.DBus.Error.Spawn.ChildSignaled: Process /usr/lib/dconf/dconf-service received signal 5

Offline

#10 2011-10-09 22:18:19

kfrance
Member
From: Provo Utah
Registered: 2008-06-28
Posts: 14

Re: [SOLVED] gdm suspends my machine, how can I stop it?

First thank you adrianx for helping me, that worked.

It looks like the problems that sweetthdevil is having is that they are already logged in as gdm when they ran the commands. I became root, ran the commands given by adrianx, and then continued with the solution.

Offline

#11 2011-10-09 22:33:38

sweetthdevil
Member
Registered: 2009-10-20
Posts: 415

Re: [SOLVED] gdm suspends my machine, how can I stop it?

I am running the commands while connected with my regular user in gnome. Should those commands be run into the command prompt? (Using alt+f1 on the gem login screen?)

Edit: checked it and problem solved, many thanks

Last edited by sweetthdevil (2011-10-10 12:59:51)

Offline

#12 2011-10-10 09:51:39

sweetthdevil
Member
Registered: 2009-10-20
Posts: 415

Re: [SOLVED] gdm suspends my machine, how can I stop it?

right,

I have tried running the commands from tty1 prompt and it seems to have worked - will try it later and report.

Offline

Board footer

Powered by FluxBB