Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Par2 error with DAR #195

Open
klamathh opened this issue Feb 22, 2025 · 5 comments
Open

Par2 error with DAR #195

klamathh opened this issue Feb 22, 2025 · 5 comments

Comments

@klamathh
Copy link

Hi, I'm using par2 with DAR Disk Archiver
it is the first time I included it in DAR backup process

The dar command is:

backup command

/usr/bin/env dar_static -vm -vd -vf -z -D -R / -c "$FILE" -B /etc/darrc
par2 compress-exclusion -P boot/efi -P dev -P proc -P run
-P sys -P tmp -P var/tmp -P var/cache -P root+/.cache
-P home/user/.cache -P home/user/snap/firefox/common/.cache
-P media -P cdrom -P mnt -P lost+found

The error is:

Closing archive low layer...

creating PAR file for file /mnt/backup/backup/host/ubuntu24.04/full_backup/live/2025-02-22_live-backup_ubuntu-24.04_host_full.1.dar ...

Block size: 6346252
Source file count: 1
Source block count: 2000
Recovery block count: 40
Recovery file count: 1

Opening: 2025-02-22_live-backup_ubuntu-24.04_host_full.1.dar
Computing Reed Solomon matrix.
Constructing: done.
Wrote 134217600 bytes to disk
Wrote 119632480 bytes to disk
Writing recovery packets
Writing verification packets
Done
creating PAR file for file /mnt/backup/backup/host/ubuntu24.04/full_backup/live/2025-02-22_live-backup_ubuntu-24.04_host_full.1.dar ...

Block size: 6346252
Source file count: 1
Source block count: 2000
Recovery block count: 40
Recovery file count: 1

Opening: 2025-02-22_live-backup_ubuntu-24.04_host_full.1.dar
Could not create "/mnt/backup/backup/host/ubuntu24.04/full_backup/live/2025-02-22_live-backup_ubuntu-24.04_host_full.1.dar.vol00+40.par2": File already exists.
Error during user command line execution: execution of [ /usr/share/doc/dar/examples/dar_par_create.duc "/mnt/backup/backup/host/ubuntu24.04/full_backup/live" "2025-02-22_live-backup_ubuntu-24.04_host_full" 1 dar last_slice 2 ; /usr/share/doc/dar/examples/dar_par_create.duc "/mnt/backup/backup/host/ubuntu24.04/full_backup/live" "2025-02-22_live-backup_ubuntu-24.04_host_full" 1 dar last_slice 2 ] returned error code: 1536 .
Retry command-line ? [return = YES | Esc = NO]

files in backup dir are:

$ ls -l
total 12684708
-rwxrwxrwx 1 root root 35354169 Feb 22 09:45 2025-02-22_boot-efi_host.tar.gz
-rwxrwxrwx 1 root root 7139472 Mar 31 2024 2025-02-22_dar_static
-rwxrwxrwx 1 root root 12692503368 Feb 22 09:37 2025-02-22_live-backup_ubuntu-24.04_host_full.1.dar
-rwxrwxrwx 1 root root 40452 Feb 22 09:40 2025-02-22_live-backup_ubuntu-24.04_host_full.1.dar.par2
-rwxrwxrwx 1 root root 254094992 Feb 22 09:40 2025-02-22_live-backup_ubuntu-24.04_host_full.1.dar.vol00+40.par2

Have you any solution ?

Thanks in advance

@animetosho
Copy link
Contributor

Looks like par2cmdline is being run twice with the same arguments. It succeeds the first time, but fails on the second because the output PAR2 already exists.

See why it's being run twice.

@klamathh
Copy link
Author

klamathh commented Feb 22, 2025

Looks like par2cmdline is being run twice with the same arguments. It succeeds the first time, but fails on the second because the output PAR2 already exists.

See why it's being run twice.

As I can see: Because I specified par2 in dar command the /etc/darrc run par2

par2: -B "/usr/share/doc/dar/examples/dar_par.dcf"

then the /usr/share/doc/dar/examples/dar_par.dcf is:

 configuration file for dar to have Parchive integrated
 with DAR
 to be passed to dar as argument of -B option (-B dar_par.dcf)
 either directly on command line or through $HOME/.darrc or /etc/darrc
 file

create:
        -E '/usr/share/doc/dar/examples/dar_par_create.duc "%p" "%b" %N %e %c 2'
 2 stands for 2% of redundancy
 adjust it to your needs

test:
        -E '/usr/share/doc/dar/examples/dar_par_test.duc "%p" "%b" %N %e %c'

 note that you may need to set the path to dar_par_test.duc
 and dar_par_create.duc, at dar/libdar installation, /usr/share/doc/dar/examples
 is substitued by the path where these are installed to

 fix from Sergey Feo
default:
-E "echo Warning: dar_par.dcf will not be used in this operation. Please review command line options. -c or -t should be used before -B ...dar_par.dcf"

where can I find why it run twice ?

@animetosho
Copy link
Contributor

This project is for par2cmdline. You should send DAR related questions to the DAR project.

@klamathh
Copy link
Author

This project is for par2cmdline. You should send DAR related questions to the DAR project.

ok, is there a way to tell par2 to overwrite existing par2 file ?

@animetosho
Copy link
Contributor

is there a way to tell par2 to overwrite existing par2 file ?

No.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants