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.

New powerdown script needed for 5.0 unRAID

Featured Replies

oh is rc.unraid not a part of unraid itself?  My misunderstanding.

 

Yes it is but powerdown appears to be replacing it.  I think I am wrong about the rcdstock file.  It is installed with the powerdown package.

 

I've been working on this too long and I've gotten myself very confused about the stock and powerdown rc.unRAID.

 

I guess I need to let the author of powerdown take a look.

  • Replies 149
  • Views 39k
  • Created
  • Last Reply

I'm not the author but I did the change to include the rcdstock file. It contains all rcd scripts that were present on my 5.0.2 stock system. The files listed will not be called with a stop command when powerdown is requested. rc.unraid needs to be in that list, as calling it would cause an endless loop. powerdown is calling rc.unraid stop already.

 

Long Story:

Starting with unRAID 5.0 I had the problem that powerdown 1.0.2 as it is in unmenu was no longer working for me. I found it was because plugins were still running when powerdown was issued. Most plugins have their own rcd script with a stop command to stop the plugin. So I thought why not call the stop command for all rcd scripts? Problem were the stock files, that should not be called with stop. So I made a list and changed the powerdown plugin to call all rcd scripts that are not in rcdstock with an stop command. After this change powerdown did work for me again.

 

It might be, that in the new version of unRAID there are different stock rcd scripts than in 5.02, so the list will need to be adapted. I don't have the time to look at it however ATM.

 

SlrG

I'm not the author but I did the change to include the rcdstock file. It contains all rcd scripts that were present on my 5.0.2 stock system. The files listed will not be called with a stop command when powerdown is requested. rc.unraid needs to be in that list, as calling it would cause an endless loop. powerdown is calling rc.unraid stop already.

 

Long Story:

Starting with unRAID 5.0 I had the problem that powerdown 1.0.2 as it is in unmenu was no longer working for me. I found it was because plugins were still running when powerdown was issued. Most plugins have their own rcd script with a stop command to stop the plugin. So I thought why not call the stop command for all rcd scripts? Problem were the stock files, that should not be called with stop. So I made a list and changed the powerdown plugin to call all rcd scripts that are not in rcdstock with an stop command. After this change powerdown did work for me again.

 

It might be, that in the new version of unRAID there are different stock rcd scripts than in 5.02, so the list will need to be adapted. I don't have the time to look at it however ATM.

 

SlrG

 

Thanks for the info - very helpful.  I can spend a little time with this and see if I can figure it out.  I think I understand what you are saying.

 

I got very confused because it looks like Dynamix puts its own version of rc.unRAID in the /etc/rc.d.  I think that this can potentially cause some issues of who gets there fist and installs their version.

 

I'll start with a bare metal unRAID and see if I can figure out what is happening.

 

I notice that the official version is still 1.02 hosted at Google Code.  Is this being maintained/updated there any longer?

I have it installed, and don't get any issues , it's stopping all plugin and do a nice shutdown, and I have not needed to modify it.

 

//Peter

+1

I have it installed, and don't get any issues , it's stopping all plugin and do a nice shutdown, and I have not needed to modify it.

 

//Peter

+1

 

unRAID v6 Beta3?

Not tested yet....

 

 

Sent from my iPhone using Tapatalk 2

 

v6 is where I am having the problem.

 

The attached picture shows where it stops.

Miami-20140203-02708.jpg.e6f0314be338cbe740b7c03b96565f14.jpg

Hmm... the multiple calls to rc.unraid stop seem to indicate that it is not part of the rcdstock file. Could you check and add it if it is missing?

Hmm... the multiple calls to rc.unraid stop seem to indicate that it is not part of the rcdstock file. Could you check and add it if it is missing?

 

It is not missing.  I added some other files in the stock configuration.  Here is what I have.

#stock powerdown protected rc.d scripts
rc.0
rc.4
rc.6
rc.K
rc.M
rc.S
rc.acpid
rc.atalk
rc.avahidaemon
rc.avahidnsconfd
rc.fuse
rc.ifplugd
rc.inet1
rc.inet1.conf
rc.inet2
rc.inetd
rc.ip_forward
rc.libvirt
rc.local
rc.loop
rc.messagebus
rc.nfsd
rc.ntpd
rc.rpc
rc.saslauthd
rc.serial
rc.sshd
rc.samba
rc.syslog
rc.sysvinit
rc.udev
rc.xen-watchdog
rc.xencommons
rc.xend
rc.xenddomains
#additional powerdown protected rc.d scripts
rcdstock
rc.apcupsd
rc.local_shutdown
rc.unRAID

 

I'd be happy to do some more troubleshooting if you have any suggestions.

  • Author

rc.unRAID is the part of the powerdown package. I initially wrote it.

There is a slight bug in that it calls itself a second time. I was working with someone for repairs and he said he did not have time to assist.

I became busy myself. I could post a diff if interested. I was hoping to open it up more on google code and/or github.

My job is absorbing all of my time right now.

rc.unRAID is the part of the powerdown package. I initially wrote it.

There is a slight bug in that it calls itself a second time. I was working with someone for repairs and he said he did not have time to assist.

I became busy myself. I could post a diff if interested. I was hoping to open it up more on google code and/or github.

My job is absorbing all of my time right now.

 

I'd be happy to have a go at it.

rc.unRAID is the part of the powerdown package. I initially wrote it.

There is a slight bug in that it calls itself a second time. I was working with someone for repairs and he said he did not have time to assist.

I became busy myself. I could post a diff if interested. I was hoping to open it up more on google code and/or github.

My job is absorbing all of my time right now.

 

I'd be happy to have a go at it.

 

Ok, I had a go at it and have fixed the following:

- Multiple executions of "rc.unRAID stop".

- Hang ups when shutting down.

