2012-09-26 20:47:29 +00:00
|
|
|
========================
|
2012-05-03 17:45:08 +00:00
|
|
|
Installing RPM Packages
|
2012-09-26 20:47:29 +00:00
|
|
|
========================
|
2012-05-03 17:45:08 +00:00
|
|
|
|
2012-09-26 20:47:29 +00:00
|
|
|
You may install stable release packages (for stable deployments),
|
|
|
|
development release packages (for the latest features), or development
|
|
|
|
testing packages (for development and QA only). Do not add multiple
|
|
|
|
package sources at the same time.
|
2012-05-03 17:45:08 +00:00
|
|
|
|
2013-01-08 04:51:04 +00:00
|
|
|
Install Release Key
|
|
|
|
===================
|
|
|
|
|
|
|
|
Packages are cryptographically signed with the ``release.asc`` key. Add our
|
|
|
|
release key to your system's list of trusted keys to avoid a security warning::
|
|
|
|
|
2013-02-09 05:09:20 +00:00
|
|
|
sudo rpm --import 'https://ceph.com/git/?p=ceph.git;a=blob_plain;f=keys/release.asc'
|
|
|
|
|
2013-01-08 04:51:04 +00:00
|
|
|
|
2013-07-20 19:26:14 +00:00
|
|
|
Install Prerequisites
|
|
|
|
=====================
|
|
|
|
|
|
|
|
Ceph may require additional additional third party libraries.
|
|
|
|
To add the EPEL repository, execute the following::
|
|
|
|
|
|
|
|
su -c 'rpm -Uvh http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm'
|
|
|
|
|
2013-07-20 20:10:54 +00:00
|
|
|
Some releases of Ceph require the following packages:
|
2013-07-20 19:26:14 +00:00
|
|
|
|
|
|
|
- snappy
|
|
|
|
- leveldb
|
|
|
|
- gdisk
|
|
|
|
- python-argparse
|
|
|
|
- gperftools-libs
|
|
|
|
|
|
|
|
To install these packages, execute the following::
|
|
|
|
|
|
|
|
sudo yum install snappy leveldb gdisk python-argparse gperftools-libs
|
|
|
|
|
|
|
|
|
2013-01-08 04:51:04 +00:00
|
|
|
Add Release Packages
|
|
|
|
====================
|
|
|
|
|
|
|
|
|
2013-08-14 14:59:24 +00:00
|
|
|
Dumpling
|
|
|
|
--------
|
|
|
|
|
|
|
|
Dumpling is the most recent stable release of Ceph. These packages are
|
2013-01-08 04:51:04 +00:00
|
|
|
recommended for anyone deploying Ceph in a production environment.
|
|
|
|
Critical bug fixes are backported and point releases are made as necessary.
|
2012-05-03 17:45:08 +00:00
|
|
|
|
2013-08-14 14:59:24 +00:00
|
|
|
Packages are currently built for the RHEL/CentOS6 (``el6``), Fedora 18 and 19
|
|
|
|
(``f18`` and ``f19``), OpenSUSE 12.2 (``opensuse12.2``), and SLES (``sles11``)
|
|
|
|
platforms. The repository package installs the repository details on your local
|
|
|
|
system for use with ``yum`` or ``up2date``.
|
|
|
|
|
|
|
|
For example, for CentOS 6 or other RHEL6 derivatives (``el6``)::
|
|
|
|
|
|
|
|
su -c 'rpm -Uvh http://ceph.com/rpm-dumpling/el6/noarch/ceph-release-1-0.el6.noarch.rpm'
|
|
|
|
|
|
|
|
You can download the RPMs directly from::
|
|
|
|
|
|
|
|
http://ceph.com/rpm-dumpling
|
|
|
|
|
|
|
|
|
|
|
|
Cuttlefish
|
|
|
|
----------
|
|
|
|
|
|
|
|
Cuttlefish is the previous recent major release of Ceph. These packages are
|
|
|
|
recommended for those who have already deployed bobtail in production and are
|
|
|
|
not yet ready to upgrade.
|
|
|
|
|
2013-01-08 04:51:04 +00:00
|
|
|
Packages are currently built for the RHEL/CentOS6 (``el6``), Fedora 17
|
|
|
|
(``f17``), OpenSUSE 12 (``opensuse12``), and SLES (``sles11``)
|
|
|
|
platforms. The repository package installs the repository details on
|
|
|
|
your local system for use with ``yum`` or ``up2date``.
|
2012-05-03 17:45:08 +00:00
|
|
|
|
2013-05-07 03:16:23 +00:00
|
|
|
For example, for CentOS 6 or other RHEL6 derivatives (``el6``)::
|
|
|
|
|
2013-07-20 19:26:14 +00:00
|
|
|
su -c 'rpm -Uvh http://ceph.com/rpm-cuttlefish/el6/noarch/ceph-release-1-0.el6.noarch.rpm'
|
2013-05-07 03:16:23 +00:00
|
|
|
|
|
|
|
You can download the RPMs directly from::
|
|
|
|
|
|
|
|
http://ceph.com/rpm-cuttlefish
|
|
|
|
|
|
|
|
|
|
|
|
Bobtail
|
|
|
|
-------
|
|
|
|
|
2013-08-14 14:59:24 +00:00
|
|
|
Bobtail is the second major release of Ceph. These packages are
|
2013-05-07 03:16:23 +00:00
|
|
|
recommended for those who have already deployed bobtail in production and
|
|
|
|
are not yet ready to upgrade.
|
|
|
|
|
|
|
|
Packages are currently built for the RHEL/CentOS6 (``el6``), Fedora 17
|
|
|
|
(``f17``), OpenSUSE 12 (``opensuse12``), and SLES (``sles11``)
|
|
|
|
platforms. The repository package installs the repository details on
|
|
|
|
your local system for use with ``yum`` or ``up2date``.
|
|
|
|
|
2013-07-09 01:11:25 +00:00
|
|
|
Replace the``{DISTRO}`` below with the distro codename::
|
2013-01-08 04:51:04 +00:00
|
|
|
|
|
|
|
su -c 'rpm -Uvh http://ceph.com/rpm-bobtail/{DISTRO}/x86_64/ceph-release-1-0.el6.noarch.rpm'
|
|
|
|
|
|
|
|
For example, for CentOS 6 or other RHEL6 derivatives (``el6``)::
|
|
|
|
|
|
|
|
su -c 'rpm -Uvh http://ceph.com/rpm-bobtail/el6/x86_64/ceph-release-1-0.el6.noarch.rpm'
|
|
|
|
|
|
|
|
You can download the RPMs directly from::
|
|
|
|
|
|
|
|
http://ceph.com/rpm-bobtail
|
|
|
|
|
|
|
|
|
|
|
|
Development Release Packages
|
|
|
|
----------------------------
|
2012-05-03 17:45:08 +00:00
|
|
|
|
2012-09-27 22:02:42 +00:00
|
|
|
Our development process generates a new release of Ceph every 3-4 weeks. These
|
|
|
|
packages are faster-moving than the stable releases. Development packages have
|
2012-09-26 20:47:29 +00:00
|
|
|
new features integrated quickly, while still undergoing several weeks of QA
|
|
|
|
prior to release.
|
|
|
|
|
2012-09-27 22:02:42 +00:00
|
|
|
Packages are cryptographically signed with the ``release.asc`` key. Add our
|
|
|
|
release key to your system's list of trusted keys to avoid a security warning::
|
2012-09-26 20:47:29 +00:00
|
|
|
|
2013-02-09 05:09:20 +00:00
|
|
|
sudo rpm --import 'https://ceph.com/git/?p=ceph.git;a=blob_plain;f=keys/autobuild.asc'
|
2012-09-26 20:47:29 +00:00
|
|
|
|
2012-09-27 22:02:42 +00:00
|
|
|
Packages are currently built for the CentOS-6 and Fedora 17 platforms. The
|
|
|
|
repository package installs the repository details on your local system for use
|
|
|
|
with ``yum`` or ``up2date``.
|
2012-09-26 20:47:29 +00:00
|
|
|
|
2012-09-27 22:02:42 +00:00
|
|
|
For CentOS-6::
|
2012-09-26 20:47:29 +00:00
|
|
|
|
2012-09-27 21:00:40 +00:00
|
|
|
su -c 'rpm -Uvh http://ceph.com/rpms/el6/x86_64/ceph-release-1-0.el6.noarch.rpm'
|
2012-09-26 20:47:29 +00:00
|
|
|
|
2012-09-27 22:02:42 +00:00
|
|
|
For Fedora 17::
|
2012-09-26 20:47:29 +00:00
|
|
|
|
2012-09-27 21:00:40 +00:00
|
|
|
su -c 'rpm -Uvh http://ceph.com/rpms/fc17/x86_64/ceph-release-1-0.fc17.noarch.rpm'
|
2012-09-26 20:47:29 +00:00
|
|
|
|
2013-01-08 04:51:04 +00:00
|
|
|
You can download the RPMs directly from::
|
|
|
|
|
|
|
|
http://ceph.com/rpm-testing
|
|
|
|
|
2013-07-09 01:11:25 +00:00
|
|
|
|
2013-07-20 19:26:14 +00:00
|
|
|
|
|
|
|
Installing Ceph Deploy
|
|
|
|
======================
|
|
|
|
|
|
|
|
Once you have added either release or development packages to ``yum``, you
|
2013-07-20 20:10:54 +00:00
|
|
|
can install ``ceph-deploy``. ::
|
2013-07-20 19:26:14 +00:00
|
|
|
|
2013-07-20 20:10:54 +00:00
|
|
|
sudo yum install ceph-deploy python-pushy
|
2013-07-20 19:26:14 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
2013-07-09 01:11:25 +00:00
|
|
|
Installing Ceph Packages
|
|
|
|
========================
|
2012-09-26 20:47:29 +00:00
|
|
|
|
2012-09-27 22:02:42 +00:00
|
|
|
Once you have added either release or development packages to ``yum``, you
|
2013-07-20 19:26:14 +00:00
|
|
|
can install Ceph packages. You can also use ``ceph-deploy`` to install Ceph
|
|
|
|
packages. ::
|
2012-09-26 20:47:29 +00:00
|
|
|
|
|
|
|
sudo yum install ceph
|
2013-07-09 01:11:25 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Installing Ceph Object Storage
|
|
|
|
==============================
|
|
|
|
|
|
|
|
:term:`Ceph Object Storage` runs on Apache and FastCGI in conjunction with the
|
|
|
|
:term:`Ceph Storage Cluster`.
|
|
|
|
|
|
|
|
#. Install Apache and FastCGI. ::
|
|
|
|
|
|
|
|
rpm -ivh fcgi-2.4.0-10.el6.x86_64.rpm
|
|
|
|
rpm -ivh mod_fastcgi-2.4.6-2.el6.rf.x86_64.rpm
|
|
|
|
|
|
|
|
|
|
|
|
#. Install the Ceph Object Storage daemon. ::
|
|
|
|
|
|
|
|
yum install ceph-radosgw
|
|
|
|
|
|
|
|
|
|
|
|
#. Add the following lines to your Ceph configuration file.
|
|
|
|
|
|
|
|
.. code-block:: ini
|
|
|
|
|
|
|
|
[client.radosgw.gateway]
|
|
|
|
host = {fqdn}
|
|
|
|
keyring = /etc/ceph/keyring.radosgw.gateway
|
|
|
|
rgw socket path = /tmp/radosgw.sock
|
|
|
|
log file = /var/log/ceph/radosgw.log
|
|
|
|
rgw print continue = false
|
|
|
|
|
|
|
|
.. note:: Replace ``{fqdn}`` with the output from ``hostname``. This is
|
|
|
|
important. Debian systems use the simple hostname, but on CentOS 6/RHEL 6
|
|
|
|
you must use the fully qualified domain name.
|
|
|
|
|
|
|
|
#. Create a data directory. ::
|
|
|
|
|
|
|
|
mkdir -p /var/lib/ceph/radosgw/ceph-radosgw.gateway
|
|
|
|
|
|
|
|
|
|
|
|
#. Change ``httpd ServerName`` in ``/etc/httpd/conf/httpd.conf``. ::
|
|
|
|
|
|
|
|
ServerName {FQDN}
|
|
|
|
|
|
|
|
|
2013-09-17 17:39:24 +00:00
|
|
|
#. Create an Apache httpd virtual host in ``/etc/httpd/conf.d/rgw.conf``. ::
|
2013-07-09 01:11:25 +00:00
|
|
|
|
|
|
|
FastCgiExternalServer /var/www/s3gw.fcgi -socket /tmp/radosgw.sock
|
|
|
|
<VirtualHost *:80>
|
|
|
|
ServerName <FQDN of the host>
|
|
|
|
ServerAdmin root@localhost
|
|
|
|
DocumentRoot /var/www
|
|
|
|
RewriteEngine On
|
|
|
|
RewriteRule ^/([a-zA-Z0-9-_.]*)([/]?.*) /s3gw.fcgi?page=$1¶ms=$2&%{QUERY_STRING} [E=HTTP_AUTHORIZATION:%{HTTP:Authorization},L]
|
|
|
|
<IfModule mod_fastcgi.c>
|
|
|
|
<Directory /var/www>
|
|
|
|
Options +ExecCGI
|
|
|
|
AllowOverride All
|
|
|
|
SetHandler fastcgi-script
|
|
|
|
Order allow,deny
|
|
|
|
Allow from all
|
|
|
|
AuthBasicAuthoritative Off
|
|
|
|
</Directory>
|
|
|
|
</IfModule>
|
|
|
|
AllowEncodedSlashes On
|
|
|
|
ErrorLog /var/log/httpd/error.log
|
|
|
|
CustomLog /var/log/httpd/access.log combined
|
|
|
|
ServerSignature Off
|
|
|
|
</VirtualHost>
|
|
|
|
|
|
|
|
#. Turn off ``fastcgiwrapper`` in ``/etc/httpd/conf.d/fastcgi.conf`` by
|
|
|
|
commenting out the following line::
|
|
|
|
|
|
|
|
#FastCgiWrapper On
|
|
|
|
|
|
|
|
|
2013-09-17 17:34:47 +00:00
|
|
|
#. Add a ``fastcgi`` script with the following path ``/var/www/s3gw.fcgi``. ::
|
2013-07-09 01:11:25 +00:00
|
|
|
|
|
|
|
#!/bin/sh
|
|
|
|
exec /usr/bin/radosgw -c /etc/ceph/ceph.conf -n client.radosgw.gateway
|
|
|
|
|
|
|
|
|
|
|
|
#. Make ``s3gw.fcgi`` executable::
|
|
|
|
|
2013-09-17 17:34:47 +00:00
|
|
|
chmod +x /var/www/s3gw.fcgi
|
2013-07-09 01:11:25 +00:00
|
|
|
|
|
|
|
|
|
|
|
#. Create a user key. ::
|
|
|
|
|
|
|
|
ceph-authtool -C -n client.radosgw.gateway --gen-key /etc/ceph/keyring.radosgw.gateway
|
2013-07-19 17:04:40 +00:00
|
|
|
ceph-authtool -n client.radosgw.gateway --cap mon 'allow rw' --cap osd 'allow rwx' /etc/ceph/keyring.radosgw.gateway
|
2013-07-09 01:11:25 +00:00
|
|
|
ceph auth add client.radosgw.gateway --in-file=/etc/ceph/keyring.radosgw.gateway
|
|
|
|
|
|
|
|
|
|
|
|
#. Please make sure ``/etc/ceph/keyring.radosgw.gateway`` file and
|
|
|
|
``/var/log/ceph/radosgw.log`` are accessible by the ``apache`` user. ::
|
|
|
|
|
|
|
|
sudo chown apache:apache /etc/ceph/keyring.radosgw.gateway
|
|
|
|
sudo chown apache:apache /var/log/ceph/radosgw.log
|
|
|
|
|
|
|
|
.. note:: This is important. The user is ``root`` for Debian.
|
|
|
|
|
|
|
|
|
|
|
|
#. Create ``.rgw.buckets`` and add it to the Ceph Object Storage daemon. ::
|
|
|
|
|
|
|
|
rados mkpool .rgw.buckets
|
|
|
|
radosgw-admin pool add --pool .rgw.buckets
|
|
|
|
|
|
|
|
#. Configure Apache and the Ceph Object Storage daemon to start on boot. ::
|
|
|
|
|
|
|
|
chkconfig httpd on
|
|
|
|
chkconfig ceph-radosgw on
|
|
|
|
|
|
|
|
#. Start the services. ::
|
|
|
|
|
|
|
|
/etc/init.d/httpd start
|
|
|
|
/etc/init.d/ceph-radosgw start
|
|
|
|
|
|
|
|
See `Ceph Object Storage`_ for additional details.
|
|
|
|
|
|
|
|
.. _Ceph Object Storage: ../../radosgw
|