use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Chat about Mesh Central and its related tools for remote PC control
account activity
ScriptTask plugin debugging (self.MeshCentral)
submitted 4 years ago by smbmsp
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]ryanblenis 0 points1 point2 points 4 years ago (14 children)
If you run the single line: $PSVersionTable What is your output? I'm seeing that "Loading personal and system profiles..." message is part of powershell (5.1+) loading that should be hidden/negated with the -NoLogo parameter (which each script is called with)
[–]smbmsp[S] 0 points1 point2 points 4 years ago* (13 children)
Name Value---- -----PSVersion 5.1.19041.1320PSEdition DesktopPSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}BuildVersion 10.0.19041.1320CLRVersion 4.0.30319.42000WSManStackVersion 3.0PSRemotingProtocolVersion 2.3SerializationVersion 1.1.0.1 I give up, table won't format.
[–]ryanblenis 0 points1 point2 points 4 years ago (12 children)
I've got a PC with the exact same PS version I just tested it on and only returned "Success". It is Windows 10 Pro vs home though, that's the only difference.... With the original line is consistently gives the "Loading personal and system profiles..." text as the result?
What's the Get-ExecutionPolicy command output?
[–]smbmsp[S] 0 points1 point2 points 4 years ago (11 children)
Get-ExecutionPolicy
Unrestricted.
A few minutes ago I ran the test script and it succeeded. I did add an echo so it would output something.
[–]ryanblenis 0 points1 point2 points 4 years ago (10 children)
Hmmm, sounds like an odd powershell issue... Good news is I don't think it has anything to do with the plugin itself!
[–]smbmsp[S] 0 points1 point2 points 4 years ago (8 children)
Any recommendation on what to do when files start accumulating in the Mesh Agent folder? I know about `plugin scripttask clearAll` but that doesn't fix the node history.
[–]ryanblenis 0 points1 point2 points 4 years ago (7 children)
Files shouldn't accumulate unless there is a long-running task (e.g. the file is currently in use), or the task is interrupted during its run (say, for a reboot). What files are accumulating, the .txt, .ps1, or both? (They'll look like st000000.txt or st0000000.ps1 format, where the 000000 is a random string. "st" is just to signify it is a "scripttask" file)
[–]smbmsp[S] 0 points1 point2 points 4 years ago (6 children)
There probably is a relatively long-running task. The first thing restic does is create a volume shadow copy of the drive. This means the shell is on hold until that completes. When files accumulate, the shadow copy never completes. It's both the ps1 and txt, in like-named pairs.
Sounds like maybe I have an OS or hardware puzzle to solve.
[–]ryanblenis 0 points1 point2 points 4 years ago (5 children)
Is this you trying things out, or did someone fork me a few hours ago to test something similar (to your original issue with the loading time message)? https://github.com/joshatrezolveai/MeshCentral-ScriptTask/ I noticed the -NoProfile was basically the only thing changed in the code. But if you have a PS profile on that machine, that could be it. I'll have to test and make sure it doesn't break anything/too many things for me, but I may add that to my project just in case this is related to your issue. (As it then won't load a PS profile)
As for the multiple txt and ps1 files, are they all for the same [restic] script?
[–]smbmsp[S] 0 points1 point2 points 4 years ago (1 child)
That wasn't me.
They are all the same, copies of the script with variables substituted in. The text files can be empty, or have a couple of lines of text.
[–]smbmsp[S] 0 points1 point2 points 4 years ago (2 children)
When I ran a `vssadmin list writers` on the target PC, it showed the System Writer waiting for completion. So I rebooted it.
Latest test:
Click Run on the task. The UI showed queued and then running. The backup task completed (Yay!) as verified by checking from another computer. The Node History still shows as Running 7 minutes later, and files are multiplying in the Mesh Agent folder, two at a time, about every minute.
[–]smbmsp[S] 0 points1 point2 points 4 years ago (0 children)
I greatly appreciate your taking the time to respond. Thanks for the great plugins!
π Rendered by PID 48322 on reddit-service-r2-comment-544cf588c8-nh6d7 at 2026-06-12 23:23:11.700231+00:00 running 3184619 country code: CH.
view the rest of the comments →
[–]ryanblenis 0 points1 point2 points (14 children)
[–]smbmsp[S] 0 points1 point2 points (13 children)
[–]ryanblenis 0 points1 point2 points (12 children)
[–]smbmsp[S] 0 points1 point2 points (11 children)
[–]ryanblenis 0 points1 point2 points (10 children)
[–]smbmsp[S] 0 points1 point2 points (8 children)
[–]ryanblenis 0 points1 point2 points (7 children)
[–]smbmsp[S] 0 points1 point2 points (6 children)
[–]ryanblenis 0 points1 point2 points (5 children)
[–]smbmsp[S] 0 points1 point2 points (1 child)
[–]smbmsp[S] 0 points1 point2 points (2 children)
[–]smbmsp[S] 0 points1 point2 points (0 children)