bubbaQ Posted June 24, 2009 Share Posted June 24, 2009 Install and use s2ram instead of using "echo mem > /sys/power/state" Quote Link to comment
WeeboTech Posted June 24, 2009 Share Posted June 24, 2009 I do not get the screen back; this means: the box is alive, I can telnet to it, but the physical monitor does not show the console anymore. Any hints how to solve this? Sometimes there is a bios option to re-initialize the video bios after returning from sleep. You can check your bios and toggle the option to see if this helps. Quote Link to comment
kricker Posted June 24, 2009 Share Posted June 24, 2009 Install and use s2ram instead of using "echo mem > /sys/power/state" Sorry to be such a noob, but which version of s2ram should I get. I understand unRAID is built off Slackware, but I don't see that listed on the s2ram page. I saw a mention from a forum post somewhere that they got s2ram from slacky.eu. Unfortunately, that page is in Italian. EDIT: Okay I searched for the "Suspend" package on the slacky.eu page and it led me to http://suspend.sourceforge.net/. Is that the correct package? I'm off to go read up on how to install it now. EDIT2: Okay so I renamed suspend-0.8.tar.gz (from the sourceforge link above) to suspend-0.8.tgz and from /boot I executed: installpkg suspend-0.8.tgz Then I tried to execute: s2ram and got: s2ram: command not found I'm guessing it's either the wrong package or I did not install it properly. As a side note it appears there are no "removepkg" or "pkgtool" commands available. Quote Link to comment
bubbaQ Posted June 24, 2009 Share Posted June 24, 2009 Okay so I renamed suspend-0.8.tar.gz Nooooo...... There is no package for s2ram.... what you downloaded was the source code. You have to compile it.... and for that you need a dev system, or at least a BUNCH of packages (and more than 512MB RAM if doing it under unRAID) in order to compile source. Quote Link to comment
kricker Posted June 24, 2009 Share Posted June 24, 2009 Okay so I renamed suspend-0.8.tar.gz Nooooo...... There is no package for s2ram.... what you downloaded was the source code. You have to compile it.... and for that you need a dev system, or at least a BUNCH of packages (and more than 512MB RAM if doing it under unRAID) in order to compile source. After looking thru the file I thought it might be source code, but I wasn't sure since my knowledge of Linux is still very minimal. Oh well. I guess I'll just sit back and wait a little longer. Thanks for the input. Quote Link to comment
Guzzi Posted June 24, 2009 Share Posted June 24, 2009 Install and use s2ram instead of using "echo mem > /sys/power/state" Didn't find an installable s2ram - bit I found and installed acpitool - usind acpitool -s (found that somewhere else here in the forum). Is this the same as s2ram? Package installed: acpitool-0.4.7-i486-1goa The behaviour doesn't change, same like using the echo command Thanks, Guzzi Quote Link to comment
Guzzi Posted June 24, 2009 Share Posted June 24, 2009 I do not get the screen back; this means: the box is alive, I can telnet to it, but the physical monitor does not show the console anymore. Any hints how to solve this? Sometimes there is a bios option to re-initialize the video bios after returning from sleep. You can check your bios and toggle the option to see if this helps. No, there is no such option - checked this before posting here... Quote Link to comment
kricker Posted June 24, 2009 Share Posted June 24, 2009 ...acpitool-0.4.7-i486-1goa You got the link to that? Quote Link to comment
bubbaQ Posted June 25, 2009 Share Posted June 25, 2009 Is this the same as s2ram? No. s2ram has custom parameters for hundreds of mobos built into it, as well as additional command line parameters for special handling of ACPI and video quirks of a mobo. Quote Link to comment
Guzzi Posted June 25, 2009 Share Posted June 25, 2009 Is this the same as s2ram? No. s2ram has custom parameters for hundreds of mobos built into it, as well as additional command line parameters for special handling of ACPI and video quirks of a mobo. ok, understand - so this could help reinitializing the videocard for display. So I will wait if someone can compile a package for unraid - as I understood this is currently not available. @cricker: No, but google for it, can be found quickly (that's the way I did it) Quote Link to comment
Guzzi Posted July 11, 2009 Share Posted July 11, 2009 Here's an updated version -- this one you'd have to background from the go script rather than cron-launch. Hi, I modified the script to check if there is any htpc left running and this works fine. I inserted commands in the go script - this blocks my console. So: How do I "background" it ("launch as separate script in background"?) to keep my console free? Sorry for the silly question, but I am completely unexperienced with shell scripts... tnx, Guzzi Quote Link to comment
Joe L. Posted July 11, 2009 Share Posted July 11, 2009 Here's an updated version -- this one you'd have to background from the go script rather than cron-launch. Hi, I modified the script to check if there is any htpc left running and this works fine. I inserted commands in the go script - this blocks my console. So: How do I "background" it ("launch as separate script in background"?) to keep my console free? Sorry for the silly question, but I am completely unexperienced with shell scripts... tnx, Guzzi nohup your_script_name & nohup allows it to keep running after you log off the console, the "&" puts it in the background. As an alternative, you can do this: cd folder_that_has_your_script echo "your_script_name" | at now + 1 minute Joe L. Quote Link to comment
Guzzi Posted July 11, 2009 Share Posted July 11, 2009 Tnx Joe for the quick answer - will give it a try... Quote Link to comment
agw Posted July 26, 2009 Share Posted July 26, 2009 OK - I'm able to put my server to sleep using the: echo 3 > /proc/acpi/sleep command. Wakes up via magic packet. So far, so good. I've fiddled around with my go script and tried to implement OMV's script to force sleep after a set period of drives being spun down. This exercise just served to reinforce how little I really know about linux, scripts, etc. Anybody that has this working successfully willing to share what exactly is in their go script and, if there is a separate script for OMVs routine (or similar), how that is generated, where it is stored, etc? Many (many) thanks in advance! Quote Link to comment
kricker Posted July 26, 2009 Share Posted July 26, 2009 OK - I'm able to put my server to sleep using the: echo 3 > /proc/acpi/sleep Is that the actual command you typed? I've tried all sorts of commands that looked similar, but that exact one doesn't look familiar. Which build of unRAID did you use that with, and do you have and mods to it? Quote Link to comment
agw Posted July 26, 2009 Share Posted July 26, 2009 OK - I'm able to put my server to sleep using the: echo 3 > /proc/acpi/sleep Is that the actual command you typed? I've tried all sorts of commands that looked similar, but that exact one doesn't look familiar. Which build of unRAID did you use that with, and do you have and mods to it? Yes, if I telnet into the tower and type: echo 3 > /proc/acpi/sleep my machine goes to sleep. Works very well, actually. I gleaned this command from this thread. I'm not sure WHY it works, of course - which is what makes everything so frustrating. I do try to understand things as I try to implement them, so that I am learning as opposed to just typing. But I haven't even been able to decipher the first part of this: 'echo 3' ! Anyway, using unRAID 4.4 on a Foxconn A7GM-S motherboard. Quote Link to comment
res0nat0r Posted July 26, 2009 Share Posted July 26, 2009 This link should help: http://lxr.linux.no/linux+v2.6.30/Documentation/power/states.txt Basically you are telling the kernel to enter state "3", which is defined in the above document, hope this helps. Quote Link to comment
agw Posted July 26, 2009 Share Posted July 26, 2009 That does help a bit. Essentially you are using the 'echo' command to "apply" a value of 3 to /proc/acpi/sleep . . . I guess. What I've done so far is taken OMV's updated bash script that is designed to suspend the machine after a preset period of spindown time, and created a file called s3.sh, using wordpad, that contains OMV's script. Then I try to call that file from the go script using nohup, but it doesn't work. I get: "No such file or directory". I suspect that I'm missing something very basic in the process of creating a useable script file. Quote Link to comment
dlmh Posted August 30, 2009 Share Posted August 30, 2009 That does help a bit. Essentially you are using the 'echo' command to "apply" a value of 3 to /proc/acpi/sleep . . . I guess. What I've done so far is taken OMV's updated bash script that is designed to suspend the machine after a preset period of spindown time, and created a file called s3.sh, using wordpad, that contains OMV's script. Then I try to call that file from the go script using nohup, but it doesn't work. I get: "No such file or directory". I suspect that I'm missing something very basic in the process of creating a useable script file. You should make the script executable: chmod +x [filename] . Quote Link to comment
Joe L. Posted August 30, 2009 Share Posted August 30, 2009 I suspect that I'm missing something very basic in the process of creating a useable script file. When the "go" script is being run, the current working directory is probably "/" and the file you are trying to invoke is not in the search path. Try using either a full path to the script nohup /boot/whatever/s3.sh & or change directory to it first, and then use "nohup ./s3.sh" cd /boot/whatever nohup ./s3.sh & Quote Link to comment
jimwhite Posted August 31, 2009 Share Posted August 31, 2009 Is the current directory not on the search path in Linux? Quote Link to comment
Joe L. Posted August 31, 2009 Share Posted August 31, 2009 Is the current directory not on the search path in Linux? Not normally, at least not before /etc/profile is run, and usually never for the "root" user to prevent abuse (although Tom has edited /etc/profile to add it, even for root). Since no login has occurred when the "go" script is being invoked, it is not using /etc/profile at all. Quote Link to comment
jimwhite Posted August 31, 2009 Share Posted August 31, 2009 Thanks.... that clears up some "mysteries" for me Quote Link to comment
agw Posted September 14, 2009 Share Posted September 14, 2009 OK - it's been a long and frustrating effort, but I've finally got unRaid sending me email alerts if the system goes offline. AND . . . it's reliably sleeping after spindown and waking up via magic packet! I consider these two functions to be key to any respectable home server system so I really wanted to get both working. After it was working, the next challenge was making the WOL function a little more wife friendly. She couldn't be expected to jump through many hoops to wake the server up if she needed to access her files from her laptop. I found a windows command line tool called wolcmd that works great from a .bat file to send the magic packet. http://www.depicus.com/wake-on-lan/wake-on-lan-cmd.aspx Instructions for use are on the site. Basically the .bat file is a two-liner (could be a one-liner probably), first change to the directory where wolcmd.exe is stored, then call it along with your server mac address, ip address, and subnet mask. Pretty straighforward. Now I have an icon on the wife's laptop called "Wake Server" that she can just double-click if the server is not online. I hope this might help someone. I'll see if I can add a link to the wiki for the wolcmd tool. agw Quote Link to comment
flambot Posted September 15, 2009 Share Posted September 15, 2009 OK - it's been a long and frustrating effort, but I've finally got unRaid sending me email alerts if the system goes offline. AND . . . it's reliably sleeping after spindown and waking up via magic packet! I consider these two functions to be key to any respectable home server system so I really wanted to get both working. After it was working, the next challenge was making the WOL function a little more wife friendly. She couldn't be expected to jump through many hoops to wake the server up if she needed to access her files from her laptop. I found a windows command line tool called wolcmd that works great from a .bat file to send the magic packet. http://www.depicus.com/wake-on-lan/wake-on-lan-cmd.aspx Instructions for use are on the site. Basically the .bat file is a two-liner (could be a one-liner probably), first change to the directory where wolcmd.exe is stored, then call it along with your server mac address, ip address, and subnet mask. Pretty straighforward. Now I have an icon on the wife's laptop called "Wake Server" that she can just double-click if the server is not online. I hope this might help someone. I'll see if I can add a link to the wiki for the wolcmd tool. agw Hey congrats on the S3 mode. This is something I would like to be able to achieve. Is it possible you could detail exactly how you achieved this? Do all the drives spin up when you wake it up? Can a magic packet be sent by an xbox (Original using xbmc)?? Appreciate any help and thx. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.