Build the source code
NoteCentOS 7 is the recommended Linux development and production platform for YugabyteDB.
Install necessary packages
Update packages on your system, install development tools and additional packages:
sudo apt-get update sudo apt-get install uuid-dev libbz2-dev libreadline-dev maven ninja-build \ cmake curl rsync python3-pip python3-venv zip autoconf libtool \ pkg-config libssl1.0-dev libicu-dev bison flex \ libncurses5-dev
Assuming this repository is checked out in
~/code/yugabyte-db, do the following:
cd ~/code/yugabyte-db ./yb_build.sh release
The above command will build the release configuration, put the C++ binaries in
build/release-gcc-dynamic-ninja, and will also create the
build/latest symlink to that directory.
If you are getting errors in the form of:
uild/release-gcc-dynamic-ninja/postgres_build/src/backend/libpq/be-secure-openssl.o: In function `my_sock_read': src/postgres/src/backend/libpq/be-secure-openssl.c:665: undefined reference to `BIO_get_data' build/release-gcc-dynamic-ninja/postgres_build/src/backend/libpq/be-secure-openssl.o: In function `my_sock_write': src/postgres/src/backend/libpq/be-secure-openssl.c:685: undefined reference to `BIO_get_data'
The code is probably not finding the right path for libssl1.0. Try a clean build
./yb_build.sh --clean release.
If that doesn't work, look into your $PATH if some other openssl version path is being used.
TipYou can find the binaries you just built in
Build Java code
YugabyteDB core is written in C++, but the repository contains Java code needed to run sample applications. To build the Java part, you need:
- JDK 8
- Apache Maven .
Also make sure Maven's bin directory is added to your
PATH (for example, by adding to your
~/.bashrc). See the example below (if you've installed Maven into
For building YugabyteDB Java code, you'll need to install Java and Apache Maven.