Commit 99499629 authored by iSergio's avatar iSergio
Browse files

Add change semaphores for slaves

parent 039c5f04
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -99,3 +99,11 @@ cp -rf tsearch_data/* /usr/share/pgsql/tsearch_data/
if [[ "$TYPE" == "primary" ]]; then
    pg_replication -c -t
fi

if [[ "$TYPE" == "standby" ]]; then
    sysctl -w kernel.sem="250 32000 100 200"
    echo "250 32000 100 200" > /proc/sys/kernel/sem
    if ! grep -Fq "kernel.sem" /etc/sysctl.conf; then
        echo "kernel.sem = 250 32000 100 200" >> /etc/sysctl.conf
    fi
fi