mirror of
https://github.com/MariaDB/server.git
synced 2025-01-29 18:20:07 +01:00
1e7a68f84a
Both RPM and DEB now conflicts on previous versions of MCS. Trim .deb packaging. MCS now depends on python. Python version varies in distributions.
29 lines
605 B
Bash
29 lines
605 B
Bash
#!/bin/bash
|
|
|
|
set -e
|
|
|
|
if [ "$1" = "purge" ]; then
|
|
rm -rf /var/lib/columnstore
|
|
rm -rf /etc/columnstore
|
|
rm -f /etc/mysql/mariadb.conf.d/columnstore.cnf.rpmsave
|
|
fi
|
|
|
|
running_systemd() {
|
|
if [ "$(ps --no-headers -o comm 1)" = "systemd" ]; then
|
|
echo 0
|
|
else
|
|
echo 1
|
|
fi
|
|
}
|
|
|
|
if [ ! -z "$(pgrep -x mysqld)" ];then
|
|
systemctl cat mariadb.service > /dev/null 2>&1
|
|
if [ $? -eq 0 ] && [ $(running_systemd) -eq 0 ]; then
|
|
systemctl restart mariadb.service > /dev/null 2>&1
|
|
else
|
|
pkill mysqld > /dev/null 2>&1
|
|
/usr/bin/mysqld_safe &
|
|
fi
|
|
fi
|
|
|
|
#DEBHELPER#
|