...
Currently supported database version: Postgres 9 and 10, Greenplum 4.3 and 5.X.
Anchor | ||||
---|---|---|---|---|
|
To set up PostgreSQL + MADlib with Anaconda Python on OSX:
Code Block |
---|
PYTHON=/Users/janedoe/anaconda/bin/python brew install postgresql --with-python brew services start postgresql — — Set up database and roles — — Install the .dmg of latest madlib downloaded from MADlib website http://madlib.incubator.apache.org/download.html /usr/local/madlib/bin/madpack -s madlib -p postgres install |
Anchor | ||||
---|---|---|---|---|
|
Prerequisites
Install and configure your database of choice. MADlib currently supports the following platforms:
...
Postgres:
Code Block language bash /usr/local/madlib/bin/madpack -s madlib –p postgres install-check
Greenplum Database:
Code Block language bash /usr/local/madlib/bin/madpack –p greenplum install-check
The above may need user/port/password setting depending on how the database has been configured.
Please note that if the optimizer_control GUC is set to off in Greenplum, the following install checks will fail, and these MADlib functions will not work: decision tree, random forest, LDA , k-Means, PMML export for decision tree, PMML export for random forest. This will be fixed in a future release (MADLIB-1109). The parameter optimizer_control controls whether the server configuration parameter optimizer can be changed. The parameter optimizer controls whether the GPORCA optimizer is enabled when running SQL queries.
Anchor | ||||
---|---|---|---|---|
|
Prerequisites
Requirements for installing MADlib:
- gcc and g++ (For OSX, Clang will work for compiling the source, but not for documentation.)
- m4
- patch
- cmake
- pgxn installed
- PostgreSQL (64-bit) 9.2+ with plpython support enabled. Note: plpython may not be enabled in Postgres by default.
Use below command to install and load the latest MADlib package uploaded on PGXN.
Code Block | ||
---|---|---|
| ||
pgxn install madlib pgxn load madlib |
If you see the following error, it's likely that you are using Parallel Execution flags for make.
Code Block | ||
---|---|---|
| ||
[ 86%] Performing build step for 'EP_boost' Ignored: make [ 86%] Performing install step for 'EP_boost' Ignored: make [ 86%] Completed 'EP_boost' [ 86%] Built target EP_boost make[1]: *** [all] Error 2 make: *** [all] Error 2 ERROR: command returned 2: make PG_CONFIG=/usr/local/pg10/bin/pg_config all |
You can run this as a workaround:
Code Block | ||
---|---|---|
| ||
MAKEFLAGS='-j1' pgxn install madlib pgxn load madlib |
Anchor | ||||
---|---|---|---|---|
|
Prerequisites
Requirements for installing MADlib:
...
To install:
Code Block language bash $BUILD_ROOT/src/bin/madpack -p postgres -c [user[/password]@][host][:port][/database] install
To make sure that the installation is successful:
Code Block language bash $BUILD_ROOT/src/bin/madpack -p postgres -c [user[/password]@][host][:port][/database] install-check
For more information on the usage of madpack:
Code Block language bash $BUILD_ROOT/src/bin/madpack --help
Anchor | ||||
---|---|---|---|---|
|
The variables below will be automatically used by the madpack
installer if no connection string is provided:
...
Code Block | ||
---|---|---|
| ||
export PGPORT=5430 export PGHOST=127.0.0.1 export PGDATABASE=madlibtest $BUILD_ROOT/src/bin/madpack -p postgres install |
Anchor | ||||
---|---|---|---|---|
|
- Download the MADlib binary
- Greenplum database : Download the .gppkg binary from Pivotal Network
...
- Greenplum Database:
Upgrading gppkg to a higher version of MADlib:
For example, upgrading from 1.15.1 to 1.16on Redhat / CentOS run the following as gpadmin:
Code Block language bash gppkg -u <madlib_package_upgrading_to>
Upgrade the MADlib deployment in the database
Code Block language bash madpack -p <platform> -c <connection> upgrade
Upgrading gppkg for the same version of MADlib:
For example, upgrading from madlib_gppkg_1.16+1 to madlib_gppkg_1.16+2on Redhat / CentOS run the following as gpadmin:
Code Block language bash gppkg -u <madlib_package_upgrading_to>
MADlib deployment in the database does not need to be upgraded as the MADlib version has not changed.
Anchor | ||||
---|---|---|---|---|
|
Sometimes there are release specific variations of the installation procedures. These exceptions are listed in this section.
...