5 You can get Ceph software by retrieving Ceph source code and building it yourself.
6 To build Ceph, you need to set up a development environment, compile Ceph,
7 and then either install in user space or build packages and install the packages.
13 .. tip:: Check this section to see if there are specific prerequisites for your
14 Linux/Unix distribution.
16 Before you can build Ceph source code, you need to install several libraries
21 .. note:: Some distributions that support Google's memory profiler tool may use
22 a different package name (e.g., ``libgoogle-perftools4``).
27 Ceph is built using cmake. To build Ceph, navigate to your cloned Ceph
28 repository and execute the following::
35 .. topic:: Hyperthreading
37 You can use ``make -j`` to execute multiple jobs depending upon your system. For
38 example, ``make -j4`` for a dual core processor may build faster.
40 See `Installing a Build`_ to install a build in user space.
45 To build packages, you must clone the `Ceph`_ repository. You can create
46 installation packages from the latest code using ``dpkg-buildpackage`` for
47 Debian/Ubuntu or ``rpmbuild`` for the RPM Package Manager.
49 .. tip:: When building on a multi-core CPU, use the ``-j`` and the number of
50 cores * 2. For example, use ``-j4`` for a dual-core processor to accelerate
54 Advanced Package Tool (APT)
55 ---------------------------
57 To create ``.deb`` packages for Debian/Ubuntu, ensure that you have cloned the
58 `Ceph`_ repository, installed the `Build Prerequisites`_ and installed
61 sudo apt-get install debhelper
63 Once you have installed debhelper, you can build the packages::
65 sudo dpkg-buildpackage
67 For multi-processor CPUs use the ``-j`` option to accelerate the build.
73 To create ``.rpm`` packages, ensure that you have cloned the `Ceph`_ repository,
74 installed the `Build Prerequisites`_ and installed ``rpm-build`` and
77 yum install rpm-build rpmdevtools
79 Once you have installed the tools, setup an RPM compilation environment::
83 Fetch the source tarball for the RPM compilation environment::
85 wget -P ~/rpmbuild/SOURCES/ http://ceph.com/download/ceph-<version>.tar.bz2
87 Or from the EU mirror::
89 wget -P ~/rpmbuild/SOURCES/ http://eu.ceph.com/download/ceph-<version>.tar.bz2
91 Extract the specfile::
93 tar --strip-components=1 -C ~/rpmbuild/SPECS/ --no-anchored -xvjf ~/rpmbuild/SOURCES/ceph-<version>.tar.bz2 "ceph.spec"
95 Build the RPM packages::
97 rpmbuild -ba ~/rpmbuild/SPECS/ceph.spec
99 For multi-processor CPUs use the ``-j`` option to accelerate the build.
101 .. _Ceph: ../clone-source
102 .. _Installing a Build: ../install-storage-cluster#installing-a-build