Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Note

This walk-thru is targeting developers who want to explore the bleeding edge of Lustre. If you are evaluating Lustre for production, you should choose a Lustre Release.

Purpose

Describe the steps you need to build and test a Lustre system (MGS, MDT, MDS, OSS, OST, client) from the master branch on a x86_64, RHEL/CentOS 7.3 machine.

...

  1. Get the kernel source. First create the directory structure, then get the source from the RPM. Create a .rpmmacros file to install the kernel source in our user directory:

    Code Block
    $ cd $HOME
    $ mkdir -p kernel/rpmbuild/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
    $ cd kernel
    $ echo '%_topdir %(echo $HOME)/kernel/rpmbuild' > ~/.rpmmacros
    
  2. Install the kernel source:

    Code Block
    $ rpm -ivh http://vault.centos.org/7.3.1611/updates/Source/SPackages/kernel-3.10.0-514.2.2.el7.src.rpm

     

     



  3. Prepare the source using rpmbuild:

    Code Block
    $ cd ~/kernel/rpmbuild
    $ rpmbuild -bp --target=`uname -m` ./SPECS/kernel.spec
    


    This will end with:

    Code Block
    ...
    + make ARCH=x86_64 oldnoconfig
    scripts/kconfig/conf --olddefconfig Kconfig
    #
    # configuration written to .config
    #
    + echo '# x86_64'
    + cat .config
    + find . '(' -name '*.orig' -o -name '*~' ')' -exec rm -f '{}' ';'
    + find . -name .gitignore -exec rm -f '{}' ';'
    + cd ..
    + exit 0
    

...

  1. Start building the kernel with rpmbuild:

    Code Block
    $ cd ~/kernel/rpmbuild
    $ buildid="_lustre" # Note: change to any string that identify your work
    $ rpmbuild -ba --with firmware --target x86_64 --with baseonly \
               --define "buildid ${buildid}" \
               ~/kernel/rpmbuild/SPECS/kernel.spec
  2. A successful build will return:

    Code Block
    ...
    ...
    Wrote: /mnt/home/build/kernel/rpmbuild/SRPMS/kernel-3.10.0-514.2.2.el7_lustre.src.rpm
    Wrote: /mnt/home/build/kernel/rpmbuild/RPMS/x86_64/kernel-3.10.0-514.2.2.el7_lustre.x86_64.rpm
    Wrote: /mnt/home/build/kernel/rpmbuild/RPMS/x86_64/kernel-headers-3.10.0-514.2.2.el7_lustre.x86_64.rpm
    Wrote: /mnt/home/build/kernel/rpmbuild/RPMS/x86_64/kernel-debuginfo-common-x86_64-3.10.0-514.2.2.el7_lustre.x86_64.rpm
    Wrote: /mnt/home/build/kernel/rpmbuild/RPMS/x86_64/perf-3.10.0-514.2.2.el7_lustre.x86_64.rpm
    Wrote: /mnt/home/build/kernel/rpmbuild/RPMS/x86_64/perf-debuginfo-3.10.0-514.2.2.el7_lustre.x86_64.rpm
    Wrote: /mnt/home/build/kernel/rpmbuild/RPMS/x86_64/python-perf-3.10.0-514.2.2.el7_lustre.x86_64.rpm
    Wrote: /mnt/home/build/kernel/rpmbuild/RPMS/x86_64/python-perf-debuginfo-3.10.0-514.2.2.el7_lustre.x86_64.rpm
    Wrote: /mnt/home/build/kernel/rpmbuild/RPMS/x86_64/kernel-tools-3.10.0-514.2.2.el7_lustre.x86_64.rpm
    Wrote: /mnt/home/build/kernel/rpmbuild/RPMS/x86_64/kernel-tools-libs-3.10.0-514.2.2.el7_lustre.x86_64.rpm
    Wrote: /mnt/home/build/kernel/rpmbuild/RPMS/x86_64/kernel-tools-libs-devel-3.10.0-514.2.2.el7_lustre.x86_64.rpm
    Wrote: /mnt/home/build/kernel/rpmbuild/RPMS/x86_64/kernel-tools-debuginfo-3.10.0-514.2.2.el7_lustre.x86_64.rpm
    Wrote: /mnt/home/build/kernel/rpmbuild/RPMS/x86_64/kernel-devel-3.10.0-514.2.2.el7_lustre.x86_64.rpm
    Wrote: /mnt/home/build/kernel/rpmbuild/RPMS/x86_64/kernel-debuginfo-3.10.0-514.2.2.el7_lustre.x86_64.rpm
    Executing(%clean): /bin/sh -e /var/tmp/rpm-tmp.F7X9cL
    + umask 022
    + cd /mnt/home//build/kernel/rpmbuild/BUILD
    + cd kernel-3.10.0-514.2.2.el7
    + rm -rf /mnt/home/build/kernel/rpmbuild/BUILDROOT/kernel-3.10.0-514.2.2.el7_lustre.x86_64
    + exit 0

 


Info

If you receive a request to generate more entropy, you need to trigger some disk I/O or keyboard I/O. In another terminal, you can either type randomly or execute the following command to generate entropy:

Code Block
# grep -Ri 'entropy' /usr

...

Code Block
# yum localinstall *.x86_64.rpm

 


Disable SELinux (Lustre Servers)

...