Koozali.org: home of the SME Server

Installing backup2 via Yum

Offline Terry

  • ***
  • 46
  • +0/-0
    • http://brummell.net
Installing backup2 via Yum
« on: August 04, 2006, 03:18:48 PM »
How do I do this.  Tried adding repositories and what not, always says it can't find the package.
Anyone have a quick and dirty how-to?

Offline wjhobbs

  • *****
  • 171
  • +0/-0
    • http://www.chryxus.ca
bcakup2 Install How-to
« Reply #1 on: August 04, 2006, 04:41:05 PM »
Hi Terry,

The thing you need to know about backup2 is that it is not in any of the yum repositories.

Here is how I have done it.

How to Install backup2 (for USB) on SME7

Prepare the USB Drive

Using a recent Linux system (e.g., Fedora Core 3 or later, SME7), format the usb drive:

    - Use fdisk to create a partition(s)
    - Use mke2fs to format the partition(s)
         > with the “-j” option to create ext3,
         > use the “-c” option to check the device for bad blocks before creating the file system. If this option is specified twice, then a slower, read-write test is used instead of a fast read-only test. (
WARNING: This read-write operation will take a VERY long time.)
     >specify “-L backup2” to set the partition volume label to read ‘backup2’
- As a precaution, use 'fsck -f' to verify the partition before putting it into use[/list]

After the drive is formatted, plug the device into the SME7 usb port and confirm that it is visible to the system
Code: [Select]
# cat /proc/partitions
and that it has the label ‘backup2’ assigned (the following presumes it was /dev/sda1).
Code: [Select]
# /sbin/e2label /dev/sda1
I use the label in the fstab entry (see below) to avoid having to know which device (e.g., sda1, hdd1) needs to be mounted for the backup2usb job.

Install the Software

Ensure that there is a ‘software’ ibay to hold SME downloaded software.

Download the needed files into the directory ‘backup2’ in the ‘software’ ibay
Code: [Select]
# cd /home/e-smith/files/ibays/software/files/backup2
# wget http://mirror.contribs.org/smeserver/contribs/dmay/smeserver/7.x/rar-3.5.1-7dmay.i386.rpm
# wget http://mirror.contribs.org/smeserver/contribs/dmay/smeserver/7.x/smeserver-backup2-0.0.1-b2dmay.noarch.rpm

Go to that directory:
Code: [Select]
# cd /home/e-smith/files/ibays/software/files/backup2
Install the packages
Code: [Select]
# yum localinstall rar-3.5.1-7dmay.i386.rpm smeserver-backup2-0.0.1-b2dmay.noarch.rpm
and perform
Code: [Select]
# signal-event post-upgrade; signal-event reboot


Create a mountpoint and Setup the fstab Entry

I use ‘/media/backup’ rather than ‘/media/usbdisk’ to avoid any possible confusion with auto-mounted usb devices.

Code: [Select]
# mkdir -p /media/backup

Modify ‘fstab’
Code: [Select]
# cd /etc
Create a three line fstab entry
Code: [Select]
# pico fstab
insert the following lines at the bottom of the fstab file.
Quote
#       The following entry is for the backup usb disk for 'backup2'
LABEL=backup2  /media/backup  auto  noauto,defaults  0  0
#


Save (ctl-o) and exit (ctl-x)

The fstab entry is what backup2 uses to determine where to put the backup files.

The fstab entry, as configured above, says
LABEL=backup2’: for the drive identified as ‘backup2’
/media/backup’: mount the drive on this mountpoint
auto’: detect the file system type rather than having a predetermined one specified
noauto,defaults’: do not automatically mount this device at boot or when it is attached to the system (it will get explicitly mounted by the backup2 script); but use all of the other default mounting options
0’: do not backup this file system
0’: do not attempt to perform a file-system check of this device on boot (because it is a removable device and may not be there)[/list]

Plug in the device and go to the Server-Manager panel to invoke backups, specifying ‘/media/backup’ as the target location for the backup.
...

Offline Terry

  • ***
  • 46
  • +0/-0
    • http://brummell.net
Installing backup2 via Yum
« Reply #2 on: August 04, 2006, 04:56:46 PM »
That would be why I couldn't get it to work!  

OK, but I don't want to use a usb drive.  Hmmm, now that I think about it, a 40 gig disk in a usb housing.  I may just have to give that a whirl.

Offline idyll

  • ****
  • 113
  • +0/-0
