Git Product home page Git Product logo

Comments (44)

JourneyOver avatar JourneyOver commented on July 19, 2024 1

oof seems you missed the "t" in stuff that's why xD
conemu64_02-10-2019_03-23-09

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024 1

btw shouldn't

    "RetainBackups": {
        "value": "2"
    },

be

    "Keep": {
        "value": "2"
    },

instead? as there is nothing in the .ps1 script to indicate any sorta RetainBackups but there is for Keep

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024 1

So far everything is working perfectly, Ran it twice without any issues (just testing things) before I ended up catching the #2 (comment) thing, upon switching the RetainBackups to Keep it ended up deleting all backups and starting from scratch on the backup stuff which is about the only thing I've ran into so far since I've got things working.

and I can say that it does seem to be a lot faster at doing things compared to when I manually zipped files up and all that myself..usually took around half an hour to an hour to get everything zipped up or unzipped manually, but with the script it seems to only take around ~10-12 minutes, and it's doing the same folders I did manually.

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024 1

Btw, filed a bug report about quoted values to cmder: cmderdev/cmder#2038

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

Thanks for the feedback, JourneyOver. Let's address your issues one at a time.

The first issue (the config file not found error) is due to a bug (looks like I missed a couple of things when I tested; and to tell the truth, I did not test it extensively, just the most common scenarios). The reason why it could not find the file was because the code tested for directory. This is fixed now.

The second issue... well, I'm not sure what to make out of it. Parameter 'Mode' can be one of the following: Backup, Continue, or Restore. The default value (hard coded in the script) is Backup. If you specify the Mode value via command-line argument, make sure you use a proper value. Or when using a config file, make sure it is either null, or has the hasValue attribute set to false, or has a proper value.

The last issue (SendMail value error) was a result of the wrong value in the sample config file. Also fixed (actually, this is an old bug, so you probably used an older version of the config file; anyway, I found another typo, so thanks for bringing this to my attention).

So, grab the latest versions of the PlexBackup.ps1 and sample config and see if it works.

By the way, if you are planning to use one configuration only (i.e. you are not planning to run the script with different settings), just name the config file PlexBackup.ps1.json, make sure it's in the same directory as PlexBackup.ps1, and do not use the -ConfigFile switch (the script will find it, just make the extension .ps1.json). If you are planning to use different configurations (say, you want to use Robocopy backup and run it once a week as a new backup and a few days per week as continued backup), then using custom config files would make sense, but otherwise, just use the default name.

I hope this fixes your issues, but if not, please let me know. The script works beautifully for me. It was so much hassle when I did it manually before. Now, I just have it running as a scheduled task once a week and it sends me an email notification with backup result.

Let me know how it goes. If it solves your problem, I'll create a new release for the last commit.

Cheers.

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

One more thing. I just noticed (and was able to duplicate it): for the Mode error, if your config file path has spaces, make sure you enclose it in quotes, i.e. instead of:

./PlexBackup.ps1 -ConfigFile D:\Plex Stuff\PlexBackup\PlexBackup.json

use

./PlexBackup.ps1 -ConfigFile "D:\Plex Stuff\PlexBackup\PlexBackup.json"

I'm not sure why PowerShell complains about the Mode value. I understand that it treats the "Stuff\PlexBackup\PlexBackup.json" part as a separate parameter (since it comes after a space character when not using quotes), but no idea why it results in the wrong error message. Must be something to do with PowerShell internals. I'm not a pro in PowerShell (in fact, this was my very first PowerShell script).

Anyway, make sure you put parameters with space characters in quotes, but also consider using the default config file name as I recommended above.

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

The first issue (the config file not found error) is due to a bug (looks like I missed a couple of things when I tested; and to tell the truth, I did not test it extensively, just the most common scenarios). The reason why it could not find the file was because the code tested for directory. This is fixed now.

This seems to be fixed now.

