Results 1 to 7 of 7
  1. #1
    Join Date
    Jan 2018
    Posts
    4

    Default Snapshots from command line

    Hi everybody, first post here.
    I looked into the docs and the forums and couldn't find an answer.
    Is it possible to create a folder snapshot from the command line?
    I'm trying to automate that with a bat script.

    Thanks!

  2. #2
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    11,899

    Default

    Hello,

    Yes, using BC Scripting (documented in the Help file -> Using Beyond Compare -> Scripting, and the main Scripting reference chapter).

    The command line itself would be something like:
    bcompare.exe "@c:\script.txt" "c:\pathoffolder" "c:\bcsnapshot.bcss"

    where script.txt contains the snapshot command similar to:
    snapshot include-empty no-filters path:"%1" output:"%2"
    Aaron P Scooter Software

  3. #3
    Join Date
    Jan 2018
    Posts
    4

    Default

    Guess I didn't look hard enough
    Thank you very much.

    Best regards

  4. #4
    Join Date
    Jan 2018
    Posts
    4

    Default

    Any chance of adding par2 or something similar to add redundant data to snapshots for recovery purposes?

  5. #5
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    11,899

    Default

    Hello,

    We probably wouldn't add PAR2 to the snapshot, since the goal is to keep snapshots as small as possible and not contain any actual file data.

    How would it work to compartmentalize? Create an associated "PAR2" folder with the number/size of PAR files you need (letting you control the level of recovery options) and keep it next to the snapshot.bcss file. Then you can verify and compare with the snapshot (which can optionally include CRC information), and run a par recovery if ever needed.
    Aaron P Scooter Software

  6. #6
    Join Date
    Jan 2018
    Posts
    4

    Default

    Thanks for the reply, Aaron.

    I understand the file size at a minimum goal, and I found snapshot extremely useful for forensics and validation long term.
    I have been using PAR2 files for validation/recovery and found them extremely useful. I'm actually suprised that people seem to be oblivious of the concept. One of the things that I miss in PAR files is metadata verification. As far as I know, PAR files recover the actual file content and filename, that's it. So I found myself using both PAR and BC snapshots, which to me feel redundant in a way, so I though about 'merging' the PAR functionality with BC.
    I understand that it poses a challenge from a usability standpoint, but on the other hand it feels natural to have the option to heal/reconstruct files besides CRC verification.

    Long story short, I would offer the option to embed the PAR data in the snapshot file for portability (although it's true that the file size will skyrocket), and also the option to generate standalone PAR files along the snapshot.
    In both cases BC would use the PAR data to verify/fix missing or corrupted data.

    Again, I understand that it may not be your aim to add all that to BC, which is a tremendous tool anyway.
    Thanks a lot.

  7. #7
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    11,899

    Default

    Appreciated. It's unlikely we'll be able to tackle this project, given the complexity of supporting it well and handling snapshot compatibility for old .bcss handled in newer versions of BC4. Other advantages for keeping it separate is it is compartmentalized: you can upgrade PAR utilities or strategies going forward, but still have fully formed packages in older folders that can compare against newer versions, and all of this is independent of the version of BC you are currently running and the .bcss file.
    Aaron P Scooter Software

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •