Jump to content
  • 0

Trigger a scheduled task or script after balance?


fattipants2016

Question

Easy question, today.

Is there any way to trigger a scheduled task, or execute a script from the command-line after balancing?

I'm trying to sync DP & SnapRAID, and by time isn't cutting it.

I disabled DP's background balancing, and told the scheduled task (SR) to only start when the computer's idle, but it just starts in the middle of balancing anyways.

Link to comment
Share on other sites

12 answers to this question

Recommended Posts

  • 0

DrivePool_RunningFile doesn't seem to do anything in 2.2.906.

I've tried both "Override: C:\Snapraid\Balancing.txt" and "Override: "C:\Snapraid\Balancing.txt"" (with and without quotes,) rebooting before each test.

No file is created at any point during balancing.

I still desperately need help with my SSD Optimizer balancing issues, as well.

 

Link to comment
Share on other sites

  • 0

Thank you! That worked.

Is there any plan to, or a layman explanation why not, add support for event logging? It would have been very easy to trigger snapraid based on an event.

And for anyone else with similar needs, I used a powershell script called "Powershell FileSystemWatcher" to write an event, and used said event to trigger snapraid-helper (also PS.)

A bit convoluted, but launching one powershell script from another is suprisingly complex.

 

Link to comment
Share on other sites

  • 0

This isn't working for me. I've got this:

  "DrivePool_RunningFile": {
    "Default": "",
    "Override": "D:\\StableBit DrivePool\\Service\\CurrentlyBalancing.txt"
  },

Then I pick an un-duplicated folder and make it duplicate - no file is created while the duplication is running...

I restarted the DP service, which should be sufficient for it to re-read the json file. I'll try rebooting but I shouldn't need to...

Regards,

Link to comment
Share on other sites

  • 0

They may not be monitoring this thread anymore, since I marked it answered.

Does the folder D:\stablebit drivepool\service\ already exist? Is it write protected?

Try putting the file in the root of D:\ just to rule out any problems with the path.

Another thing to try is to temporarily re-instate the "DrivePool.Service.exe.default.config" (rename to DrivePool.Service.exe.config) settings file in programfiles, and enable it there.

I got it to work that way, temporarily, until I heard about having to use the double \\'s. Just don't forget to rename (disable) those old settings, afterwards.

Link to comment
Share on other sites

  • 0

Lol, once again, my mistake.

Tried a TON of things, loaded-up Process Monitor, made sure DrivePool was loading the settings file; monitored for my "lock" file -> Nowhere to be found.

After like 40 minutes I had a look at the DrivePool logs and found this:

DrivePool.Service.exe	Warning	0	[JsonSettings] Error parsing JSON settings file. Using application defaults. Unexpected character encountered while parsing value: F. Path 'BitLocker_PoolPartUnlockDetect.Override', line 4, position 16.	2018-04-12 22:57:55Z	15061268610
DrivePool.Service.exe	Warning	0	[JsonSettings] Error parsing JSON settings file. Using application defaults. Unexpected character encountered while parsing value: F. Path 'BitLocker_PoolPartUnlockDetect.Override', line 4, position 16.	2018-04-12 22:58:05Z	15098892007

Looks like TRUE and FALSE are CASE-SENSITIVE. Maybe now I will see if my drives spin-down? lol.

Thanks.

Link to comment
Share on other sites

  • 0

Hi Christopher.

Lol, you know what that means: my BitLocker_PoolPartUnlockDetect.Override setting had not been working since the get-go! I don't really hear the drives spin-up or down, so it's hard for me to see if they spin-down as they should, I'd have to leave the computer idle on purpose and I haven't really had time to test this. I /think/ they don't spin-down, but it could be something else than DrivePool, like the Intel RAID driver that's still running the drives (I had to disable spin-down in Windows when this was a Intel RAID otherwise the Intel driver was fighting the sleep and re-spinning the drives up immediately. I have since re-enabled sleep in Windows, but not tested.)

PS: The lock file works fine now that I don't have an error in the config.

Regards,

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  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.

Loading...
×
×
  • Create New...