Secure (encrypted) offsite backup needed

Status
Not open for further replies.

Robert Trevellyan

Pony Wrangler
Joined
May 16, 2014
Messages
3,778
Not new, but I've been using HashBackup with B2 for most of the intervening period, and remain satisfied with both.
 

Robert Trevellyan

Pony Wrangler
Joined
May 16, 2014
Messages
3,778
I experimented with backup from my Mac to a USB-attached hard drive when I was getting the hang of the program, but that's all.

HashBackup maintains a local cache, which you can regard as a local backup if you don't impose a size limit on it.
 

ccdanieldb

Dabbler
Joined
Oct 26, 2016
Messages
29
I've been using duplicacy and B2.

I looked at duplicacy and the cli version looks like it is free and updated regularly. Do you have a source for an install on freenas how to? I tried to install it as per the website wiki but when I try to run it I get a permission denied prompt. I have never used (go) before and have no idea if the install went well. I was running it inside a jail on the freenas that has the files I want to backup. I plan to just push an encrypted backup to an other freenas on my home network.
 

fracai

Guru
Joined
Aug 22, 2012
Messages
1,212
While I have compiled some changes from source, all I did for FreeNAS was download the FreeBSD binary and stick it in my home folder. You probably just need to give it executable permission:
Code:
chmod +x path/to/duplicacy

The binary is self contained so it can even be run from a FreeNAS cron task. I've been happy so far.
If you're just pushing to another local FreeNAS, why not use replication?
 

ccdanieldb

Dabbler
Joined
Oct 26, 2016
Messages
29
While I have compiled some changes from source, all I did for FreeNAS was download the FreeBSD binary and stick it in my home folder. You probably just need to give it executable permission:
Code:
chmod +x path/to/duplicacy

The binary is self contained so it can even be run from a FreeNAS cron task. I've been happy so far.
If you're just pushing to another local FreeNAS, why not use replication?

The output needs to be encrypted data that I can store anywhere. I had a second FreeNAS box in my parents house I set it up with an OpenVPN connection back in late 2015 and just let rsync do a daily update from my home FreeNAS. It worked fine until... In any case, I got the box back a few days ago. I wiped all the drives and re-flashed the bios. I am starting over now and want an option that will let me backup encrypted data to the second FreeNAS and I will upload that encrypted data to the cloud. I use the out of the box encryption that comes with zfs but I need to be able to back up the encrypted data in its encrypted state. I have setup Arq 5 on a local windows 10 box but it is very slow. I was hoping that using a native app on the FreeNAS box and backing up to another local FreeNAS box would be faster. Duplicacy seems to be just the thing I need. Rclone will not back up to a local box with encryption. Unless someone can show me how to trick the cloud backup app in FreeNAS into thinking my second FreeNAS box is a cloud service.
 

ccdanieldb

Dabbler
Joined
Oct 26, 2016
Messages
29
Help, I can't figure this out. How do I get from

pkg install wget
pkg install go
go get -u github.com/gilbertchen/duplicacy/...
go build -v /root/go/src/github.com/gilbertchen/duplicacy/duplicacy/duplicacy_main.go
chmod +x /root/go/bin/duplicacy

To running duplicacy.

root@duplicacy:~/go/bin # duplicacy
duplicacy: Command not found.
root@duplicacy:~/go/bin # ./ duplicacy
./: Permission denied.

I am running this on a FreenNAS ver-11.1-U5 jail.
 

ccdanieldb

Dabbler
Joined
Oct 26, 2016
Messages
29
LOL. I am not sure why this is happing but please see for your self. I must have been misspelling it before. I am sure I also tried ./duplicacy and also sure it did not work several hours ago.
Code:
/root/go/bin/duplicacy

is working now.

root@duplicacy:/ # cd /root/go/bin/
root@duplicacy:/go/bin # ls
duplicacy duplicacy_main
root@duplicacy:/go/bin # duplicacy
duplicacy: Command not found.
root@duplicacy:/go/bin # /duplicacy
/duplicacy: Permission denied.
root@duplicacy:/go/bin # /root/go/bin/duplicacy
NAME:
duplicacy - A new generation cloud backup tool based on lock-free deduplication