backup2 usb
« Reply #3 on: August 04, 2006, 08:38:01 PM »
I suggest adding a monthly crontab entry to perform an e2fsck or you will see errors stating

"EXT3-fs warning: maximal mount count reached, running e2fsck is recommended"

patrick
...

Offline Terry

  • ***
  • 46
  • +0/-0
    • http://brummell.net
Installing backup2 via Yum
« Reply #4 on: August 04, 2006, 08:44:23 PM »
OK, if I didn't want to use a usb disk, what are my "backup to" options?

Offline idyll

  • ****
  • 113
  • +0/-0
poke around
« Reply #5 on: August 04, 2006, 09:07:39 PM »
There is a thread just below this one titled

"need testers for last backuppc contribs"

See if it works for you.

patrick
...

Offline Terry

  • ***
  • 46
  • +0/-0
    • http://brummell.net
Re: poke around
« Reply #6 on: August 04, 2006, 09:26:46 PM »
Quote from: "idyll"
There is a thread just below this one titled

"need testers for last backuppc contribs"

See if it works for you.

patrick

I already read it before deciding to use backup2.  I really trust Daryel's stuff as he's been around SME/E-Smith for as long as I can remember (that's four years or so for me now).  
I'm wondering, within backup2, what are my options?  Need someone who has used it before to pipe up here.  I'll probably end up installing it anyway, but with 18 gigs to backup the included backup just doesn't work for me.  I guess I need to look in to a tape drive.

Offline idyll

  • ****
  • 113
  • +0/-0
backup
« Reply #7 on: August 04, 2006, 09:34:55 PM »
Dungog has a backup utility which uses USB, NFS or a Windows share. Or, they did, I haven't looked in a while.

Otherwise it is as you suggested, time to shop for a DAT.

patrick
...

Offline raem

  • *
  • 3,972
  • +4/-0
Re: poke around
« Reply #8 on: August 05, 2006, 03:09:40 AM »
Terry

> I'm wondering, within backup2, what are my options?  
> I'll probably end up installing it anyway, but with 18 gigs to backup ...

Why don't you just install the contrib, instructions were given earlier, it'll take about 5 minutes in total to download, install & configure.
It's easy to backup 18 Gb by splitting the whole backup job into parts, see the server manager panel for details as it is fairly self explanatory.
You can backup either to workstation hard drives on your network or attached USB drives.
I suggest you keep the part size at 2Gb or less for reliable restores when needed. I size mine at 1.5Gb to fit 3 parts on a DVD and not exceed the DVD max size per file spec.
Search on backup, backup2 & backup2ws for lots of posts on the subject going back a year or two.
...

Offline wjhobbs

  • *****
  • 171
  • +0/-0
    • http://www.chryxus.ca
Installing backup2 via Yum
« Reply #9 on: August 05, 2006, 04:54:35 AM »
Quote from: "Terry"
OK, if I didn't want to use a usb disk, what are my "backup to" options?

You can 'backup2usb' or 'backup2ws'. The usb is self-explanatory. (If you use a usb enclosure, be sure your usb port and the enclosure are usb 2.0 or your 18GB backup will take forever.) The ws refers to workstation and really means a share on another computer on your network.

I have used both. Some others have set up a separate SME server to act as a backup machine and have either an ibay or a user's home directory as the target for the backups.

Give it a shot. Take Ray's advice about the file size parameter if you think you might want to burn the backup to dvd - it defaults to 650MB for those who might want to burn to cd.

John
...

Offline raem

  • *
  • 3,972
  • +4/-0
Installing backup2 via Yum
« Reply #10 on: August 05, 2006, 05:40:55 AM »
Terry

> You can 'backup2usb' or 'backup2ws'.

These are for sme6,
for sme 7 use
smeserver-backup2-0.0.1-b2dmay.noarch.rpm
You can select whether to backup to workstatiuon or usb.

The only issue you may have is if your sme7 does not have
compat-libstdc++-33-3.2.3-47.3.i386.rpm
which is needed.
Search the forums on libstdc or see this link for a yum answer re installing that rpm

http://forums.contribs.org/index.php?topic=30737.0
...

Offline Terry

  • ***
  • 46
  • +0/-0
    • http://brummell.net
Installing backup2 via Yum
« Reply #11 on: August 05, 2006, 03:45:40 PM »
Thanks everyone for the replies.  Backup2 is installed with help from Ray's instructions, and is currently doing a 911 backup to one of my XP boxes.

Daryel, yet another excellent contrib by you.  Thanks to all for the help.