Skip to content

Build and Install

Archie L. Cobbs edited this page Jun 13, 2019 · 9 revisions

Important Note

Please ignore the "Releases" thing that Github automatically creates for every source control tag without my knowledge or ability to stop them.

Instead, download the actual release distributions from the Downloads wiki page.

You can tell an actual release distribution because it contains a ./configure script.

Requirements

s3backer requires the following additional packages:

Name Description Home Page
libcurl-devel HTTP library for C http://curl.haxx.se/
fuse-devel User-space filesystems http://fuse.sourceforge.net/
libopenssl-devel Encryption library http://www.openssl.org/
zlib-devel Compression library http://www.zlib.net/
libexpat-devel XML parsing library http://expat.sourceforge.net/
pkg-config Software library manager http://pkgconfig.freedesktop.org/

On various different systems, these may be already installed and/or have different package names.

Requirements On Ubuntu

This should be all that's required for Ubuntu:

$ sudo apt-get install libcurl4-openssl-dev libfuse-dev libexpat1-dev libssl-dev zlib1g-dev pkg-config

Requirements On Mac OS X

Use Homebrew to install s3backer on Mac OS X. Note that for unknown reason the package is named s3-backer (with a dash).

Installing Using Pre-Built RPMs

If you are running openSUSE or a few other Linux variants, you can find pre-built RPMs in the usual places.

Building And Installing From Distribution Source

Like lots of other software packages, s3backer uses GNU Autoconf for its build process so once you have installed the other required packages, building and installing s3backer is usually as easy as:

$ ./configure
$ make
$ sudo make install

Building Distribution Source From Github Source

If you've cloned the Github project, to build the distribution source tarball you'll need autoconf, automake, etc. installed, then:

$ ./autogen.sh
$ ./configure
$ make dist

FUSE Configuration

If you want to allow normal users to mount s3backer filesystems, you need to add the user_allow_other option to /etc/fuse.conf. It must be on a line by itself.

For example:

$ sudo sh -c 'echo user_allow_other >> /etc/fuse.conf'

Setting up /etc/fstab

You can have your s3backer disk mounted automatically via /etc/fstab.

But first: WARNING there is a bug (see #9869 and #1741) in systemd that causes this to not work. The symptom is that all attempts to access the disk will hang. The fact that this bug has existed for almost four years doesn't reflect well on the project.

When it did used to work, here is how I did it:

s3backer#mybucket  /mnt/s3b      fuse  size=1t,blockSize=256k,encrypt,compress=9,passwordFile=/etc/s3backer_cryptkey,accessFile=/etc/s3backer_passwd,prefix=host123-,blockCacheSize=2500,blockCacheFile=/opt/s3backer-cachefile,blockCacheWriteDelay=15000,blockCacheThreads=4,blockCacheRecoverDirtyBlocks,timeout=90,_netdev,x-systemd.requires=firewalld.service 0 0
/mnt/s3b/file      /mnt/bigdisk  ext4  noauto,loop,discard,noatime,nodiratime,_netdev,x-systemd.requires=mnt-s3b.mount 0 0
Clone this wiki locally