From 11c378185446b50d68e52ac66c74b39693ba41b1 Mon Sep 17 00:00:00 2001 From: Christoph Date: Tue, 27 Feb 2018 04:31:04 +0100 Subject: [PATCH] Some minor changes. --- DOC/README.percona.debian | 22 +++++++++++++++++++++ remove_mariadb_installation.sh | 6 +++--- remove_mysql_installation.sh | 6 +++--- remove_percona_installation.sh | 35 +++++++++++++++++++++++++++++----- 4 files changed, 58 insertions(+), 11 deletions(-) create mode 100644 DOC/README.percona.debian diff --git a/DOC/README.percona.debian b/DOC/README.percona.debian new file mode 100644 index 0000000..a6b3295 --- /dev/null +++ b/DOC/README.percona.debian @@ -0,0 +1,22 @@ + +# - Install MySQL client libraries /libmysqlclient +# - +apt-get install libmariadb-dev libmariadb-dev-compat +apt-get install cpanminus + +apt-get install libdbd-mysql-perl +# - OR /AND +cpanm DBD::mysql + + +# - Fetch the repository packages from web +# - +# - Once you install this package the Percona repositories should be added. +# - You can check the repository setup in the /etc/apt/sources.list.d/percona-release.list file. +# - +cd /tmp +wget https://repo.percona.com/apt/percona-release_0.1-4.$(lsb_release -sc)_all.deb +dpkg -i percona-release_0.1-4.$(lsb_release -sc)_all.deb + +apt-get update +apt-get install percona-server-server-5.7 percona-server-common-5.7 percona-server-client-5.7 diff --git a/remove_mariadb_installation.sh b/remove_mariadb_installation.sh index 920a61d..adc408b 100755 --- a/remove_mariadb_installation.sh +++ b/remove_mariadb_installation.sh @@ -299,9 +299,9 @@ if [[ -n "$CURRENT_VERSION" ]] ; then echo "" - echononl " Remove directory '${working_dir}/log-${CURRENT_VERSION}'.." - if [[ -d "${working_dir}/log-${CURRENT_VERSION}" ]] ; then - rm -r ${working_dir}/log-${CURRENT_VERSION} > $tmp_log_file 2>&1 + echononl " Remove directory '${working_dir}/log-mariadb-${CURRENT_VERSION}'.." + if [[ -d "${working_dir}/log-mariadb-${CURRENT_VERSION}" ]] ; then + rm -r ${working_dir}/log-mariadb-${CURRENT_VERSION} > $tmp_log_file 2>&1 if [[ $? -ne 0 ]] ; then echo_failed error "$(cat $tmp_log_file)" diff --git a/remove_mysql_installation.sh b/remove_mysql_installation.sh index 1e08352..98e2b7a 100755 --- a/remove_mysql_installation.sh +++ b/remove_mysql_installation.sh @@ -299,9 +299,9 @@ if [[ -n "$CURRENT_VERSION" ]] ; then echo "" - echononl " Remove directory '${working_dir}/log-${CURRENT_VERSION}'.." - if [[ -d "${working_dir}/log-${CURRENT_VERSION}" ]] ; then - rm -r ${working_dir}/log-${CURRENT_VERSION} > $tmp_log_file 2>&1 + echononl " Remove directory '${working_dir}/log-mysql-${CURRENT_VERSION}'.." + if [[ -d "${working_dir}/log-mysql-${CURRENT_VERSION}" ]] ; then + rm -r ${working_dir}/log-mysql-${CURRENT_VERSION} > $tmp_log_file 2>&1 if [[ $? -ne 0 ]] ; then echo_failed error "$(cat $tmp_log_file)" diff --git a/remove_percona_installation.sh b/remove_percona_installation.sh index f946560..9471a51 100755 --- a/remove_percona_installation.sh +++ b/remove_percona_installation.sh @@ -227,6 +227,31 @@ else fi +echo "" + + echononl " Remove '/etc/ld.so.conf.d/mysql.conf'.." + if [[ -f "/etc/ld.so.conf.d/mysql.conf" ]]; then + rm /etc/ld.so.conf.d/mysql.conf > $tmp_log_file 2>&1 + if [[ $? -ne 0 ]] ; then + echo_failed + error "$(cat $tmp_log_file)" + else + echo_ok + fi + + echononl " Run ldconfig - configure dynamic linker run-time bindings .." + ldconfig -V > $tmp_log_file 2>&1 + if [[ $? -ne 0 ]] ; then + echo_failed + error "$(cat $tmp_log_file)" + else + echo_ok + fi + else + echo_skipped + fi + + echo "" _failed=false @@ -299,9 +324,9 @@ if [[ -n "$CURRENT_VERSION" ]] ; then echo "" - echononl " Remove directory '${working_dir}/log-${CURRENT_VERSION}'.." - if [[ -d "${working_dir}/log-${CURRENT_VERSION}" ]] ; then - rm -r ${working_dir}/log-${CURRENT_VERSION} > $tmp_log_file 2>&1 + echononl " Remove directory '${working_dir}/log-percona-${CURRENT_VERSION}'.." + if [[ -d "${working_dir}/log-percona-${CURRENT_VERSION}" ]] ; then + rm -r ${working_dir}/log-percona-${CURRENT_VERSION} > $tmp_log_file 2>&1 if [[ $? -ne 0 ]] ; then echo_failed error "$(cat $tmp_log_file)" @@ -313,8 +338,8 @@ if [[ -n "$CURRENT_VERSION" ]] ; then fi echononl " Remove directory '${working_dir}/percona-server-${CURRENT_VERSION}'.." - if [[ -d "${working_dir}/mysql-${CURRENT_VERSION}" ]] ; then - rm -r ${working_dir}/mysql-${CURRENT_VERSION} > $tmp_log_file 2>&1 + if [[ -d "${working_dir}/percona-server-${CURRENT_VERSION}" ]] ; then + rm -r ${working_dir}/percona-server-${CURRENT_VERSION} > $tmp_log_file 2>&1 if [[ $? -ne 0 ]] ; then echo_failed error "$(cat $tmp_log_file)"