Menu

Getting started: waiting for shut down time

Help
2014-03-27
2014-04-25
  • torbenamstrup

    torbenamstrup - 2014-03-27

    hiya, I´m trying to get the scheduler activated so that the nas shuts down when meeting the poweroff criteria set in the disc traffic and network traffic tabs. For some reason however the main schedule always lists a : "waiting for shut down time" message, and isn´t actually active.

    I´m running the newest dms

    Suggestions would be much appreciated. I have the feeling that I´m missing a basic setting somewhere..

    The following is set (rest is default):

    main schedule:
    enabled (no program list or commands are specified)

    poweroff settings tab:
    data traffic (enabled) using default settings 10mb/1min
    network traffic (enabled) using default settings 10mb/1min

    welcome tab
    current state: waiting for shut down time
    planned shut down: none planned

    Thanks a lot !

     
  • Renaud Métrich

    Renaud Métrich - 2014-03-27

    Hello,
    I guess you didn't specify any program in the Poweroff settings tab.
    The tool works by first reaching the program shutdown time, then analysing plugins (disk, network, etc) to derogate temporarily.
    For now it is not possible to shut down without any main program. This is intended use because otherwise the NAS may shutdown automatically just after boot, since likely there is no activity just after boot (e.g. no connection from clients, no network traffic, etc).

    If this is a requirement for you, please let me think about how to solve such issue.

     
  • torbenamstrup

    torbenamstrup - 2014-03-29

    ok, that makes sense!

    I´ll be using the APM with "download station" to shut down the NAS, when that particular program is idle.

    Let´s say that i wanted this schedule on 24/7 what would be the syntax for that ?. Also is there an example of the syntax that should be used to specifify a program in the program list ?. For instance I´m able to save the line: "Mon-Sun at 10:00, 11:00, 12:00" but it´s unclear how specify a program.

    Thanks a lot!

     
  • Renaud Métrich

    Renaud Métrich - 2014-03-29

    Hi,
    for now it is not possible to shut down upon a process being idle because it is not possible to know when such thing happens.
    In order to solve your problem, assuming the download station doesn't enable upload once a download is finished, you may do the following:
    - Program shutdown at an arbitrary time (e.g. DAILY at 12:00)
    - Use "Network" plugin to set up a threshold (e.g. 1MB/10min)

    This will result in the NAS entering shut down state every day at 12:00. But the NAS will only shut down if there is less than 1MB of network traffic (up+down) over 10 minutes.
    If your download station becomes idle and you didn't enable upload of finished items (the default case I believe), the NAS will shut down after a maximum of 10 minutes after the last item finished.
    Using a long period (10min) is preferred other a short period (e.g. 1min, the minimum), because if using 1min and the downloads become stale during 1min, the NAS will shut down.
    Here, with 10min, you may suffer some stale periods without having the NAS being shut down.

     
  • torbenamstrup

    torbenamstrup - 2014-03-29

    Hi Renaud, thanks for all your help, and the insight into what´s possible, and what´s not. I got it to work using your comments above, and are now experimenting with the different settings. yay!

     
  • Cade

    Cade - 2014-04-24

    Hi Renaud, firstly thanks for making such a wonderful addon.

    I'm actually after the addon to monitor the disk and/or network traffic for shutdown time without any existing time schedule.

    Basically I have a DS1813 for home use, which I sometimes use regularly, but can also go days without using it.
    As such I wanted to have a 240 minute time interval for disk traffic less than 50MB with the number of checkpoints set to 60. The times I use it is random and as such I don't think any schedule would be appropriate

    I did manage to get it working with this setup after modifying the Scheduler.pm (commenting out lines 119 -> 156), however it would be great if this could be kept as the normal behaviour, or perhaps an extra checkbox in the scheduling to allow this.

    I can understand the concerns of the DS shuting down if the time interval is too low as I actually had this happen when I was playing around with an older version (2.3.8) and editing it to get the above functionality to work.
    After a bit of playing around, I managed to disable Advanced Power Manager, allowing me to fix my settings, etc. Perhaps you could include this procedure incase people have similar issues (in the event you add this functionality)

    1) Shutdown the DS
    2) Remove the disk where the Advanced Power Manager was installed
    3) Power on the DS
    4) Once powered on, SSH to the DS and remove the following file: rm /var/packages/AdvancedPowerManager/enabled
    5) Shutdown the DS
    6) Re-insert the disk removed in step 2
    7) Power on

    I guess you would also need to remove the config file to prevent it shutting down when it is re-enabled to re-configure, but I'm sure you would have a far better idea of that than me.

    Anyway, if this functionality could be added in future releases, then that would be great.
    Either way, thanks very much for your great work in providing this package.

     
  • Renaud Métrich

    Renaud Métrich - 2014-04-24

    Hi Cade,

    please consider using the following workaround for now. I plan to integrate such feature after 3.2 which will come quickly out.
    - In shutdown tab, shut down every hour or so:
    DAILY at 08:00,09:00, ...

    This will make AdvPowerMgr enter shutdown procedure rapidly (if using 240 minutes as interval for Disk activity, even immediately).

     
  • Cade

    Cade - 2014-04-25

    Hi Renaud,

    Thanks for the quick reply and great suggestion.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.