You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ambari.apache.org by "Vitaly Brodetskyi (JIRA)" <ji...@apache.org> on 2013/12/26 12:55:51 UTC
[jira] [Resolved] (AMBARI-4175) ambari-server reset doesn't work
for MySQL as Ambari DB
[ https://issues.apache.org/jira/browse/AMBARI-4175?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Vitaly Brodetskyi resolved AMBARI-4175.
---------------------------------------
Resolution: Fixed
> ambari-server reset doesn't work for MySQL as Ambari DB
> -------------------------------------------------------
>
> Key: AMBARI-4175
> URL: https://issues.apache.org/jira/browse/AMBARI-4175
> Project: Ambari
> Issue Type: Bug
> Components: agent
> Affects Versions: 1.4.3
> Reporter: Vitaly Brodetskyi
> Assignee: Vitaly Brodetskyi
> Fix For: 1.4.3
>
> Attachments: AMBARI-4175.patch
>
>
> *STR:*
> *STR:*
> 1. Install and start MySQL server on first host of cluster.
> 2. Create MySQL DB:
> {code}
> mysql -u root
> CREATE DATABASE ambari;
> quit
> {code}
> 3. Create user and grant all privileges to him:
> {code}
> mysql -u root
> CREATE USER 'ambari'@'localhost' IDENTIFIED BY 'bigdata';
> GRANT ALL PRIVILEGES ON *.* TO 'ambari'@'bigdata';
> FLUSH PRIVILEGES;
> quit
> {code}
> 4. Install Ambari server.
> 5. Install mysql-connector-java.
> 6. Perform "ambari-server setup".
> 7. Perform "ambari-server reset -s --verbose".
> *Actual result:*
> {code}
> Using python /usr/bin/python2.6
> Resetting ambari-server
> INFO: about to run command: ps -p 13453
> **** WARNING **** You are about to reset and clear the Ambari Server database. This will remove all cluster host and configuration information from the database. You will be required to re-configure the Ambari server and re-run the cluster wizard.
> Are you SURE you want to perform the reset [yes/no] (yes)?
> Confirm server reset [yes/no](yes)?
> Resetting the Server database...
> INFO: Loading properties from /etc/ambari-server/conf/ambari.properties
> INFO: Loading properties from /etc/ambari-server/conf/ambari.properties
> INFO: about to run command: type mysql
> INFO: about to run command: which mysql
> INFO: about to run command: type mysql
> INFO: about to run command: which mysql
> INFO: about to run command: /usr/bin/mysql --host=localhost --port=3306 --user=ambari --password=bigdata ambari -e"set @schema='ambari'; set @username='ambari'; source /var/lib/ambari-server/resources/Ambari-DDL-MySQL-DROP.sql;"
> INFO: about to run command: type mysql
> INFO: about to run command: which mysql
> INFO: about to run command: /usr/bin/mysql --host=localhost --port=3306 --user=ambari --password=bigdata ambari -e"set @schema='ambari'; set @username='ambari'; source /var/lib/ambari-server/resources/Ambari-DDL-MySQL-CREATE.sql;"
> INFO: about to run command: ps -p 13453
> Ambari Server 'reset' completed successfully.
> {code}
> But next "ambari-server setup" fails with messages:
> {code}
> ERROR 1050 (42S01) at line 29 in file: '/var/lib/ambari-server/resources/Ambari-DDL-MySQL-CREATE.sql': Table 'clusters' already exists
> ERROR: Database bootstrap failed. Please, provide correct connection properties.
> ERROR: Exiting with exit code 1. Reason: Error while configuring connection properties. Exiting
> {code}
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)