How to backup freePBX to USB Drive

I want to know how to backup my freepbx to a USB HARDDRIVE or flashdrive any idea ?

The backups are in /var/lib/asterisk/backups/ and the backups are monolithic and self dated. You could mount a formatted USB disk on one of the existing directories and still use the GUI

can someone please give me step by step how to back to to external drive since I never did it and I do not know were to begin ?

With respect, your monicker is linuxman, You ask about the absolute basics of linux and how it handles it’s filesytem, are you sure that is appropriate?

Plug in your USB stick,

cat /proc/partitions

note your USB stick , maybe by its size. You will need to partition it to suit so

man fdisk

will help you there. Having partitioned your stick you will need to format it. To familiarize yourself as to how formatting works in linux:-

man mkfs

Having a formatted USB stick you will need to “mount” it, to familiarize yourself with how mount works:-

man mount

As I told you before you then need to mount the usb stick onto your filesystem. At a very basic level and if your USB stick is /dev/sdc:-

mount /dev/sdc1 /var/lib/asterisk/backups

You can add that into /etc/fstab if you want it to be there over a reboot, again

man fstab

will hone your skills,

When you run a backup from FreePBX then the result will be written to your USB stick.

If you want an image of your whole system investigate “mondoarchive”, which can create a bootable usb stick for a bare metal restore into almost any other hardware without bringing your working system down for second.

1 Like

First line is the funniest thing I’ve heard all day. Thanks Dicko for the laugh!