forked from greenplum-db/gpdb-archive
-
Notifications
You must be signed in to change notification settings - Fork 0
/
README.amazon_linux
67 lines (53 loc) · 2 KB
/
README.amazon_linux
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
# c3.2xlarge is a lower price but powerful dev box for build and test
# try local ssd disk without EBS
# 8 to 16 GB RAM
# 2 to 8 cores CPU
# Select Amazon Linux OS (as opposed to RHEL or CENTOS or Debian etc)
# edit hostname
sudo vim /etc/sysconfig/network
sudo vim /etc/hosts
# add mount points
sudo vim /etc/fstab
# install packages
sudo yum -y install git gcc readline-devel zlib-devel libcurl-devel bzip2-devel bison flex gcc-c++ python-devel openssl-devel libffi-devel libapr-devel libevent-devel
sudo yum -y install perl-ExtUtils-MakeMaker.noarch perl-ExtUtils-Embed.noarch
sudo yum -y install apr-util-devel libxml2-devel libxslt-devel
# edit /etc/sysctl.conf
vm.overcommit_memory = 2
# edit /etc/security/limits.conf
* soft core unlimited
* soft nofile 65536
* hard nofile 65536
* soft nproc 131072
* hard nproc 131072
# edit /etc/grub.conf
add transparent_hugepage=never to kernel boot command line
cat /sys/kernel/mm/transparent_hugepage/enabled
# update blockdev read ahead
/sbin/blockdev --setra 16384 GPDB_DEVICE_NAMES
# reboot host
# pip packages
curl https://bootstrap.pypa.io/get-pip.py | sudo python
sudo pip install --upgrade setuptools wheel paramiko pip lockfile psutil
# configure and build
git clone https://github.com/greenplum-db/gpdb.git
cd gpdb
./configure --with-openssl --with-libxml --with-libxslt --with-python --with-perl
make
sudo make install
. /usr/local/gpdb/greenplum_path.sh
# create init system file with update values
cp $GPHOME/docs/cli_help/gpconfigs/gpinitsystem_test .
mkdir /home/ec2-user/primary
mkdir /home/ec2-user/mirror
mkdir /home/ec2-user/master
# update these line to reflect accurate names
declare -a DATA_DIRECTORY=(/home/ec2-user/primary /home/ec2-user/primary)
declare -a MIRROR_DATA_DIRECTORY=(/home/ec2-user/mirror /home/ec2-user/mirror)
MASTER_DIRECTORY=/home/ec2-user/master
MASTER_HOSTNAME=mydev
MACHINE_LIST_FILE=/home/ec2-user/hostfile_gpinitsystem
# initialize the system
gpssh-exkeys -h `hostname`
echo `hostname` > hostfile_gpinitsystem
gpinitsystem -c gpinitsystem_test