How to use an usb disk with bup save

140 views
Skip to first unread message

Encolpe Degoute

unread,
Jul 30, 2012, 12:38:30 PM7/30/12
to bup-...@googlegroups.com
Hello,

I have to use an USB disk for some backups.

I tried to use these command to make the save on the USB:
/usr/bin/bup index -f /media/USB/bup-edegoute/.bup/bupindex -u /home/edegoute

/usr/bin/bup save -9 -n home-edegoute-weekly -f /media/USB/bup-edegoute/.bup/bupindex  /home/edegoute


And finally everything was saved in my home folder:

du -sh ~/.bup

958M    /home/edegoute/.bup


I don't have enough storage to make a local backup before to push it on the USB device. 
Did I miss something in the documentation that can help me?

Regards,
Encolpe

Stefan Buller

unread,
Jul 30, 2012, 12:51:38 PM7/30/12
to Encolpe Degoute, bup-...@googlegroups.com
You'll either want to
# symlink ~/.bup to your disk
mv ~/.bup /media/DISK/backup
ln -s /media/DISK/backup ~/.bup
# or tell bup to use a different repository
export BUP_DIR=/media/DISK/backup
# or
bup -d/media/DISK/backup

PS. I forgot to include the list last time.

--
Stefan Buller

Avery Pennarun

unread,
Jul 30, 2012, 1:01:32 PM7/30/12
to Stefan Buller, Encolpe Degoute, bup-...@googlegroups.com
On Mon, Jul 30, 2012 at 12:51 PM, Stefan Buller <stefan...@gmail.com> wrote:
> You'll either want to
> # symlink ~/.bup to your disk
> mv ~/.bup /media/DISK/backup
> ln -s /media/DISK/backup ~/.bup
> # or tell bup to use a different repository
> export BUP_DIR=/media/DISK/backup
> # or
> bup -d/media/DISK/backup

Actually, I recommend using the '-r' option instead:

bup index /home/edegoute
bup save -r /media/USB/bup/.bup /home/edegoute

This will save some stuff, like the index, in your local home
directory. That way you can rotate between different usb disks
without losing your index, so it'll run really fast. But the actual
content will be saved to USB.

Also, I don't recommend naming your bupdir after the particular
directory or machine you're backing up; you get better deduplication
if you backup *all* your stuff, even multiple machines, into the same
bupdir. But that's an even more important reason your bupindex should
be on your local disk, not on the USB disk. (You don't need the
bupindex to do a restore, so it's fine if it gets lost when your
computer finally dies.)

Have fun,

Avery

Tony Godshall

unread,
Jul 30, 2012, 8:39:51 PM7/30/12
to Avery Pennarun, Stefan Buller, Encolpe Degoute, bup-...@googlegroups.com
And I assume you mean then that he
should add the -n argument to distinguish,
e.g. -n $(hostname)-home-edegoute

Or perhaps that's too obvious to mention.

Tony

Avery Pennarun

unread,
Jul 30, 2012, 8:47:51 PM7/30/12
to Tony Godshall, Stefan Buller, Encolpe Degoute, bup-...@googlegroups.com
On Mon, Jul 30, 2012 at 8:39 PM, Tony Godshall <to...@of.net> wrote:
> And I assume you mean then that he
> should add the -n argument to distinguish,
> e.g. -n $(hostname)-home-edegoute
>
> Or perhaps that's too obvious to mention.

It was maybe too obvious for me to remember to mention, but it is what
I meant to say :)

Have fun,

Avery

Tim Riemenschneider

unread,
Jul 31, 2012, 1:42:02 PM7/31/12
to bup-...@googlegroups.com, Stefan Buller, Encolpe Degoute

Am Montag, 30. Juli 2012 19:01:32 UTC+2 schrieb apenwarr:

Actually, I recommend using the '-r' option instead:

  bup index /home/edegoute
  bup save -r /media/USB/bup/.bup  /home/edegoute


That reminds me: it could/should be mentioned in the documentation, that one can omit the host-part of "-r host:path"
(I'm not sure about the wording, so no patch yet....)

cu
Tim

Encolpe Degoute

unread,
Aug 1, 2012, 5:05:26 AM8/1/12
to bup-...@googlegroups.com, Stefan Buller, Encolpe Degoute
Perhaps  starting by don' call this option -r/--remote if it does local stuff too. Try -d/--destination.
Something else in new features: the remote/destination option is not allowed with bup index and I had to use both -r and -f options for bup save.

Regards

Tony Godshall

unread,
Aug 1, 2012, 4:55:32 PM8/1/12
to bup-list

>>> Actually, I recommend using the '-r' option instead:
>>>
>>>   bup index /home/edegoute
>>>   bup save -r /media/USB/bup/.bup  /home/edegoute

>> That reminds me: it could/should be mentioned in the documentation, that one can omit the host-part of "-r host:path"
>> (I'm not sure about the wording, so no patch yet....)

> Perhaps  starting by don' call this option -r/--remote if it does local stuff too. Try -d/--destination.

Or think of it as "repository".  "destination" is not a good term since it's only the destination when you are backing up, not when you are restoring


> Something else in new features: the remote/destination option is not allowed with bup index and I had to use both -r and -f options for bup save.

Yes, but index does not involve a remote repository

Tony

Tony Godshall

unread,
Aug 1, 2012, 4:56:26 PM8/1/12
to bup-list
I meant "bup index" not "but index"




--
Best Regards.
This is unedited.
Reply all
Reply to author
Forward
0 new messages