Announcement

Collapse
No announcement yet.

Is there a way to detect errors

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Is there a way to detect errors

    I've a bit of scripting to do. Make a backup of a folder system and then empty the source folder structure after the backup. I'd really like to know if the backup actually worked. I don't see error-detecting in the scripting guide. Is there an obvious way to do this that I can't see?

  • #2
    Hello,

    You would need to use the "log" scripting command as the first line of your script, and then search if a file copy error or other file operation error occurred. The other method would be to generate a folder-report after the 'backup' but before emptying the source, as any differences would be files that were not backed up.

    We also have the "option stop-on-error" line, which could be the second line of your script. If any errors occur, the script will stop.

    What do you mean by emptying the source folder as well? Are you deleting the original after copying to a 'backup' location? Do you have another, secondary location to serve as an actual backup? In general, it is a good practice to always have the files in at least two locations, in case one location fails you can restore from the other.

    Fatal errors (such as failing to load a base folder) will be logged and also prevent the script from running.
    Aaron P Scooter Software

    Comment


    • #3
      You're correct. I'm planning to delete the original after copying to the backup location. And I agree: there's no way I should do this without first making a safe copy that I can go back to should a disaster befall me.

      Thanks for the suggestion about searching the log for errors. I hadn't thought of that. I still have to make sure with the customer whether I can rely on there being a person to verify that everything went well before eradicating the safe copy.

      Thanks Aaron. I see your support is as good as your product.
      Last edited by Aaron; 02-Oct-2014, 01:25 PM.

      Comment


      • #4
        Yes, and let us know if you have any other questions.

        To clarify, we sometimes see customers who 'backup' to an external drive, and then delete the source. At which point, if that external drive fails or is stolen, the 'backup' is gone since it was the only copy of the data. I just wanted to warn against this scenario, and recommend that you have the data in at least two independent locations before deleting the original.

        Update: And a Folder Compare of Source <> Backup running a binary compare, and then generating a folder-report, would give you a quick overview if all of the files are binary equal or if any are missing.
        Aaron P Scooter Software

        Comment

        Working...
        X