This repository has been archived by the owner on Jul 23, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 327
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
HAWQ-1780. Add GitHub Action Step to Test against Running Instance
It fixes the install_name of libhdfs and libyarn with @rpath prefix, which is required when loading executable in different path, and enforces searching headers and libraries in those self-contained first.
- Loading branch information
1 parent
a8c0940
commit 4cbd805
Showing
7 changed files
with
201 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
#!/bin/bash | ||
# Licensed to the Apache Software Foundation (ASF) under one or more | ||
# contributor license agreements. See the NOTICE file distributed with | ||
# this work for additional information regarding copyright ownership. | ||
# The ASF licenses this file to You under the Apache License, Version 2.0 | ||
# (the "License"); you may not use this file except in compliance with | ||
# the License. You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
set -e | ||
|
||
|
||
|
||
# Configure | ||
tee $GPHOME/etc/hawq-site.xml << EOF_hawq_site | ||
<configuration> | ||
<property> | ||
<name>hawq_dfs_url</name> | ||
<value>localhost:8020/hawq_default</value> | ||
<description>URL for accessing HDFS.</description> | ||
</property> | ||
<property> | ||
<name>hawq_master_address_host</name> | ||
<value>localhost</value> | ||
</property> | ||
<property> | ||
<name>hawq_master_address_port</name> | ||
<value>5432</value> | ||
</property> | ||
<property> | ||
<name>hawq_segment_address_port</name> | ||
<value>40000</value> | ||
</property> | ||
<property> | ||
<name>hawq_master_directory</name> | ||
<value>/tmp/db_data/hawq-data-directory/masterdd</value> | ||
</property> | ||
<property> | ||
<name>hawq_segment_directory</name> | ||
<value>/tmp/db_data/hawq-data-directory/segmentdd</value> | ||
</property> | ||
<property> | ||
<name>hawq_master_temp_directory</name> | ||
<value>/tmp</value> | ||
</property> | ||
<property> | ||
<name>hawq_segment_temp_directory</name> | ||
<value>/tmp</value> | ||
</property> | ||
</configuration> | ||
EOF_hawq_site | ||
|
||
# Initialize | ||
rm -rf /opt/dependency* | ||
rm -rf /tmp/db_data/hawq-data-directory | ||
install -d /tmp/db_data/hawq-data-directory/masterdd | ||
install -d /tmp/db_data/hawq-data-directory/segmentdd | ||
hawq init cluster -a |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
#!/bin/bash | ||
# Licensed to the Apache Software Foundation (ASF) under one or more | ||
# contributor license agreements. See the NOTICE file distributed with | ||
# this work for additional information regarding copyright ownership. | ||
# The ASF licenses this file to You under the Apache License, Version 2.0 | ||
# (the "License"); you may not use this file except in compliance with | ||
# the License. You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
set -e | ||
|
||
|
||
|
||
# Configure | ||
tee $HADOOP_HOME/etc/hadoop/core-site.xml << EOF_core_site | ||
<configuration> | ||
<property> | ||
<name>fs.defaultFS</name> | ||
<value>hdfs://localhost:8020</value> | ||
</property> | ||
</configuration> | ||
EOF_core_site | ||
tee $HADOOP_HOME/etc/hadoop/hdfs-site.xml << EOF_hdfs_site | ||
<configuration> | ||
<property> | ||
<name>dfs.namenode.name.dir</name> | ||
<value>file:///tmp/db_data/hdfs/name</value> | ||
</property> | ||
<property> | ||
<name>dfs.datanode.data.dir</name> | ||
<value>file:///tmp/db_data/hdfs/data</value> | ||
</property> | ||
</configuration> | ||
EOF_hdfs_site | ||
|
||
# Initialize | ||
install -d /tmp/db_data/hdfs/name | ||
install -d /tmp/db_data/hdfs/data | ||
hdfs namenode -format | ||
|
||
# Start | ||
$HADOOP_HOME/sbin/start-dfs.sh | ||
|
||
# Connect | ||
hdfs dfsadmin -report | ||
hdfs dfs -ls / |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
#!/bin/bash | ||
# Licensed to the Apache Software Foundation (ASF) under one or more | ||
# contributor license agreements. See the NOTICE file distributed with | ||
# this work for additional information regarding copyright ownership. | ||
# The ASF licenses this file to You under the Apache License, Version 2.0 | ||
# (the "License"); you may not use this file except in compliance with | ||
# the License. You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
set -e | ||
|
||
|
||
|
||
# Setup passphraseless ssh | ||
sudo systemsetup -setremotelogin on | ||
ssh-keygen -t rsa -P '' -f ~/.ssh/id_rsa | ||
cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys | ||
chmod 0700 ~/.ssh | ||
chmod 0600 ~/.ssh/authorized_keys | ||
|
||
tee -a ~/.ssh/config <<EOF_ssh_config | ||
Host * | ||
StrictHostKeyChecking no | ||
UserKnownHostsFile=/dev/null | ||
EOF_ssh_config | ||
|
||
ssh -v localhost whoami | ||
|
||
# Configure system kernel state | ||
sudo tee /etc/sysctl.conf << EOF_sysctl | ||
kern.sysv.shmmax=2147483648 | ||
kern.sysv.shmmin=1 | ||
kern.sysv.shmmni=64 | ||
kern.sysv.shmseg=16 | ||
kern.sysv.shmall=524288 | ||
kern.maxfiles=65535 | ||
kern.maxfilesperproc=65536 | ||
kern.corefile=/cores/core.%N.%P | ||
EOF_sysctl | ||
</etc/sysctl.conf xargs sudo sysctl | ||
|
||
# Add data folder | ||
sudo install -o $USER -d /tmp/db_data/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters