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

AMBARI-23149. Installation of MySQL fails on CentOS 7.2, should install mariadb #555

Merged
merged 1 commit into from Mar 6, 2018
Merged
Show file tree
Hide file tree
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
Expand Up @@ -301,12 +301,7 @@
<osFamily>redhat7</osFamily>
<packages>
<package>
<name>mysql-community-release</name>
<skipUpgrade>true</skipUpgrade>
<condition>should_install_mysql</condition>
</package>
<package>
<name>mysql-community-server</name>
<name>mariadb-server</name>
<skipUpgrade>true</skipUpgrade>
<condition>should_install_mysql</condition>
</package>
Expand Down
Expand Up @@ -27,10 +27,11 @@
def get_daemon_name():
import status_params

for possible_daemon_name in status_params.POSSIBLE_DAEMON_NAMES:
daemon_path = os.path.join(status_params.SERVICES_DIR, possible_daemon_name)
if os.path.exists(daemon_path):
return possible_daemon_name
for service_file_template in status_params.SERVICE_FILE_TEMPLATES:
for possible_daemon_name in status_params.POSSIBLE_DAEMON_NAMES:
daemon_path = service_file_template.format(possible_daemon_name)
if os.path.exists(daemon_path):
return possible_daemon_name

raise Fail("Could not find service daemon for mysql")

Expand Down
Expand Up @@ -69,7 +69,8 @@
webhcat_pid_file = format('{hcat_pid_dir}/webhcat.pid')

process_name = 'mysqld'
SERVICES_DIR = '/etc/init.d'

SERVICE_FILE_TEMPLATES = ['/etc/init.d/{0}', '/usr/lib/systemd/system/{0}.service']
POSSIBLE_DAEMON_NAMES = ['mysql', 'mysqld', 'mariadb']


Expand Down
Expand Up @@ -70,12 +70,7 @@
<osFamily>redhat7</osFamily>
<packages>
<package>
<name>mysql-community-release</name>
<skipUpgrade>true</skipUpgrade>
<condition>should_install_mysql</condition>
</package>
<package>
<name>mysql-community-server</name>
<name>mariadb-server</name>
<skipUpgrade>true</skipUpgrade>
<condition>should_install_mysql</condition>
</package>
Expand Down
Expand Up @@ -84,12 +84,7 @@
<osFamily>redhat7</osFamily>
<packages>
<package>
<name>mysql-community-release</name>
<skipUpgrade>true</skipUpgrade>
<condition>should_install_mysql</condition>
</package>
<package>
<name>mysql-community-server</name>
<name>mariadb-server</name>
<skipUpgrade>true</skipUpgrade>
<condition>should_install_mysql</condition>
</package>
Expand Down
Expand Up @@ -55,12 +55,7 @@
<osFamily>redhat7</osFamily>
<packages>
<package>
<name>mysql-community-release</name>
<skipUpgrade>true</skipUpgrade>
<condition>should_install_mysql</condition>
</package>
<package>
<name>mysql-community-server</name>
<name>mariadb-server</name>
<skipUpgrade>true</skipUpgrade>
<condition>should_install_mysql</condition>
</package>
Expand Down
Expand Up @@ -179,12 +179,7 @@
<osFamily>redhat7</osFamily>
<packages>
<package>
<name>mysql-community-release</name>
<skipUpgrade>true</skipUpgrade>
<condition>should_install_mysql</condition>
</package>
<package>
<name>mysql-community-server</name>
<name>mariadb-server</name>
<skipUpgrade>true</skipUpgrade>
<condition>should_install_mysql</condition>
</package>
Expand Down