- Cleaned up some minor warnings that could be a concern to inexperienced users.

 

I would like anyone willing to beta test this for me to give it a try.  I have tested it on unRAID v5 and v6.  My test server is a very minimal system with only a few plugins.  Both work as expected.

 

The issue of the lock ups depended on how clean the plugins shut themselves down on shutdown.  Basically the rc.unRAID was trying to shut down active pids on the array when there potentially weren't any to shut down.  When plugins were not shutting themselves down properly, they were active on the array and the routine to shut them down would succeed.  I believe this is why some had issues and others had no problems at all.

 

Once I get feedback that the powerdown is working properly in all versions of unRAID, I will commit it to WeeboTech's Google Code repository.  WeeboTech has graciously allowed me ownership privileges so I can upload my modifications.

 

Let me know that is working for you so I can feel confident that I'm not going to cause anyone any issues when it goes "live".

powerdown-1.05-noarch-unRAID.zip

If this version are OK, Then we can hope Tom add this as a part of the next beta! Are Tom aware if this add on?

 

It looks like wee all need this functionality  ;)

 

//Peter

 

 

 

If this version are OK, Then we can hope Tom add this as a part of the next beta! Are Tom aware if this add on?

 

It looks like wee all need this functionality  ;)

 

//Peter

 

I'm waitimg for feedback to see if it is working for others before I post it to the repository.

 

This is an add on and not a part of unRAID.

I've created a simple plugin that will install the new version of the powerdown package.  It is attached.  Just put this file in the /boot/config/plugins.

 

Either reboot your system or do the following to install:

telnet to your unRAID

cd /boot/config/plugins

installplg powerdown.plg

 

For those of you wanting to include the new version of powerdown in your plugin change the powerdown download to:

<FILE Name="/boot/packages/powerdown-1.05-noarch-unRAID.tgz" Run="CTRLALTDEL=YES upgradepkg --install-new">
<URL>--no-check-certificate https://github.com/dlandon/unraid-snap/raw/master/powerdown-1.05-noarch-unRAID.tgz</URL>
</FILE>

 

The download link has changed because Google Code deprecated their download feature and we can no longer add files to the download.  I am hosting the powerdown package on my SNAP GitHub repository until WeeboTech and I can sort out the final repository.

powerdown.plg.txt

dlandon -----

 

Did your post above come out looking as you intended it to?  (I don't see a file to download.)

 

Frank

dlandon -----

 

Did your post above come out looking as you intended it to?  (I don't see a file to download.)

 

Frank

 

My bad.  I fixed it.

thanks

I've created a simple plugin that will install the new version of the powerdown package.  It is attached.  Just put this file in the /boot/config/plugins.

 

 

OK, I want to run this by you before I actually do it.  I currently have powerdown-1.02-noarch-unRAID.tgz installed via unMEMU. 

 

First, I should go into the unMENU PKG Manager and set 'powerdown-1.02-noarch-unRAID.tgz' to 'Disable re-install on Reboot'.

 

Second, rename your  powerdown.plg.txt file that I downloaded to remove the .txt extension.

 

Third, copy this renamed powerdown.plg file to /config/plugin folder(directory) using windows explorer.

 

Fourth, use the GUI stop the array and then reboot the server.

 

Do I have the steps correct? 

I've created a simple plugin that will install the new version of the powerdown package.  It is attached.  Just put this file in the /boot/config/plugins.

 

 

OK, I want to run this by you before I actually do it.  I currently have powerdown-1.02-noarch-unRAID.tgz installed via unMEMU. 

 

First, I should go into the unMENU PKG Manager and set 'powerdown-1.02-noarch-unRAID.tgz' to 'Disable re-install on Reboot'.

 

Second, rename your  powerdown.plg.txt file that I downloaded to remove the .txt extension.

 

Third, copy this renamed powerdown.plg file to /config/plugin folder(directory) using windows explorer.

 

Fourth, use the GUI stop the array and then reboot the server.

 

Do I have the steps correct?

 

That should do it.

 

Confirm that the 1.05 version of the package is installed by looking in the log.

 

Things are a bit messy right now while testing powerdown.  When we are confident that powerdown is working, the plugin authors can update their versions of powerdown.

 

Once I am confident that this version is working, I will release a new version (2.00) that includes fixes and the ability for those running VMs or others needing special shutdown processing to install scripts that powerdown will manage to stop VMs or any special needs before shutting down.

I did the install as I outlined.  I have also installed Apcupsd-3.14.10-i486-4_rlw-dl.plg  and looking through the syslog and the Apcupsd .plg file, it apparently installs powerdown 1.02 as a part of its installation process.  Of course, then your new powerdown script uninstalls the 1.02 version to install 1.05.  Luckily, the Apcupsd install occurs first! 

 

So you are right.  The install process is a bit messy at this point!  ::)

I did the install as I outlined.  I have also installed Apcupsd-3.14.10-i486-4_rlw-dl.plg  and looking through the syslog and the Apcupsd .plg file, it apparently installs powerdown 1.02 as a part of its installation process.  Of course, then your new powerdown script uninstalls the 1.02 version to install 1.05.  Luckily, the Apcupsd install occurs first! 

 

So you are right.  The install process is a bit messy at this point!  ::)

 

Change the lines in your apcupsd plugin that download and install the powerdown package to the following and it will install the 1.05 version.

 

<FILE Name="/boot/packages/powerdown-1.05-noarch-unRAID.tgz" Run="CTRLALTDEL=YES upgradepkg --install-new">
<URL>--no-check-certificate https://github.com/dlandon/unraid-snap/raw/master/powerdown-1.05-noarch-unRAID.tgz</URL>
</FILE>

Version 2.00 is now available.

 

Where would one download the file and is there a readme file to described the changes? 

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.