The second issue... well, I'm not sure what to make out of it. Parameter 'Mode' can be one of the following: Backup, Continue, or Restore. The default value (hard coded in the script) is Backup. If you specify the Mode value via command-line argument, make sure you use a proper value. Or when using a config file, make sure it is either null, or has the hasValue attribute set to false, or has a proper value.

One more thing. I just noticed (and was able to duplicate it): for the Mode error, if your config file path has spaces, make sure you enclose it in quotes, i.e. instead of:

./PlexBackup.ps1 -ConfigFile D:\Plex Stuff\PlexBackup\PlexBackup.json

use

./PlexBackup.ps1 -ConfigFile "D:\Plex Stuff\PlexBackup\PlexBackup.json"

I'm not sure why PowerShell complains about the Mode value. I understand that it treats the "Stuff\PlexBackup\PlexBackup.json" part as a separate parameter (since it comes after a space character when not using quotes), but no idea why it results in the wrong error message. Must be something to do with PowerShell internals. I'm not a pro in PowerShell (in fact, this was my very first PowerShell script).

Anyway, put make sure you put parameters with space characters in quotes, but also consider using the default config file name as I recommended above.

I explained above why it's complaining about the mode value and that I already put quotes around the pathing due to the space, so that should not be an issue at all.. as I explained above

For some reason or another it seems to completely be cutting out the D:\Plex bit from the path, even though I surround it in quotes ./PlexBackup.ps1 -ConfigFile "D:\Plex Stuff\PlexBackup\PlexBackup.json"

and this is still an issue as well, so it's something to do with the script interpreting things wrong or something as I have no issues with any other kinda powershell script.


The last issue (SendMail value error) was a result of the wrong value in the sample config file. Also fixed (actually, this is an old bug, so you probably used an older version of the config file; anyway, I found another typo, so thanks for bringing this to my attention).

So, grab the latest versions of the PlexBackup.ps1 and sample config and see if it works.

Definetly wasn't due to an older version, as I grabbed the latest source code when I first seen this and wanted to see how things worked, and this issue is still prevelent in the latest source as well. It's something to do inside of the ps1 script, not the config file.

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

Also testing with just the default "PlexBackup.ps1.SAMPLE.json" seems to work but I need to provide the -configfile switch in the call otherwise it doesn't work.. but it throws another error as well now.

PlexBackup v1.3.4 (c) 2019 Alek Davis
Script started at:
  02/10/2019 02:28:38
Loading configuration settings from:
  PlexBackup.ps1.SAMPLE.json
in:
  C:\Users\JourneyOver\Desktop\Installers\PlexBackup
Test-Path : The network path was not found
At C:\Users\JourneyOver\Desktop\Installers\PlexBackup\PlexBackup.ps1:890 char:15
+         if (!(Test-Path -Path $fileDir -PathType Container)) {
+               ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Test-Path], IOException
    + FullyQualifiedErrorId : System.IO.IOException,Microsoft.PowerShell.Commands.TestPathCommand

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

Okay, let's simplify it: name the config file PlexBackup.ps1.config, place it in the same folder as PlexBackup.ps1 and run it without any command-line parameters. What will you get?

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024
PlexBackup v1.3.4 (c) 2019 Alek Davis
Script started at:
  02/10/2019 02:31:40
Loading configuration settings from:
  PlexBackup.ps1.json
in:
  C:\Users\JourneyOver\Desktop\Installers\PlexBackup
Test-Path : The network path was not found
At C:\Users\JourneyOver\Desktop\Installers\PlexBackup\PlexBackup.ps1:890 char:15
+         if (!(Test-Path -Path $fileDir -PathType Container)) {
+               ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Test-Path], IOException
    + FullyQualifiedErrorId : System.IO.IOException,Microsoft.PowerShell.Commands.TestPathCommand

This is just doing
./PlexBackup.ps1 no command-line parameters but having the default sample config in the same folder with the filename changed and nothing more.

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

Please post the contents of the PlexBackup.ps1.json file.

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

it was due to the

   "BackupRootDir": {
        "value": "\\\\MYNAS\\PlexBackup"
    },

