Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

watching movie server went to sleep[SOLVED ]

Featured Replies

like the title writes i was watching a movie and server went sleep....

here is the s3.sh script...some ideas for the server not going into sleep while the drive still spinning?

 


#!/bin/bash

drives="/dev/sda /dev/sdb /dev/sdc dev/sdd dev/sde dev/sdh dev/sdg dev/sdf"
timeout=5


count=5
while [ 1 ]
do
 hdparm -C $drives | grep -q active
 if [ $? -eq 1 ]
 then
   count=$[$count-1]
 else
   count=$timeout
 fi
 if [ $count -le 0 ]
 then
   # Do pre-sleep activities
   sleep 5

   # Go to sleep
   echo 3 > /proc/acpi/sleep

   # Do post-sleep activities
   # Force a DHCP renewal (shouldn't be used for static-ip boxes)
   #/sbin/dhcpcd -n
   sleep 5

   count=$timeout
 fi
 # Wait a minute
 echo COUNT $count
 sleep 60
done

I'll bet the drive with the movie you were watching when it went to sleep was on

sdd, sde, sdg, sdh, or sdf.

 

You incorrectly defined the drives in your script.  You left off the leading "/" on many of them.

 

You have:

drives="/dev/sda  /dev/sdb  /dev/sdc  dev/sdd  dev/sde  dev/sdh  dev/sdg  dev/sdf"

 

You should have:

drives="/dev/sda  /dev/sdb  /dev/sdc  /dev/sdd /dev/sde  /dev/sdh  /dev/sdg  /dev/sdf"

  • Author

omg...i have overlooked the slash :-X

changed and reboot.......

Worked.. :-) Cheers!

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.