LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 03-02-2016, 03:27 PM   #1
joe0172
LQ Newbie
 
Registered: Mar 2016
Distribution: Debian Jesse (8.2)
Posts: 11

Rep: Reputation: Disabled
Debian Server is going to sleep and will not wake up


Hello!

I'm experiencing a problem that needs to be addressed.

I'm using Debian Jesse as a server. the intent is to build a webserver.

The hardware I'm using is a Dell GX520 desktop. it is NOT a server class box.

I'm NOT using any form of GUI desktop. Strictly command line only.

The problem....

After successfully starting up, the server works fine, but if I walk away from it, it goes to "Sleep". the light on the power switch blinks yellow and the screen blanks out.

Pressing keys on the keyboard doesn't wake it up. moving the mouse doesn't wake it up.

the only thing I can do is hold the power switch in until it shuts off the computer and then I can restart it.

After looking around the 'net, I found a command I can use to "disable" the sleep "feature" the command is...

systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target


This will work for a single instance. If I reboot the server, I have to issue the command again.

I've looked at the BIOS settings, and there are options for power management, but they are not very helpful.

Is there any way I can disable these items permanently?
 
Old 03-02-2016, 09:26 PM   #2
kaz2100
Senior Member
 
Registered: Apr 2005
Location: Penguin land, with apple, no gates
Distribution: SlackWare > Debian testing woody(32) sarge etch lenny squeeze(+64) wheezy jessie stretch buster
Posts: 1,725

Rep: Reputation: 107Reputation: 107
Hya,

How logs look like? (check them through ssh may be one idea)
 
Old 03-02-2016, 10:21 PM   #3
joe0172
LQ Newbie
 
Registered: Mar 2016
Distribution: Debian Jesse (8.2)
Posts: 11

Original Poster
Rep: Reputation: Disabled
What should I be looking for, specifically?
 
Old 03-03-2016, 03:08 AM   #4
life0riley
Member
 
Registered: Feb 2016
Location: Salem, OR, USA
Distribution: Kubuntu, Xubuntu, Debian, Fedora
Posts: 36

Rep: Reputation: 4
Are you sure this isn't a power supply or power issue?

I found a couple websites that point at this with the power light blinking yellow.
Optiplex GX520 computer will "turn off" or go to a sleep mode, yellow light?
Dell Optiplex GX520 hibernation/sleep mode issues
 
1 members found this post helpful.
Old 03-03-2016, 06:48 AM   #5
fmattheus
Member
 
Registered: Nov 2015
Posts: 104

Rep: Reputation: 38
If you want that command to run every time the machine is started, the easiest way is to create a file /etc/rc.local make it executable, and put your one line command in it.
 
Old 03-03-2016, 07:38 AM   #6
zhjim
Senior Member
 
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,748
Blog Entries: 11

Rep: Reputation: 233Reputation: 233Reputation: 233
systemctl has its own "run on startup" file. Don't need to use /etc/rc.local or alike. Checkout /etc/sysctl.conf or /etc/sysctl.d
 
Old 03-03-2016, 07:54 AM   #7
fmattheus
Member
 
Registered: Nov 2015
Posts: 104

Rep: Reputation: 38
I'm assuming you're referring to systemd. /etc/sysctl.conf and /etc/sysctl.d are used for setting kernel parameters.

You you can create service file for systemd, but systemd in jessie still runs the /etc/rc.local file. It's executed via the /lib/systemd/system/rc-local.service service file.
 
Old 03-03-2016, 09:48 AM   #8
zhjim
Senior Member
 
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,748
Blog Entries: 11

Rep: Reputation: 233Reputation: 233Reputation: 233
Upsi right. seems like systemd and not sysctl.

I'm out
 
Old 03-03-2016, 03:23 PM   #9
joe0172
LQ Newbie
 
Registered: Mar 2016
Distribution: Debian Jesse (8.2)
Posts: 11

Original Poster
Rep: Reputation: Disabled
Power issues

Life0Riley put me onto the issue of a power problem. the blinking yellow power switch....

I opened up the box, blew out as much dust as I could find, and tightened up the connectors, including the memory chips, One of them may have been loose.

Booted the box, UPTIME reported 4:48 hrs up. with no glitches. I'm going to leave it alone to see if it stays up.
The monitor goes off, but a keypress brings it back up.

Looks good so far. I'll let you know later how it goes.
 
Old 03-04-2016, 09:10 PM   #10
joe0172
LQ Newbie
 
Registered: Mar 2016
Distribution: Debian Jesse (8.2)
Posts: 11

Original Poster
Rep: Reputation: Disabled
Upate...

Well, I was running the box for over 4 hours and left the office for dinner....
Got back and the power switch was blinking yellow... so....
I still have some form of a power problem.

the only difference I made in the box was that I installed a 2TB SATA hard drive in it.

It originally had an 80MB hard drive in it.

THe power supply is rated at 305 W.

Could the new drive be pulling too much power?
 
Old 03-04-2016, 09:52 PM   #11
life0riley
Member
 
Registered: Feb 2016
Location: Salem, OR, USA
Distribution: Kubuntu, Xubuntu, Debian, Fedora
Posts: 36

Rep: Reputation: 4
You could try this:
eXtreme Power Supply Calculator
 
Old 03-04-2016, 10:05 PM   #12
joe0172
LQ Newbie
 
Registered: Mar 2016
Distribution: Debian Jesse (8.2)
Posts: 11

Original Poster
Rep: Reputation: Disabled
This is a little out of my league. I'm not a hardware guy....

Based on the inputs I used (I took a guess on some) I'm within the PS rating of 305W

I'm going to try and swap out the drive for a smaller one...
 
