Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mount disk in kubemark earlier #35102

Merged
merged 1 commit into from
Oct 19, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 2 additions & 6 deletions test/kubemark/start-kubemark-master.sh
Original file line number Diff line number Diff line change
Expand Up @@ -48,16 +48,12 @@ function mount-master-pd() {
# persistent data, and link them to where they're used.
mkdir -p "${mount_point}"

device=$1
mountpoint=$2

# Format only if the disk is not already formatted.
if ! tune2fs -l "${pd_path}" ; then
echo "Formatting '${pd_path}'"
mkfs.ext4 -F -E lazy_itable_init=0,lazy_journal_init=0,discard "${pd_path}"
fi

mkdir -p "${mount_point}"
echo "Mounting '${pd_path}' at '${mount_point}'"
mount -o discard,defaults "${pd_path}" "${mount_point}"
echo "Mounted master-pd '${pd_path}' at '${mount_point}'"
Expand All @@ -78,6 +74,8 @@ function mount-master-pd() {
fi
}

mount-master-pd

if [ "${EVENT_STORE_IP}" == "127.0.0.1" ]; then
# Retry starting etcd to avoid pulling image errors.
retry sudo docker run --net=host \
Expand All @@ -101,8 +99,6 @@ retry sudo docker run --net=host \
# Increase the allowed number of open file descriptors
ulimit -n 65536

mount-master-pd

tar xzf kubernetes-server-linux-amd64.tar.gz

kubernetes/server/bin/kube-scheduler --master=127.0.0.1:8080 $(cat scheduler_flags) &> /var/log/kube-scheduler.log &
Expand Down