as I was currently using the default https://github.com/alekdavis/PlexBackup/blob/master/PlexBackup.ps1.SAMPLE.json with just the name change like you requested above, once I changed that to a actual directory on my computer it stopped throwing that error.

Now how do I get it to stop popping up the thing for the mail, as setting this

    "SendMail": {
        "hasValue": true,
        "value": "Always"
    },

to false doesn't seem to stop it from coming up, and I do not want emails from this.

and if I have it set to false, and when the popup thing for the mail happens and I click cancel instead of filling it out it throws

PlexBackup v1.3.4 (c) 2019 Alek Davis
Script started at:
  02/10/2019 02:43:08
Loading configuration settings from:
  PlexBackup.ps1.json
in:
  D:\Plex Stuff\PlexBackup
The variable cannot be validated because the value False is not a valid value for the SendMail variable.
At D:\Plex Stuff\PlexBackup\PlexBackup.ps1:2685 char:9
+         $SendMail = $false
+         ~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : MetadataError: (:) [], ParentContainsErrorRecordException
    + FullyQualifiedErrorId : ValidateSetFailure

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

Oh, this makes sense. :-)

To not send mail, set the value to "Never" (or just remove the "hasValue" line and set value to null, i.e. "value" : null. It is "Never" by default.

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

still throwing

PlexBackup v1.3.4 (c) 2019 Alek Davis
Script started at:
  02/10/2019 02:45:31
Loading configuration settings from:
  PlexBackup.ps1.json
in:
  D:\Plex Stuff\PlexBackup
The variable cannot be validated because the value False is not a valid value for the SendMail variable.
At D:\Plex Stuff\PlexBackup\PlexBackup.ps1:2685 char:9
+         $SendMail = $false
+         ~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : MetadataError: (:) [], ParentContainsErrorRecordException
    + FullyQualifiedErrorId : ValidateSetFailure

and I just have it set as

    "SendMail": {
        "value": null
    },

in the config file.

Current config file is looking like

{
    "_meta": {
        "version": "1.0",
        "strictMode": false,
        "description": "Sample configuration settings for PlexBackup.ps1."
    },
    "Mode": {
        "value": "Backup"
    },
    "PlexAppDataDir": {
        "value": null
    },
    "BackupRootDir": {
        "value": "D:\\Plex Stuff\\PlexBackup"
    },
    "BackupDirPath": {
        "value": null
    },
    "TempZipFileDir": {
        "hasValue": true,
        "value": null
    },
    "PlexRegKey": {
        "value": null
    },
    "ExcludePlexAppDataDirs": {
        "value": null
    },
    "SpecialPlexAppDataSubDirs": {
        "value": null
    },
    "PlexServiceNameMatchString": {
        "value": "^Plex"
    },
    "PlexServerExeFileName": {
        "value": "Plex Media Server.exe"
    },
    "PlexServerExePath": {
        "value": null
    },
    "RetainBackups": {
        "value": null
    },
    "Robocopy": {
        "value": false
    },
    "Retries": {
        "value": null
    },
    "RetryWaitSec": {
        "value": null
    },
    "Log": {
        "value": true
    },
    "LogAppend": {
        "value": null
    },
    "LogFile": {
        "value": null
    },
    "ErrorLog": {
        "value": true
    },
    "ErrorLogAppend": {
        "value": null
    },
    "ErrorLogFile": {
        "value": null
    },
    "Shutdown": {
        "value": null
    },
    "SendMail": {
        "value": null
    },
    "From": {
        "value": null
    },
    "To": {
        "value": null
    },
    "SmtpServer": {
        "value": "smtp.gmail.com"
    },
    "Port": {
        "value": 587
    },
    "UseSsl": {
        "value": true
    },
    "CredentialFile": {
        "value": null
    },
    "PromptForCredential": {
        "value": true
    },
    "SaveCredential": {
        "value": true
    },
    "Anonymous": {
        "value": null
    },
    "SendLogFile": {
        "value": "Never"
    }
}

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

which btw not doing the -configfile thing in the call fixes the whole issue with the space in the path..so idk what is going on with the script and calling the configfile and the configfile being in some place with a space in the path, even though it's being quoted..

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

Oh, crap, that's my bug. Change line 2685 from

$SendMail = $false

to

$SendMail = 'Never'

Or get the latest file from github.

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

I just tested the script with custom config file in a different folder with a space in the path and as long as I have the file path in quotes, it works fine.

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

2
1

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

Oh, crap, that's my bug. Change line 2685 from

$SendMail = $false

to

$SendMail = 'Never'

Or get the latest file from github.

Yep seems to have fixed it, as once I changed that and ran it again it started right up without any errors..

I just tested the script with custom config file in a different folder with a space in the path and as long as I have the file path in quotes, it works fine.

Strange that it's working for you just fine with having spaces in the path, but for me it doesn't at all.. but it seems that if I just call it like ./PlexBackup.ps1 it'll work with the space in the path, but if I call it like ./PlexBackup.ps1 -ConfigFile "D:\Plex Stuff\PlexBackup\PlexBackup.json" (The path is quoted) it'll throw the

D:\Plex Stuff\PlexBackup\PlexBackup.ps1 : Cannot validate argument on parameter 'Mode'. The argument "Stuff\PlexBackup\PlexBackup.json" does
not belong to the set "Backup,Continue,Restore" specified by the ValidateSet attribute. Supply an argument that is in the set and then try
the command again.
At line:1 char:38
+ ./PlexBackup.ps1 -ConfigFile D:\Plex Stuff\PlexBackup\PlexBackup.json
+                                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidData: (:) [PlexBackup.ps1], ParameterBindingValidationException
    + FullyQualifiedErrorId : ParameterArgumentValidationError,PlexBackup.ps1

error.

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

-ConfigFile "D:\Plex Stuff\PlexBackup\PlexBackup.json" should work (as I posted a screenshot above; I added a return 0, to immediately return if the script reads config settings without a problem and it does). You would get the "Cannot validate argument on parameter 'Mode'" error if you do not enclose the path in parentheses:
3

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

Like I've said time and time again...I quote it..
02-10-2019_03-18-02
I mostly call my powershell scripts in cmder, as it's just quicker for me to pull it up compared to pulling up powershell

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

Could you post the result from this command:

dir "D:\Plex Stuff\PlexBackup"

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

Very strange..
if I do dir "D:\Plex Suff\PlexBackup" it comes up with The system cannot find the file specified. but if I do just dir it comes up with all the files..
conemu64_02-10-2019_03-21-53

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

Hmmm... not sure what to tell you. And you get the same result in PowerShell?

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

inside powershell ISE it started working finally correctly, but it's got to be something with this script in general because I have never had this issue before where if I needed to add a command-line parameter that I had to provide a path and it had a space in said path anywhere it worked just fine whenever I quoted it whenever I decided to use cmd instead to call the powershell script..

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

Don't know what to tell you. I do not use cmder, and it works fine for me from either PowerShell ISE and PowerShell command line. Command-line argument processing is done by PowerShell before it executes a single line of the script code (beyond the script param section). You can test by adding Write-Host "OK" at the top of the main logic and you will see that the script will not call it (you will get the error first). And the binding just assigns the value of -ConfigFile to a sting variable, so I'm not inventing anything new here.

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

Good catch. Will fix it.

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

Don't know what to tell you. I do not use cmder, and it works fine for me from either PowerShell ISE and PowerShell command line. Command-line argument processing is done by PowerShell before it executes a single line of the script code (beyond the script param section). You can test by adding Write-Host "OK" at the top of the main logic and you will see that the script will not call it (you will get the error first). And the binding just assigns the value of -ConfigFile to a sting variable, so I'm not inventing anything new here.

Well I tried one more thing, I triple quoted it instead of just putting one double quote around it, so like ./PlexBackup.ps1 -ConfigFile """D:\Plex Stuff\PlexBackup\PlexBackup.json""" instead of ./PlexBackup.ps1 -ConfigFile "D:\Plex Stuff\PlexBackup\PlexBackup.json" and it worked..dunno why your script is making me triple quote the path but w/e, at least I can call it in cmder now.

Good catch. Will fix it.

^^

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

I will also thinking about setting the default backup folder dir to the script dir (and remove the NAS share from the sample config file).

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

Yea would prob be smart, otherwise you'll get people trying with the sample config and running into errors xD

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

Well I tried one more thing, I triple quoted it instead of just putting one double quote around it, so like ./PlexBackup.ps1 -ConfigFile """D:\Plex Stuff\PlexBackup\PlexBackup.json""" instead of ./PlexBackup.ps1 -ConfigFile "D:\Plex Stuff\PlexBackup\PlexBackup.json" and it worked..dunno why your script is making me triple quote the path but w/e, at least I can call it in cmder now.

But regular double or single quotes work in standard PowerShell and PowerShell ISE, right? And they do not work in cmder. Wouldn't it mean it's a cmder problem? (As I said, I did not invent anything here; it's standard PowerShell command-line processing.)

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

But regular double or single quotes work in standard PowerShell and PowerShell ISE, right? And they do not work in cmder. Wouldn't it mean it's a cmder problem. (As I said, I did not invent anything here; it's standard PowerShell command-line processing.)

Yes, but like I said before I'm able to just regular double/single quote on other things just fine without issue in cmder..it's only your script that I seem to have to triple double quote to get it to register the path correctly if it's got a space in it.

So I don't really know what is going on with this all, but I'm fine with it, as long as it works >.<

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

Cool. If you figure it out, let me know (as I said, this is my first PowerShell script, so maybe I missed something). Let me know how the backup goes (succeeds? runs into issues?). It took me (in the compression mode) over 3 hours to back up data from a NAS share and about 45 minutes to backup from a local drive. As long as you do not have paths longer than 260 characters (other than the subfolder the script already knows about), it should work, but in any case, let me know. Thanks for being my beta tester. ;-)

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

Sweet. I just tested it in cmder and I also get the same error. But guess what: if I use single quotes instead of double quotes, it works fine:

4

So cmder works differently whether you enclose a command line parameter in single or double quotes? Seems messed up to me and not consistent with PowerShell (where it works the same).

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

I think I'll be taking off for tonight. :-) Let me know if you run into any other issues. I'll keep this thread open for now. Thanks again for you effort and feedback. I appreciate it.

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

Sweet. I just tested it in cmder and I also get the same error. But guess what: if I use single quotes instead of double quotes, it works fine:

4

So cmder works differently whether you enclose a command line parameter in single or double quotes? Seems messed up to me and not consistent with PowerShell (where it works the same).

Mmm that's even stranger, as I can double quote/single quote other stuff just fine xD it's only this script I'm running into this issue..but if it's allowing single quote (I didn't even test that thinking I'd run into the same problem) then I guess I'm happy as I won't have to worry about remembering to triple quote the path whenever I run this script.

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

Sounds good, Have a good night o/ if I run into any issues, I will be sure to report them here :)

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

I marked the update with a new release number and will close this issue as resolved. If you run into any other problems, please open another issue. Cheers.

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

Alright man sounds good ^^

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

Here is the explanation why the quotes are not parsed correctly: https://stackoverflow.com/questions/55201798/why-does-powershell-not-recognize-quoted-parameters

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

Did you change something recently in your script?? it seems to completely ignore the -ConfigFile parameter now..

powershell ./PlexBackup.ps1 -ConfigFile 'PlexBackup.Backup.json'
PlexBackup v1.5.6 (c) 2019 Alek Davis
Script started at:
  05/18/2019 02:22:48
PlexBackup v1.5.6 (c) 2019 Alek Davis
Script started at:
  05/18/2019 02:22:48
Operation mode:
Operation mode:
  BACKUP
  BACKUP
Backup type:
Backup type:
  DEFAULT
  DEFAULT
Plex Media Server version (CURRENT):
Plex Media Server version (CURRENT):
  1.15.6.1079
  1.15.6.1079
Cannot save Plex Media Server version:
Cannot save Plex Media Server version:
  1.15.6.1079
  1.15.6.1079
to:
to:
  C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248\version.txt
  C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248\version.txt
Could not find a part of the path 'C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248\version.txt'.
Could not find a part of the path 'C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248\version.txt'.
Stopping Plex Media Server process:
Stopping Plex Media Server process:
  Plex Media Server.exe
  Plex Media Server.exe
Ignoring script parameter:
Ignoring script parameter:
  ExcludePlexAppDataFiles
  ExcludePlexAppDataFiles
Backup will be saved in:
Backup will be saved in:
  C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248
  C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248
Creating backup folder:
Creating backup folder:
  C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248
  C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248
Creating task-specific subfolder(s) in:
Creating task-specific subfolder(s) in:
  C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248
  C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248
Backing up special subfolders.
Backing up special subfolders.
Moving folder:
Moving folder:
  C:\Users\JourneyOver\AppData\Local\Plex Media Server\Plug-in Support\Data\com.plexapp.system\DataItems\Deactivated
  C:\Users\JourneyOver\AppData\Local\Plex Media Server\Plug-in Support\Data\com.plexapp.system\DataItems\Deactivated
to:
to:
  C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248\3\Plug-in Support\Data\com.plexapp.system\DataItems\Deactivated
  C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248\3\Plug-in Support\Data\com.plexapp.system\DataItems\Deactivated at:
at:
  2019/05/18 02:22:50.607
  2019/05/18 02:22:50.607
Completed at:
Completed at:
  2019/05/18 02:22:50.649
  2019/05/18 02:22:50.649
Backing up Plex app data folders from:
Backing up Plex app data folders from:
  C:\Users\JourneyOver\AppData\Local\Plex Media Server
  C:\Users\JourneyOver\AppData\Local\Plex Media Server
to:
to:
  C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248\1
  C:\Users\JourneyOver\Desktop\Github\Backup-Scripts\PlexBackup\20190518022248\1
Archiving:
Archiving:
  C:\Users\JourneyOver\AppData\Local\Plex Media Server\Cache
  C:\Users\JourneyOver\AppData\Local\Plex Media Server\Cache
to temp file:
to temp file:
  C:\Users\JOURNE~1\AppData\Local\Temp\PlexBackup-b04ccf98-00f6-4fb7-afd2-2d62881bb3aa.zip
  C:\Users\JOURNE~1\AppData\Local\Temp\PlexBackup-b04ccf98-00f6-4fb7-afd2-2d62881bb3aa.zip
at:
at:
  2019/05/18 02:22:50.765
  2019/05/18 02:22:50.765

is what it's currently doing now..

and this is my config file

{
  "_meta": {
    "version": "1.0",
    "strict": false,
    "description": "Backup Config File"
  },
  "Mode": {
    "_meta": {
      "set": "Backup,Continue,Restore",
      "default": "Backup"
    },
    "value": "Backup"
  },
  "Type": {
    "_meta": {
      "set": ",7zip,Robocopy",
      "default": ""
    },
    "value": "7zip"
  },
  "PlexAppDataDir": {
    "_meta": {
      "default": "$env:LOCALAPPDATA\\Plex Media Server"
    },
    "value": null
  },
  "BackupRootDir": {
    "value": "H:\\Ketarin\\ketarin-files\\installers\\Backups\\PMS"
  },
  "BackupDirPath": {
    "value": null
  },
  "TempZipFileDir": {
    "_meta": {
      "default": "$env:TEMP"
    },
    "hasValue": true,
    "value": null
  },
  "PlexRegKey": {
    "value": null
  },
  "ExcludePlexAppDataDirs": {
    "_meta": {
      "default": ["Diagnostics", "Crash Reports", "Updates", "Logs"]
    },
    "value": ["Cache", "Diagnostics", "Crash Reports", "Updates", "Logs"]
  },
  "ExcludePlexAppDataFiles": {
    "_meta": {
      "default": ["*.bif"]
    },
    "value": null
  },
  "SpecialPlexAppDataSubDirs": {
    "_meta": {
      "default": [
        "Plug-in Support\\Data\\com.plexapp.system\\DataItems\\Deactivated"
      ]
    },
    "value": null
  },
  "PlexServiceNameMatchString": {
    "_meta": {
      "default": "^Plex"
    },
    "hasValue": false,
    "value": null
  },
  "PlexServerExeFileName": {
    "_meta": {
      "default": "Plex Media Server.exe"
    },
    "value": null
  },
  "PlexServerExePath": {
    "value": null
  },
  "Keep": {
    "_meta": {
      "range": "0-[int]::MaxValue",
      "default": "3"
    },
    "value": "1"
  },
  "Retries": {
    "_meta": {
      "range": "0-[int]::MaxValue",
      "default": "5"
    },
    "value": null
  },
  "RetryWaitSec": {
    "_meta": {
      "range": "0-[int]::MaxValue",
      "default": "10"
    },
    "value": null
  },
  "Log": {
    "value": true
  },
  "LogAppend": {
    "value": false
  },
  "LogFile": {
    "value": "H:\\Ketarin\\ketarin-files\\installers\\Backups\\PMS\\PlexBackup.log"
  },
  "ErrorLog": {
    "value": true
  },
  "ErrorLogAppend": {
    "value": false
  },
  "ErrorLogFile": {
    "value": "H:\\Ketarin\\ketarin-files\\installers\\Backups\\PMS\\PlexBackupError.log"
  },
  "Shutdown": {
    "value": null
  },
  "Inactive": {
    "value": null
  },
  "Force": {
    "value": null
  },
  "SendMail": {
    "_meta": {
      "set": "Never,Always,OnError,OnSuccess,OnBackup,OnBackupError,OnBackupSuccess,OnRestore,OnRestoreError,OnRestoreSuccess",
      "default": "Never"
    },
    "value": null
  },
  "From": {
    "value": null
  },
  "To": {
    "value": null
  },
  "SmtpServer": {
    "value": "smtp.gmail.com"
  },
  "Port": {
    "_meta": {
      "range": "0-[int]::MaxValue",
      "default": "0"
    },
    "value": 587
  },
  "UseSsl": {
    "value": true
  },
  "CredentialFile": {
    "value": null
  },
  "PromptForCredential": {
    "value": false
  },
  "SaveCredential": {
    "value": false
  },
  "Anonymous": {
    "value": null
  },
  "SendLogFile": {
    "_meta": {
      "set": "Never,OnError,OnSuccess,Always",
      "default": "Never"
    },
    "value": "Never"
  },
  "ArchiverPath": {
    "_meta": {
      "default": "$env:ProgramFiles\\7-Zip\\7z.exe"
    },
    "value": null
  }
}

Things was working just fine in 1.5.3 but seen you updated so I updated my backup script, along with my config, and now it just does the above..

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

@JourneyOver : Oh, dang. Thanks for reporting this. I did change how the config file gets loaded (moved all config file handling logic into a separate module), and I forgot to include the $ConfigFile parameter when invoking the module, so it only reads the default config file (PlexBackup.ps1.json). Will fix it in a moment. But you can rename your config file to the default name and it should work with the default file.

from plexbackup.

alekdavis avatar alekdavis commented on July 19, 2024

@JourneyOver Okay, should be good now (in v1.5.7). Also fixed duplicate log messages. Let me know if there is anything else (please, open a new issue; this one is a bit long). Thanks again for reporting it.

from plexbackup.

JourneyOver avatar JourneyOver commented on July 19, 2024

@alekdavis all looks to be good now on at least the configfile stuff ^^ I'll open a new issue for the one last little thing that seems to not work correctly for some reason (and I don't think it ever has yet).

from plexbackup.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.