Old 03-04-2016, 11:01 PM   #13
life0riley
Member
 
Registered: Feb 2016
Location: Salem, OR, USA
Distribution: Kubuntu, Xubuntu, Debian, Fedora
Posts: 36

Rep: Reputation: 4
Was your old hard drive 80 MB or 80 GB?

You could install inxi. It is in the Debian repositories.

Inxi is a system information script that can display various things about your hardware and software. This could help eliminate some of the guess work when trying to figure out your specs.

Here is the output from mine:
Code:
life0riley@kubuntu-desktop:~$ inxi -Fz
System:    Host: kubuntu-desktop Kernel: 3.2.0-99-generic-pae i686 (32 bit) Desktop: KDE 4.8.5 Distro: Ubuntu 12.04 precise
Machine:   Mobo: ASUSTeK model: CM5570 version: Rev X.0x Bios: American Megatrends version: 0207 date: 05/13/2009
CPU:       Dual core Pentium CPU E5300 (-MCP-) cache: 2048 KB flags: (lm nx pae sse sse2 sse3 ssse3) 
           Clock Speeds: 1: 1203.00 MHz 2: 1203.00 MHz
Graphics:  Card: NVIDIA GF119 [GeForce GT 610] 
           X.Org: 1.11.3 drivers: nvidia (unloaded: fbdev,vesa,nouveau) Resolution: 2560x1440@60.0hz 
           GLX Renderer: GeForce GT 610/PCIe/SSE2 GLX Version: 4.2.0 NVIDIA 304.131
Audio:     Card-1: NVIDIA GF119 HDMI Audio Controller driver: snd_hda_intel Sound: ALSA ver: 1.0.24
           Card-2: Intel 82801JI (ICH10 Family) HD Audio Controller driver: snd_hda_intel 
Network:   Card: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller driver: r8169 
           IF: eth0 state: up speed: 1000 Mbps duplex: full mac: <filter>
Drives:    HDD Total Size: 2000.4GB (44.8% used) 1: id: /dev/sda model: WDC_WD5000AADS size: 500.1GB 
           2: id: /dev/sdc model: WDC_WD1002FAEX size: 1000.2GB 3: id: /dev/sdb model: WDC_WD5000AAKS size: 500.1GB 
Partition: ID: / size: 453G used: 294G (69%) fs: ext4 ID: swap-1 size: 6.44GB used: 0.00GB (0%) fs: swap 
RAID:      No RAID devices detected - /proc/mdstat and md_mod kernel raid module present
Sensors:   System Temperatures: cpu: 37.0C mobo: 25.0C gpu: 38C 
           Fan Speeds (in rpm): cpu: 312 psu: 0 sys-1: 0 
Info:      Processes: 167 Uptime: 23:38 Memory: 1690.7/6054.5MB Client: Shell (bash) inxi: 1.9.17 
life0riley@kubuntu-desktop:~$
Age could be a factor also.
 
Old 03-05-2016, 01:00 PM   #14
joe0172
LQ Newbie
 
Registered: Mar 2016
Distribution: Debian Jesse (8.2)
Posts: 11

Original Poster
Rep: Reputation: Disabled
it was an 80 GB drive.

I installed a spare 80 GB drive in the box and started to install Debian on it, only to have the SAME PROBLEM OCCUR during the install.

I have another box that I can use. the 2TB drive wont fit in it, (it's too thick) but i'll work with the 80 GB one and see what happens.
 
Old 03-05-2016, 02:18 PM   #15
life0riley
Member
 
Registered: Feb 2016
Location: Salem, OR, USA
Distribution: Kubuntu, Xubuntu, Debian, Fedora
Posts: 36

Rep: Reputation: 4
Quote:
Originally Posted by joe0172 View Post
...
I installed a spare 80 GB drive in the box and started to install Debian on it, only to have the SAME PROBLEM OCCUR during the install.
...
I thought Debian was already installed on the Dell GX520 before adding the additional drive. I'm confused now. Are you just replacing the original hard drive and then installing Debian?

I thought this was the sequence of events based on your description:
  1. You had a Dell GX520 running Debian 8 that boots to command line only
  2. It would spontaneously go to sleep or shut down with the power light blinking yellow (suggests it could be a power problem)
  3. To resolve this you opened the box and blew out the dust and re-seated the connections
  4. This appeared to work until you added an additional 2TB hard drive (or replaced the primary hard drive and re-installed Debian - I'm not sure which now)
  5. Thinking the 2TB drive was drawing too much power you swapped it out for an 80GB drive, but you are still experiencing the issue

At what point in the Debian install process did your computer go to sleep or shut down? Take a picture of your monitor and post it if possible or provide a detailed description.

We really need more information about your hardware.
  • CPU (Central Processor Unit) make (Intel, AMD, ?) and whether 32-bit, 64-bit, or ?
  • GPU (Graphics Processor Unit) manufacturer and model
  • RAM (how much installed)
  • HDs (number of and type internal - number of and type external)
  • Optical Drives (number of and type internal - number of and type external)
 
  


Reply

Tags
sleep


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Debian 7 does not wake keyboard after sleep kwill Debian 3 07-18-2013 12:51 AM
Halt after several second before wake up after sleep Sweetie Linux - Laptop and Netbook 1 06-25-2013 01:40 PM
[SOLVED] Sleep and Wake scheduling lonesoac0 Linux - Software 0 02-05-2012 03:25 PM
how to wake up from S3 acpi sleep state? bluesmanu Linux - Laptop and Netbook 4 01-15-2006 03:22 PM
Screen does not wake up after going to sleep at promp PSIPHON Linux - General 1 08-09-2005 08:30 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 05:03 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration