SageTV Community  

Go Back   SageTV Community > SageTV Development and Customizations > SageTV Github Development
Forum Rules FAQs Community Downloads Today's Posts Search

Notices

SageTV Github Development Discussion related to SageTV Open Source Development. Use this forum for development topics about the Open Source versions of SageTV, hosted on Github.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 07-20-2016, 05:02 PM
chairmanmao's Avatar
chairmanmao chairmanmao is offline
Sage Advanced User
 
Join Date: Aug 2006
Location: San Carlos, CA
Posts: 81
linux v9 sleep wake timers

Jeff responded to a question I posed back in March of this year about sleep/wake timers in linux v9, to the effect that they weren't in the linux implementation but would be reasonably straightforward to implement (I asked the question because my sage server runs infrequently enough that I don't want the server live 24/7, in order to save electricity).

Has anyone implemented the necessary functionality in the last few months? Or researched it some more to see what's involved?
Reply With Quote
  #2  
Old 07-21-2016, 01:12 PM
Narflex's Avatar
Narflex Narflex is offline
Sage
 
Join Date: Feb 2003
Location: Redondo Beach, CA
Posts: 6,349
I can tell you no one has added it because I would have seen the change come through GitHub.
__________________
Jeffrey Kardatzke
Google
Founder of SageTV
Reply With Quote
  #3  
Old 07-22-2016, 06:24 AM
Fuzzy's Avatar
Fuzzy Fuzzy is offline
SageTVaholic
 
Join Date: Sep 2005
Location: Jurupa Valley, CA
Posts: 9,957
Does ubuntu server (used as an example here) even have the ability to detect when it is idle? In the windows version, Sage does not put the computer to sleep - that's all on windows to do that. All Sage does is tell windows when it needs the computer to wake up, and tell windows when it cannot go to sleep.

I'm thinking the furthest we might want Sage to do on Linux is to perhaps write a simple file (or environment variable) with it's power wishes, and an external cron launched script might be able to read that file (or environment variable) to determine if it can sleep, and until when, and utilize rtcwake to do so. Doing it this way would then allow the script to be modified as wished to check other things before putting the system to sleep.

Code:
SAGEPOWER=WAKE_AT_UTC mm-dd-yyyy hh:mm:ss
Code:
SAGEPOWER=KEEP_AWAKE
Sage already runs a process continuously to determine if it can sleep and when it should wake, so adding this simple output of that value shouldn't be too difficult.
__________________
Buy Fuzzy a beer! (Fuzzy likes beer)

unRAID Server: i7-6700, 32GB RAM, Dual 128GB SSD cache and 13TB pool, with SageTVv9, openDCT, Logitech Media Server and Plex Media Server each in Dockers.
Sources: HRHR Prime with Charter CableCard. HDHR-US for OTA.
Primary Client: HD-300 through XBoxOne in Living Room, Samsung HLT-6189S
Other Clients: Mi Box in Master Bedroom, HD-200 in kids room
Reply With Quote
  #4  
Old 07-22-2016, 10:56 AM
SomeWhatLost's Avatar
SomeWhatLost SomeWhatLost is offline
Sage Expert
 
Join Date: Jan 2009
Location: earth
Posts: 532
I have a bit of a philosophical question, but with modern CPU's and their power efficiency out of the box, plus the fact that they adjust their clock to fit the load/etc, is "sleep" still a big deal?
obviously "sleeping" is still better than being awake, but is it really that much better than idling these days?
just curious really... anyone do any measurements with a kill-o-watt or anything?
__________________
NOTE: As one wise professional something once stated, I am ignorant & childish, with a mindset comparable to 9/11 troofers and wackjob conspiracy theorists. so don't take anything I say as advice...
Reply With Quote
  #5  
Old 07-22-2016, 01:08 PM
Taddeusz Taddeusz is offline
SageTVaholic
 
Join Date: Nov 2004
Location: Yukon, OK
Posts: 3,919
Unless you're system is running full tilt all the time, which is highly unlikely, it's like running a 100-150W lightbulb 24/7. Of course that is highly dependent on your components and how many hard drives you have.
__________________
Server: i5 8400, ASUS Prime H370M-Plus/CSM, 16GB RAM, 15TB drive array + 500GB cache, 2 HDHR's, SageTV 9, unRAID 6.6.3
Client 1: HD300 (latest FW), HDMI to an Insignia 65" 1080p LCD and optical SPDIF to a Sony Receiver
Client 2: HD200 (latest FW), HDMI to an Insignia NS-LCD42HD-09 1080p LCD
Reply With Quote
  #6  
Old 07-22-2016, 02:03 PM
EnterNoEscape's Avatar
EnterNoEscape EnterNoEscape is offline
SageTVaholic
 
