Backing up my files

minshew

New Member


Messages: 7

Hi Folks,

I have a raspberry pi running FreeBSD that is booted off of a USB

I need to backup the current FreeBSD operating system and all of its files and contents to a second USB that I am plugging into the raspberry pi.

Currently, I am looking through the manual and seeing the cp command and I have seen something about ls /dev/da* but when I list this I have five da* devices.

Any ideas about how I can backup my files onto a second USB?
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 12,342
Messages: 38,859

I am looking through the manual and seeing the cp command and I have seen something about ls /dev/da* but when I list this I have five da* devices.
You cannot simply use cp(1) to copy from one device to another, cp(1) only works with filesystems, not raw devices. If you really want to copy raw devices you will need to use dd(1). This will make a bit-for-bit copy. Which is often not really what you need as it may pose other problems if the destination is a different size than the original. For proper backups, assuming you used UFS, use dump(8)/restore(8). If you want to make file level backups, use tar(1) or rsync(1), both have slightly different usage, it depends on how you want to access those backup files.
 

gpw928

Aspiring Daemon

Reaction score: 243
Messages: 557

I need to backup the current FreeBSD operating system and all of its files and contents to a second USB that I am plugging into the raspberry pi.
Do you want to be able to boot your FreeBSD installation from the second USB stick?

Is the second USB stick the same size as the first?

Once we know the answers to those questions, the options will clarify.
 
Top