Yes, thanks, I forgot to tell about the sudoers-part. I did that, precisely as you suggest.

And oddly enough, even when I copy your TarClientCmd mine exits with the same error. The only information I can dig up from Google on error 512 is permissions, but as my user backuppc is in sudoers, how can that be a problem?

I can for instance manually, as backuppc, run "sudo tar <arguments and target>" without problem and without need to give a password.



2013-01-29 16:24, Travis.Schwenke skrev:

Hey, I might be able to give back to the community!!


I have the same stetup (I didn’t install Ubuntu Server, not sure if you did) and yes the default gave me the same error out of the box.

Did you do this part of the instructions?


Add backuppc to the sudoers list

1.       Run “sudo visudo”

2.     At the bottom of the file add

# Allow backuppc to run tar without a password

backuppc ALL=NOPASSWD: /bin/tar

1.       If you are unfamiliar with vi editor: Scroll to the end of last line of the file, press a to start adding text, write magic lines mentioned above, hit esc, type ":w"+enter to save file, ":q" to quit (":q!" to quit without saving changes).


I didn’t change EVERYTING to match those instructions as them seemed older.  I took what seemed to be the important part.. running tar as sudo and applied that to the base-as installed commands.  I do everything via the CGI and for localhost, my TarClientCmd is:

/usr/bin/env LC_ALL=C sudo $tarPath -c -v -f - -C $shareName --totals


By default they only have /etc setup to be backed up, after I got that working, I added a few more directories and it worked fine (well at the next full, it created directories on the incremental, but the files were old so didn’t add them).  I am switching everything over to rsync, thought I was going to start with localhost, but that is next on the list now.  For now TAR is working with no errors.




From: Magnus Larsson [mailto:magnus@vista.se]
Sent: Tuesday, January 29, 2013 08:05
To: backuppc-users@lists.sourceforge.net
Subject: [BackupPC-users] Tar exited with error 512, localhost on Ubuntu 12.10



I just installed backuppc on a new home server, and am now trying to get first of all localhost to work. The system is ubuntu 12.10, and I use tar for localhost backups. When I start a full backup, it runs for a while and then I get an error (from the log file):

2013-01-29 13:47:33 Got fatal error during xfer (Tar exited with error 512 () status)
2013-01-29 13:47:38 Backup aborted (Tar exited with error 512 () status)
And from running (as instructed on the troubleshooting page of the wiki: 
$ sudo -u backuppc /usr/share/backuppc/bin/BackupPC_dump -v -f localhost
(lots of output, then:)
Got fatal error during xfer (Tar exited with error 512 () status)

Some details from my configuration - config.pl:

$Conf{TarFullArgs} = '$fileList+';
$Conf{TarFullArgs} = '$fileList+';
$Conf{TarClientCmd} = 'sudo $tarPath -c -v -f - -C $shareName'
                    . ' --totals';
$Conf{TarClientRestoreCmd} = 'sudo $tarPath -x -p --numeric-owner --same-owner'
                   . ' -v -f - -C $shareName';
$Conf{TarClientPath} = '/bin/tar';

I have edited the TarClientCmd and TarClientRestoreCmd according to the instructions on https://help.ubuntu.com/community/BackupPC. It did not work out of the box.

# $Conf{TarClientCmd} = '/usr/bin/env LC_ALL=C $tarPath -c -v -f - -C $shareName' . ' --totals';

Any ideas on what is wrong? What did I miss?



Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS,
MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current
with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft
MVPs and experts. ON SALE this month only -- learn more at:

BackupPC-users mailing list
List:    https://lists.sourceforge.net/lists/listinfo/backuppc-users
Wiki:    http://backuppc.wiki.sourceforge.net
Project: http://backuppc.sourceforge.net/