agw Posted September 15, 2009 Share Posted September 15, 2009 This is something I would like to be able to achieve. Is it possible you could detail exactly how you achieved this? When I get home this evening, I will try to put something together. To automate the sleep process, I essentially copied OMV's script (see beginning of this thread) verbatim and then made a couple of very minor edits. Do all the drives spin up when you wake it up? Yes. Can a magic packet be sent by an xbox (Original using xbmc)?? No idea. I'm far from an expert (and I don't own an xbox). Perhaps someone else will chime in. Ideally I'd like the machine to wake up whenever someone tries to browse to it or access it, but I'm not sure that's currently possible. May even be a motherboard restriction, not sure. Quote Link to comment
prostuff1 Posted September 15, 2009 Share Posted September 15, 2009 I did some quick searching on the modded xbox running xbmc and there does appear to be a little script that can be run to send the magic packet. Now, the problem i found is that the site that hosted that script is gone. So some more digging might be in order to find it. As for the browsing a share thing from a Windows machine, that i am not sure about. On a mac you can set up these things called Folder Actions that can be attached to folders. Do some google searching for 'Folder Actions Mac" to get an idea of what they do and maybe you can find something similar for the windows side of things. Quote Link to comment
kricker Posted September 15, 2009 Share Posted September 15, 2009 ...Can a magic packet be sent by an xbox (Original using xbmc)??...Take a look at this post here. Use the code posted there to create a WOL.py script. Edited it ad described in the post for your needs. You can then run that from XBMC a few ways; manually whenever you want to wake the NAS, you can link to it using an autoexec.py script which will run whenever XBMC is first launched, or edit the skins .xml file and add a second onclick action to the menu item that takes you to the media on the NAS <onclick>XBMC.RunScript(Q:\scripts\Wake\WOL.py)</onclick> Quote Link to comment
flambot Posted September 16, 2009 Share Posted September 16, 2009 Thx muchly for the comments. They should get me started. Pity all the drives spin up, but I guess this is what happens on a Windows machine as well?? If I think about it, I'm not sure I want all the drives to spin up (16 of them) just to save a few watts of power. I'm more worried about the long-term reliability of the HDD's - especially as that's were all the $ lay in the system Being able to shut the server down and start it up from the xbox would be good though. Thx again for the help. Quote Link to comment
agw Posted September 17, 2009 Share Posted September 17, 2009 Well, my box currently only has two drives in it - so for me 'all drives spinning up' just means that both spin up. Although I'm fairly certain that all of them would spin up regardless of how many were installed. Mine spends most of its time idle, and when it is online I have the drives set to spin for a minimum of one hour of no activity before they spin down - which seems like a reasonable compromise of energy saving vs drive wear. I'm using an 80+ power supply, integrated video and a 45W processor, and my machine still pulls about 70W idle with both drives spun down, so I really wanted the machine to sleep when it's not in use. BTW flambot - I haven't forgot about you, I'm still putting together my S3 / WOL step-by-step - but I've not had much time to piece it all together. I realize you may not even be that interested anymore, but I think it may still be good reference for others. I'm pretty green at all of this, so I'm even learning quite a bit as I re-visit everything. Quote Link to comment
WeeboTech Posted September 17, 2009 Share Posted September 17, 2009 I wonder if the drives would still spin up if you set power up in standby mode? I set this option on my WD Green drives. When the system is powered on the drives are in standby mode and do not spin up until the kernel activates them. Also, how fast does the server return from S3 to power on usable state? Quote Link to comment
kricker Posted September 17, 2009 Share Posted September 17, 2009 I wonder if the drives would still spin up if you set power up in standby mode?..Is this a drive option you are setting using a WD tool? Or a BIOS option you have? Quote Link to comment
WeeboTech Posted September 17, 2009 Share Posted September 17, 2009 I use hdparm. I have a script in this thread. http://lime-technology.com/forum/index.php?topic=2555.0 you would need to modify it to point to the hard drives you want to set via serial number. You can also set WD drives via a jumper. Quote Link to comment
flambot Posted September 17, 2009 Share Posted September 17, 2009 I looked up what "Powered up in standby" meant. Cool. This looks promising - as virtually all my drives are WD's (they will all be soon). If this is enabled, will the drives spin up automatically (after returning from a standby state) when they are asked to be a network task?, Or does some software thing have to take place after returning from standby to make the drives ready for use? Thx Quote Link to comment
WeeboTech Posted September 18, 2009 Share Posted September 18, 2009 If this is enabled, will the drives spin up automatically (after returning from a standby state) when they are asked to be a network task?, Or does some software thing have to take place after returning from standby to make the drives ready for use? I dunno, you will be the first to test! LOL! Quote Link to comment
flambot Posted September 18, 2009 Share Posted September 18, 2009 If this is enabled, will the drives spin up automatically (after returning from a standby state) when they are asked to be a network task?, Or does some software thing have to take place after returning from standby to make the drives ready for use? I dunno, you will be the first to test! LOL! Oh no... Quote Link to comment
bubbaQ Posted September 18, 2009 Share Posted September 18, 2009 With the WD drives set to power up in standby, they will remain spun-down when resuming from S3 suspend state. They will even remain spun down when you access them if what you access is already cached, such as a directory listing. They will spin up when you access then for any content that is not cached. Quote Link to comment
WeeboTech Posted September 18, 2009 Share Posted September 18, 2009 How long does it take to bring the machine up to an accessible point (login) from an S3 state? Quote Link to comment
agw Posted September 18, 2009 Share Posted September 18, 2009 How long does it take to bring the machine up to an accessible point (login) from an S3 state? From memory, I'm going to say 8-10 seconds or so? I definitely remember it being faster than a fresh boot. But again, I'm only running two drives, so not sure how the numbers might change for some of the large arrays that many are running. Of course, after several days of glorious S3 / WOL use - I dug back into this to write-up my FB,BB (For Beginners, By Beginners) Guide to S3 / WOL . . . and I somehow got things all goofed up. So, this weekend I get to wrestle with two things: 1. Server is no longer responding to magic packet. I'm hoping I just made a bad BIOS tweak - I don't remember doing that but I was in the BIOS the other day and it's plausible. 2. When it is sleeping and waking properly, I noticed that the server no longer negotiates a gigabit connection upon wake-up. It's 1000Mb/s off of cold-boot, but if I check it after wake from sleep, it seems to be coming back at 100Mb/s. It's onboard Realtek 8168b NIC, so I suspect a driver issue - which means I probably won't be able to do much about it other than hope a driver update in next unRAID release cleans it up. Or buy a NIC, but I'm inclined not to go that route if I can help it. AGW Quote Link to comment
flambot Posted September 18, 2009 Share Posted September 18, 2009 How long does it take to bring the machine up to an accessible point (login) from an S3 state? From memory, I'm going to say 8-10 seconds or so? I definitely remember it being faster than a fresh boot. But again, I'm only running two drives, so not sure how the numbers might change for some of the large arrays that many are running. Of course, after several days of glorious S3 / WOL use - I dug back into this to write-up my FB,BB (For Beginners, By Beginners) Guide to S3 / WOL . . . and I somehow got things all goofed up. So, this weekend I get to wrestle with two things: 1. Server is no longer responding to magic packet. I'm hoping I just made a bad BIOS tweak - I don't remember doing that but I was in the BIOS the other day and it's plausible. 2. When it is sleeping and waking properly, I noticed that the server no longer negotiates a gigabit connection upon wake-up. It's 1000Mb/s off of cold-boot, but if I check it after wake from sleep, it seems to be coming back at 100Mb/s. It's onboard Realtek 8168b NIC, so I suspect a driver issue - which means I probably won't be able to do much about it other than hope a driver update in next unRAID release cleans it up. Or buy a NIC, but I'm inclined not to go that route if I can help it. AGW AGW - Hope you get it sorted out. Thx BQ for your comments - very helpful. Quote Link to comment
ReneV Posted September 19, 2009 Share Posted September 19, 2009 2. When it is sleeping and waking properly, I noticed that the server no longer negotiates a gigabit connection upon wake-up. This seems to be a relatively common GNU/Linux issue. I saw it on one of my unRAID motherboards, too, when I had a quick look recently. The motherboard previously did service in a Ubuntu (2009.04) desktop, where it had the same problem. There's an easy fix that involves the kernel config files but I can't remember it off the top of my head, and I don't seem to have sent a tech note about it to myself. Google will sort you out. I'm fairly certain the fix will be distribution agnostic, [/ubuntu <something> on] which means that you can add "ubuntu" as a search term if you need to narrow down the search results and specifically target detailed instructions. [/ubuntu <something> off] Quote Link to comment
kricker Posted September 19, 2009 Share Posted September 19, 2009 As per bubbaq's earlier advice, I hooked up an old drive installed windows and set the NIC to WOL. It is working fine with windows XP. The strange thing though is that the NIC light still goes out while in standby. But, it does wake with a magic packet nicely. After confirming this, I rebooted into unRAID. I telnetted in and checked the NIC using "ethtool eth0". The NIC was set to "Wake-on: g": I stopped the RAID then executed the sleep command "echo 3 > /proc/acpi/sleep". The PC would not WOL at this point. I could still wake it with the keyboard. After I woke it using the keyboard I checked the NIC again. This time it said "Wake-on: d". I believe this means it was disabled. Did it get disabled before it went into sleep? Quote Link to comment
bubbaQ Posted September 19, 2009 Share Posted September 19, 2009 What kernel are you using? Quote Link to comment
kricker Posted September 19, 2009 Share Posted September 19, 2009 What kernel are you using? Whatever is in 4.5-beta6 Quote Link to comment
bubbaQ Posted September 19, 2009 Share Posted September 19, 2009 Post the output of "uname -a" Quote Link to comment
kricker Posted September 20, 2009 Share Posted September 20, 2009 Linux 2.6.29.1-unRAID. root@Tower:~# uname -a Linux Tower 2.6.29.1-unRAID #2 SMP Thu Apr 23 14:17:18 MDT 2009 i686 Intel(R) Pe ntium(R) 4 CPU 2.40GHz GenuineIntel GNU/Linux root@Tower:~# Quote Link to comment
bubbaQ Posted September 20, 2009 Share Posted September 20, 2009 I had a similar problem under 2.6.29.1 and I went to 2.6.29.6 and that fixed it. Quote Link to comment
kricker Posted September 20, 2009 Share Posted September 20, 2009 I had a similar problem under 2.6.29.1 and I went to 2.6.29.6 and that fixed it. uuuhmmm? Is that a compile yourself kinda thing? Quote Link to comment
BRiT Posted September 20, 2009 Share Posted September 20, 2009 I had a similar problem under 2.6.29.1 and I went to 2.6.29.6 and that fixed it. uuuhmmm? Is that a compile yourself kinda thing? Yes, exactly. Quote Link to comment
kricker Posted September 20, 2009 Share Posted September 20, 2009 Okay, I'm not quite there yet. Maybe if a new beta comes out it'll have that or newer kernel. 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.