Join Date: Jun 2010
Location: Harrisburg, PA
Posts: 2,657
I did look into this last year for OpenDCT and we don't support it there because all of the suggestions I found involved using scripts to tell the program what's going on with the system and a utility to tell the computer when to wake back up. There's comments in the code on how we could implement it, but it felt too hacky for my taste. I was planning on contributing whatever I did there to the SageTV project too, but like I said, it never panned out.
__________________
SageTV v9 Server: ASRock Z97 Extreme4, Intel i7-4790K @ 4.4Ghz, 32GB RAM, 6x 3TB 7200rpm HD, 2x 5TB 7200rpm HD, 2x 6TB 7200rpm HD, 4x 256GB SSD, 4x 500GB SSD, unRAID Pro 6.7.2 (Dual Parity + SSD Cache).
Capture: 1x Ceton InfiniTV 4 (ClearQAM), 2x Ceton InfiniTV 6, 1x BM1000-HDMI, 1x BM3500-HDMI.

Clients: 1x HD300 (Living Room), 1x HD200 (Master Bedroom).
Software: OpenDCT :: WMC Live TV Tuner :: Schedules Direct EPG
Reply With Quote
  #7  
Old 07-22-2016, 02:23 PM
KryptoNyte's Avatar
KryptoNyte KryptoNyte is offline
SageTVaholic
 
Join Date: Dec 2006
Posts: 2,754
Quote:
Originally Posted by SomeWhatLost View Post
I have a bit of a philosophical question, but with modern CPU's and their power efficiency out of the box, plus the fact that they adjust their clock to fit the load/etc, is "sleep" still a big deal?
obviously "sleeping" is still better than being awake, but is it really that much better than idling these days?
just curious really... anyone do any measurements with a kill-o-watt or anything?
I'm at around 150 watts with my SageTV server in its lowest power state (when not in sleep). It's on a second floor office in my home, and the central AC unit can barely get cool air to this room to begin with. For me, this is the difference between sitting in a 75 degree office (in sleep) or an 82 degree office (sleep disabled) over the course of a nasty hot day, and let's face, there is no shortage of nasty hot days.

In the winter time, I'm happy to leave it running.
Reply With Quote
  #8  
Old 07-22-2016, 02:42 PM
SomeWhatLost's Avatar
SomeWhatLost SomeWhatLost is offline
Sage Expert
 
Join Date: Jan 2009
Location: earth
Posts: 532
thanks for the replies, I was just curious, I though idle would be a bit (ie much) less power... especially since the drives can sleep/spin down independently of the computer...
__________________
NOTE: As one wise professional something once stated, I am ignorant & childish, with a mindset comparable to 9/11 troofers and wackjob conspiracy theorists. so don't take anything I say as advice...
Reply With Quote
  #9  
Old 07-22-2016, 04:53 PM
Fuzzy's Avatar
Fuzzy Fuzzy is offline
SageTVaholic
 
Join Date: Sep 2005
Location: Jurupa Valley, CA
Posts: 9,957
a typical (low end) 600W computer power supply is likely to burn 40-60W or so on it's own when turned on, because they are designed for peak efficiency at about 50% load, not 0%. Going to S3 sleep and running just the standby portion of the power supply is a pretty hefty savings, even if the CPU itself is only drawing 10-15W at idle, from the wall it could be pulling 80 easily.
__________________
Buy Fuzzy a beer! (Fuzzy likes beer)

unRAID Server: i7-6700, 32GB RAM, Dual 128GB SSD cache and 13TB pool, with SageTVv9, openDCT, Logitech Media Server and Plex Media Server each in Dockers.
Sources: HRHR Prime with Charter CableCard. HDHR-US for OTA.
Primary Client: HD-300 through XBoxOne in Living Room, Samsung HLT-6189S
Other Clients: Mi Box in Master Bedroom, HD-200 in kids room
Reply With Quote
  #10  
Old 07-22-2016, 05:06 PM
SomeWhatLost's Avatar
SomeWhatLost SomeWhatLost is offline
Sage Expert
 
Join Date: Jan 2009
Location: earth
Posts: 532
that seems like a crappy power supply design... but I guess you are right...
I just checked my Sage server (no current recordings going on), it is at 120W with the occasional spike to 150W...
of course it is also my unraid server, (all drives are currently spun up for some reason? except for the 2 sage recording drives...), a windows VM running a batch VIDEO_TS -> MKV conversion on all my dvd's, and a few other things going on...
but average CPU load is <20% (although cores 5 & 6 spike to about 50%, they are the windows VM) so its technically mostly idle... 120W is more then I thought it would be at idle oh well... at least I eliminated 2 other boxes doing this VM thing, so I hope its a net gain (well power loss?) over all...
__________________
NOTE: As one wise professional something once stated, I am ignorant & childish, with a mindset comparable to 9/11 troofers and wackjob conspiracy theorists. so don't take anything I say as advice...
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Linux: Sleep/Wake chairmanmao SageTV Github Development 1 03-14-2016 12:46 PM
spinning wheel on wake from sleep sflamm Phoenix 0 07-27-2012 08:40 AM
Wake from sleep to record andyvr4 SageTV Linux 2 03-23-2011 07:07 PM
Windows 7 wake from S3 sleep and record jimbo67 SageTV Beta Test Software 13 10-06-2010 04:37 PM
Ctrl-z to sleep, what to wake? Todd33 SageTV Beta Test Software 15 04-02-2004 12:28 PM


All times are GMT -6. The time now is 02:11 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.