Help needed with snapshot verify

Hi everyone,
I’m relatively new to kopia and usually only use its GUI, but I read about this command and wanted to try it:

kopia snapshot verify --verify-files-percent=100 --file-parallelism=10 --parallel=10

However, I can’t get it to work. I’m doing the following:

kopia repository connect filesystem --path="..."
kopia snapshot verify "k824b5107b13b381cb832c7ed16dbeaa2" --verify-files-percent=100 --file-parallelism=10 --parallel=10

but it gives an error:

Listing blobs...
Listed 17 blobs.
ERROR unable to parse snapshot manifest k824b5107b13b381cb832c7ed16dbeaa2: snapshot not found
Finished processing 0 objects.
ERROR found 0 of the 1 requested snapshot IDs to verify

I have tried different snapshot-IDs with and without quotation marks, verify without further flags,… same error.

What am I doing wrong?
Thanks for your help

I’m seeing the same error when passing a snapshot-id. But omiting the snapshot-id and verifying the repository instead a single snapshot does work.

I have tried and indeed it does not work. Looks like a bug for me.

I think I see what’s amiss:

Without:

kopia snapshot verify --verify-files-percent=100 --file-parallelism=10 --parallel=10 --config-file=$HOME/.config/kopia/repository.config; status=$?; printf "%s\n" "snapshot verify exit code: $status"
Listing blobs...
Listed 46 blobs.
Processed 0 objects.
Finished processing 5 objects.
snapshot verify exit code: 0

With:

kopia snapshot verify --verify-files-percent=100 --file-parallelism=10 --parallel=10 --config-file=$HOME/.config/kopia/repository.config c5488bd7509fa100aa10c9ede4fcbf57; status=$?; printf "%s\n" "snapshot verify exit code: $status"
Listing blobs...
Listed 46 blobs.
Processed 0 objects.
Finished processing 5 objects.
snapshot verify exit code: 0

The snapshot ID was noted after running:

time kopia --config-file=$HOME/.config/kopia/repository.config snapshot create $pathToSnapshot; kopia_exit_status="$?"; printf "%s\n" "exit code: $kopia_exit_status"
Snapshotting user@host:$pathToSnapshot ...
 * 0 hashing, 3 hashed (30.3 MB), 0 cached (0 B), uploaded 24.8 MB, estimating...
Created snapshot with root kc9c25d526595cb6114c611ad5d5b6a0f and ID c5488bd7509fa100aa10c9ede4fcbf57 in 0s

real    0m0.528s
user    0m0.452s
sys     0m0.096s
exit code: 0

It appears kopia snapshot list --show-identical --all --config-file=$HOME/.config/kopia/repository.config "$user@host:$pathToSnapshot" only reports the root ID (eg: kc9c25d526595cb6114c611ad5d5b6a0f) vs the actual snapshot ID (c5488bd7509fa100aa10c9ede4fcbf57).

So that’s fun.

@SomeBoringName

Found it:

kopia snapshot list --json --json-indent --config-file=$HOME/.config/kopia/repository.config "$user@$host:$pathToBeSnapshotted" | grep "id" | head -n1

 "id": "c5488bd7509fa100aa10c9ede4fcbf57",

So I echo @kapitainsky : this seems like a bug… at least in proper output in the CLI, GUI.

Great find! :clap:

Agree. Would you mind creating a Github issue?

I would. I don’t care for MSFT’s openly hostile stance towards online privacy. They can kiss my ASN.

Wow, thank you all for your answers and especially @97b4958b055b for identifying the problem!
Glad my question wasn’t entirely stupid.
With the other ID it seems to work :slight_smile:

1 Like

This software has a lot of rough edges IMO. Testing thoroughly before relying on it would be prudent if you don’t mind the unsolicited advice.

Have a good one.