Powerdown package for unRAID v5 and v6 (DEPRECATED)


dlandon

Recommended Posts

Hi,

 

just wanted to ask if I can safely remove the powerdown folder under /boot/config/plugins after upgrading to 6.2

That folder wasn't removed by the automatic uninstall after upgrading to v6.2

Are there any other files from the powerdown plugin that possibly didn't get deleted?

 

Thanks for your time supporting and creating this great plugin.

 

Yes. It can be removed.

Link to comment
  • Replies 678
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

After much consideration, I have updated the powerdown plugin one more time so it will install on 6.2.  The builtin powerdown is a lot less robust than I had anticipated.  I was struggling to get a clean shutdown with the builtin powerdown on 6.2, I couldn't do a command line reboot, the Ctrl-Alt-Del and just about all other Linux shutdown commands bypassed the builtin powerdown resulting in an unclean shutdown, etc.  I did a little testing with 6.2 and the powerdown appears to work ok.  A lot better than the built in powerdown for sure.

 

The caveats:

- The plugin will not load once 6.3 is available.

- It can only be loaded by the link in the OP.  It will not show up in CA in a new search.  It will show up as a previous app that can be re-installed.

- FCP will give you a warning about the plugin being incompatible.

- Install at your own risk.  There may be issues.

- I won't offer support as it will be going away when 6.3 is released.

 

I also updated the Tips and Tweaks plugin to remove the powerdown enhancements.  It gets in the way of the powerdown plugin.

 

I believe LT understands the powerdown issues and intends to address these issues.

Link to comment

After much consideration, I have updated the powerdown plugin one more time so it will install on 6.2.  The builtin powerdown is a lot less robust than I had anticipated.  I was struggling to get a clean shutdown with the builtin powerdown on 6.2, I couldn't do a command line reboot, the Ctrl-Alt-Del and just about all other Linux shutdown commands bypassed the builtin powerdown resulting in an unclean shutdown, etc.  I did a little testing with 6.2 and the powerdown appears to work ok.  A lot better than the built in powerdown for sure.

 

The caveats:

- The plugin will not load once 6.3 is available.

- It can only be loaded by the link in the OP.  It will not show up in CA.

- FCP will give you a warning about the plugin being incompatible.

- Install at your own risk.  There may be issues.

- I won't offer support as it will be going away when 6.3 is released.

 

I also updated the Tips and Tweaks plugin to remove the powerdown enhancements.  It gets in the way of the powerdown plugin.

 

I believe LT understands the powerdown issues and intends to address these issues.