USAGE:
duplicacy [global options] command [command options] [arguments...]

VERSION:
2.1.0

COMMANDS:
init Initialize the storage if necessary and the current directory as the repository
backup Save a snapshot of the repository to the storage
restore Restore the repository to a previously saved snapshot
list List snapshots
check Check the integrity of snapshots
cat Print to stdout the specified file, or the snapshot content if no file is specified
diff Compare two snapshots or two revisions of a file
history Show the history of a file
prune Prune snapshots by revision, tag, or retention policy
password Change the storage password
add Add an additional storage to be used for the existing repository
set Change the options for the default or specified storage
copy Copy snapshots between compatible storages
info Show the information about the specified storage
help, h Shows a list of commands or help for one command

GLOBAL OPTIONS:
-verbose, -v show more detailed information
-debug, -d show even more detailed information, useful for debugging
-log enable log-style output
-stack print the stack trace when an error occurs
-no-script do not run script before or after command execution
-background read passwords, tokens, or keys only from keychain/keyring or env
-profile address:port enable the profiling tool and listen on the specified address:port
-comment add a comment to identify the process
-help, -h show help

root@duplicacy:~/go/bin #
 

ccdanieldb

Dabbler
Joined
Oct 26, 2016
Messages
29
While I have compiled some changes from source, all I did for FreeNAS was download the FreeBSD binary and stick it in my home folder. You probably just need to give it executable permission:
Code:
chmod +x path/to/duplicacy

The binary is self contained so it can even be run from a FreeNAS cron task. I've been happy so far.
If you're just pushing to another local FreeNAS, why not use replication?

Do you run duplicacy within a Jail?

I am still having some trouble. It looks like duplicacy can't see the directory I am executing it in. Please see below. Again this is in a freenas jail. I have given the jail read/wright permissions to files/folders I am trying to backup.

root@duplicacy:/mnt/Stuff # /root/go/bin/duplicacy init -e Stuff sftp://Daniel@10.0.1.64:/mnt/RaidZ3/Stuff Failed to retrieve the current working directory: stat .: not a directory
root@duplicacy:/mnt/Stuff #

also I can only get
Code:
/root/go/bin/duplicacy
to run outside of the bin folder. Is this a permissions issue?
 

fracai

Guru
Joined
Aug 22, 2012
Messages
1,212
I just realized that you're working this in a duplicacy ticket as well. And it sounds like you got things working there.
Any questions remaining?
 

ccdanieldb

Dabbler
Joined
Oct 26, 2016
Messages
29
I have moved forward a bit.
Code:
directory: stat .: not a directory

was caused by the jail dropping the attached fileset. I restarted the jail and regained access to the local mounted files.

I still do not understand why
Code:
/root/go/bin/duplicacy

works and
Code:
./duplicacy

dose not work.
 

fracai

Guru
Joined
Aug 22, 2012
Messages
1,212
When you execute "/root/go/bin/duplicacy" are you in the "/root/go/bin/" directory? What is the output of "pwd" when "./duplicacy" fails?
 

ccdanieldb

Dabbler
Joined
Oct 26, 2016
Messages
29
Yes thank you. I got it running in the jail. The steps are below incase anyone has the same issue.

Ok got it running by downloading the prebuilt exe. Here are the steps.

Code:
pkg install wget
Needed to download a file on my system. You may have it installed already.
Code:
pkg install go
Not sure if I needed it but I got it anyway.
Code:
mkdir /root/go/

Code:
mkdir /root/go/bin/

Code:
cd /root/go/bin/

Code:
wget https://github.com/gilbertchen/duplicacy/releases/download/v2.1.0/duplicacy_freebsd_x64_2.1.0

Code:
mv duplicacy_freebsd_x64_2.1.0 duplicacy
Changes name to duplicacy. The .0 at the end of the original file was preventing it from running not sure why.
Code:
chmod +x duplicacy
Makes the file executable.
Code:
./duplicacy
Runs the file in this directory.
Code:
/root/go/bin/duplicacy
Runs the file in any other directory.
 
Status
Not open for further replies.
Top