It'll still show up within CA's previous apps section (listed as being incompatible since you're not updating the xml file) but will install fine.
Link to comment

After much consideration, I have updated the powerdown plugin one more time so it will install on 6.2.  The builtin powerdown is a lot less robust than I had anticipated.  I was struggling to get a clean shutdown with the builtin powerdown on 6.2, I couldn't do a command line reboot, the Ctrl-Alt-Del and just about all other Linux shutdown commands bypassed the builtin powerdown resulting in an unclean shutdown, etc.  I did a little testing with 6.2 and the powerdown appears to work ok.  A lot better than the built in powerdown for sure.

 

The caveats:

- The plugin will not load once 6.3 is available.

- It can only be loaded by the link in the OP.  It will not show up in CA.

- FCP will give you a warning about the plugin being incompatible.

- Install at your own risk.  There may be issues.

- I won't offer support as it will be going away when 6.3 is released.

 

I also updated the Tips and Tweaks plugin to remove the powerdown enhancements.  It gets in the way of the powerdown plugin.

 

I believe LT understands the powerdown issues and intends to address these issues.

It'll still show up within CA's previous apps section (listed as being incompatible since you're not updating the xml file) but will install fine.

 

I stand corrected.

Link to comment

Glad it's now "officially" back.  FWIW, it's been working fine for me all along.  I had it installed all along, and nothing ever resulted in it being uninstalled, so I had simply kept it.  ... and as long as it was working perfectly never saw a reason to uninstall it.

 

I certainly agree shutting down is a function that SHOULD be reliably part of the base OS ... hopefully Limetech will get this done before the next release.  I'm sure Dockers and VM's have appreciably complicated the process ... but even before those there have always been issues in the base OS with the power down process (this was of course the original genesis of the plugin).    Perhaps Tom can "steal" some of your code  8)

Link to comment

I did a little cleanup and added more logging and console messages to let you know what is happening.  If you watch the console during a shutdown, you will see the progression of the shutdown and the flow.

 

LT is welcome to use any of the code in the powerdown plugin, but there is nothing that special about what I've done.  I think the real issue is the order in which things are shut down and not using emhttp to do any of the shutdown processing.  Because I am not privy to the emhttp code, I have no idea what the shutdown flow is and have had to guess.  Because I have gotten a lot of feedback over the years on shutdown issues, I have refined the flow to accommodate plugins and other issues like users leaving a telnet or ssh terminal open.  I also believe LT is processing events out of order and causing issues shutting down VMs and Dockers.

 

Anyway, for the moment we shall see how it goes.

 

Anyone that "beat the system" by editing the plugin should go ahead and update to the latest version.  I did make some improvements.

Link to comment

I did a little cleanup...

 

I really appreciate your efforts on all the stuff you write but this one I think actually saved my sanity lol. Going to install it again now that its 6.2 friendly. During a period when I was struggling with unclean shutdowns, freezing reboots, this plug-in came along at about that same time and fixed it all for me. It was a godsend compared to a 26 hour parity check [each time, like it was running all the time lol for a while there] due to unclean shutdowns. Thanks again.

Link to comment

Thanks for bringing this plugin back!

 

My Windows VMs (Server 2016 & 10), RHEL 7 & Ubuntu Server 16 LTS all shutdown without issue, but the Ubuntu 16 LTS desktop install gets stuck since it's asking for user input (see attached screenshot). That may just be a config setting within the vanilla install, but I haven't looked into it much.

 

index.php?action=dlattach;topic=31735.0;attach=37282;image

 

Thanks again!

 

goodbye.png.a731687f2d933817a9eb14d09aa6e9d1.png

Link to comment

Sorry for this slightly OT post,

 

But I did use the K00.sh feature on shutdown, obviously I need to look for a way to change given the changes taking place.  My use case is for copying bz* files from /boot to the virtual drive I use to boot my Unraid-VM

 

I'd be grateful for any pointers or suggestions on how best to manage this going forward.

 

Only commands I need to run on shutdown are

 

cp /boot/bzroot /mnt/disks/UNRAID_VM/bzroot
cp /boot/bzimage /mnt/disks/UNRAID_VM/bzimage
cp /boot/bzroot-gui /mnt/disks/UNRAID_VM/bzroot-gui

Link to comment

Sorry for this slightly OT post,

 

But I did use the K00.sh feature on shutdown, obviously I need to look for a way to change given the changes taking place.  My use case is for copying bz* files from /boot to the virtual drive I use to boot my Unraid-VM

 

I'd be grateful for any pointers or suggestions on how best to manage this going forward.

 

Only commands I need to run on shutdown are

 

cp /boot/bzroot /mnt/disks/UNRAID_VM/bzroot
cp /boot/bzimage /mnt/disks/UNRAID_VM/bzimage
cp /boot/bzroot-gui /mnt/disks/UNRAID_VM/bzroot-gui

User Scripts plugin.
Link to comment

Sorry for this slightly OT post,

 

But I did use the K00.sh feature on shutdown, obviously I need to look for a way to change given the changes taking place.  My use case is for copying bz* files from /boot to the virtual drive I use to boot my Unraid-VM

 

I'd be grateful for any pointers or suggestions on how best to manage this going forward.

 

Only commands I need to run on shutdown are

 

cp /boot/bzroot /mnt/disks/UNRAID_VM/bzroot
cp /boot/bzimage /mnt/disks/UNRAID_VM/bzimage
cp /boot/bzroot-gui /mnt/disks/UNRAID_VM/bzroot-gui

User Scripts plugin.

 

I was already using that to do it manually by clicking on a user script I'd set up to do this......

 

Didn't realise I could select it to do so on array shutdown..

 

jiFfM.jpg

Link to comment

powerdown FTW !! I always used it in every one of my servers !!!! Don't let it die dlandon !!! :)

 

Equivalent functionality is working in 6.2.1.  LT is making a few adjustments.  The powerdown plugin is no longer needed.

 

I had strong doubts about this statement when you first deprecated the plugin; but the latest improvements within UnRAID ... and the likely changes as a result of your ongoing discussion with Tom r.e. "tweaking" the shutdown process sequencing .... have changed my mind => I agree it's no longer required as of 6.2.1, and will absolutely be obsolete by the next release.

 

It IS, however, still needed for those using 6.2 or earlier => so I hope it remains available for those folks.

 

 

Link to comment

powerdown FTW !! I always used it in every one of my servers !!!! Don't let it die dlandon !!! :)

 

Equivalent functionality is working in 6.2.1.  LT is making a few adjustments.  The powerdown plugin is no longer needed.

 

I had strong doubts about this statement when you first deprecated the plugin; but the latest improvements within UnRAID ... and the likely changes as a result of your ongoing discussion with Tom r.e. "tweaking" the shutdown process sequencing .... have changed my mind => I agree it's no longer required as of 6.2.1, and will absolutely be obsolete by the next release.

 

It IS, however, still needed for those using 6.2 or earlier => so I hope it remains available for those folks.

 

Yes, Tom is getting it worked out and I am satisfied he is on task.  I am especially pleased with the implementation of the shutdown in 6.2.1.  The shutdown code in is a common shutdown routine (rc.local_shutdown) that is executed by rc.6 which is the Linux shutdown script.  This means any shutdown or restart initiation will execute this common code and shutdown the server properly.

 

The powerdown plugin will remain available for 6.2 and earlier versions.  At version 6.3 the plugin will no longer install.

Link to comment

The powerdown plugin is no longer needed.

I still don't understand how or where I would use this command:

xl shutdown -a

to shutdown all my running VMs (currently using the powerdown plugin / in a K0 file) when I use the GUI to stop the array. Does unRAID handle that in 6.2.1 now?

Link to comment
  • 2 weeks later...

The powerdown plugin is no longer needed.

I still don't understand how or where I would use this command:

xl shutdown -a

to shutdown all my running VMs (currently using the powerdown plugin / in a K0 file) when I use the GUI to stop the array. Does unRAID handle that in 6.2.1 now?

 

unRAID shuts down VMs and Dockers as part of the shutdown procedure.  You shouldn't need to do that in a K or S script.  If you do, the K and S script functionality can be handled in the User Scripts plugin here: http://lime-technology.com/forum/index.php?topic=49992.msg479657#msg479657

Link to comment

... I'm not sure everyone appreciates the difficulty in an app being backwards compatible, the testing to be sure an app works with all supported versions of unRAID, and the support when things don't work as expected.

 

Fully aware of how much time and effort it takes to develop, maintain and support.

 

I spend really a lot, I mean a LOT of my spare time in development of Dynamix and associated plugins at no additional cost to LT or their customers. Some things which may look simple to the end-user may take a huge amount of testing, tweaking, correcting and retesting (literally months) even before it hits public status.

 

Keeping up with bug reports and provide fixes in adequate time is another time consuming activity and not to be underestimated.

 

So yes, a thank you in words or otherwise once a while keeps all the community developers motivated.

 

Hadn't read it before .. but symphatize with it ! :)

Link to comment

unRAID shuts down VMs and Dockers as part of the shutdown procedure.  You shouldn't need to do that in a K or S script.  If you do, the K and S script functionality can be handled in the User Scripts plugin here: http://lime-technology.com/forum/index.php?topic=49992.msg479657#msg479657

 

There must have been something broken before, but unRAID did not/could not shutdown running VMs and would just power down causing unclean shutdowns. This appears to be fixed.

Link to comment
  • 2 weeks later...

unRAID shuts down VMs and Dockers as part of the shutdown procedure.  You shouldn't need to do that in a K or S script.  If you do, the K and S script functionality can be handled in the User Scripts plugin here: http://lime-technology.com/forum/index.php?topic=49992.msg479657#msg479657

 

There must have been something broken before, but unRAID did not/could not shutdown running VMs and would just power down causing unclean shutdowns. This appears to be fixed.

 

Agreed. Still unclean shutdowns. Im going to miss powerdown :(

Link to comment
  • 7 months later...

I see it's been a while since anyone has posted here and I guess I'm a bit behind but I don't like living on the bleeding edge.

So I've just upgraded to v6.2.4 from v6.1.9 and have a question about this Powerdown script.

I have been using it for years to power down my server at night with a cron script, below.

It still works without issue but not sure from what I read about going forward.

How do I change this to work with UnRaid v2 and v3 etc..

 

#Do Not Powerdown for Sun
# Daily automated powerdown at fixed time:
5 2 * * 1,2,3,4,5,6 /usr/local/sbin/powerdown &> /dev/null

# * * * * * command to be executed
# - - - - -
# | | | | |
# | | | | ----- Day of week (0 - 7) (Sunday=0 or 7)
# | | | ------- Month (1 - 12)
# | | --------- Day of month (1 - 31)
# | ----------- Hour (0 - 23)
# ------------- Minute (0 - 59)

 

Link to comment
8 minutes ago, Russ Uno said:

I see it's been a while since anyone has posted here and I guess I'm a bit behind but I don't like living on the bleeding edge.

So I've just upgraded to v6.2.4 from v6.1.9 and have a question about this Powerdown script.

I have been using it for years to power down my server at night with a cron script, below.

It still works without issue but not sure from what I read about going forward.

How do I change this to work with UnRaid v2 and v3 etc..

 


#Do Not Powerdown for Sun
# Daily automated powerdown at fixed time:
5 2 * * 1,2,3,4,5,6 /usr/local/sbin/powerdown &> /dev/null

# * * * * * command to be executed
# - - - - -
# | | | | |
# | | | | ----- Day of week (0 - 7) (Sunday=0 or 7)
# | | | ------- Month (1 - 12)
# | | --------- Day of month (1 - 31)
# | ----------- Hour (0 - 23)
# ------------- Minute (0 - 59)

 

This cron should still work since /usr/local/sbin/powerdown is still there as a script that invokes the builtin.

Link to comment

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.