Member since
03-14-2016
4721
Posts
1111
Kudos Received
874
Solutions
My Accepted Solutions
Title | Views | Posted |
---|---|---|
2442 | 04-27-2020 03:48 AM | |
4877 | 04-26-2020 06:18 PM | |
3975 | 04-26-2020 06:05 PM | |
3217 | 04-13-2020 08:53 PM | |
4923 | 03-31-2020 02:10 AM |
08-28-2019
05:51 AM
@Manoj690 Try this: First switch to "root" user using "su - " then from "root" user account run the "su - hdfs" command. # su -
# su - hdfs
... View more
08-28-2019
05:48 AM
@Manoj690 Looks like you have marked an incorrect post as "Solution" which simply has an Error posted. the post which you have marked as solution simple contains the below error message which makes no sense: ERROR manager.SqlManager: Error executing statement: java.sql.SQLException: Access denied for user 'root'@'hostname' (using password: NO) . Please be careful while marking a post as solution ..
... View more
08-28-2019
05:44 AM
1 Kudo
@Manoj690 Looks like your previous error is resolved. For the new error better you shoudl have opened a new thread to avoid confusion for other readers of the thread. I see the new error is HDFS related (and completely unrelated to Mysql related error which you originally reported to this thread) 19/08/28 18:06:43 ERROR tool.ImportTool: Import failed: org.apache.hadoop.security.AccessControlException: Permission denied: user=gaian, access=WRITE, inode="/user":hdfs:hdfs:drwxr-xr-x For the HDFS error you will need to make sure that the user "gaian" who is running the sqoop job does not have thw write permission on . "/user" directory. You might be able fix it by doing this: # su - hdfs
# hdfs dfs -mkdir /user/gaian
# hdfs dfs -chown -R gaian:hadoop /user/gaian
# hdfs dfs -chmod -R 755 /user/gaian . If your question is answered then, Please make sure to mark the answer as the accepted solution. If you find a reply useful, say thanks by clicking on the thumbs up button.
... View more
08-28-2019
05:29 AM
1 Kudo
@Manoj690 As i mentioned in the other thread opened by you for the similar error. https://community.cloudera.com/t5/Support-Questions/Sqoop-jdbc-error/m-p/269108#M206636 As your latest error is ERROR manager.SqlManager: Error executing statement: java.sql.SQLException: Access denied for user 'ambari1'@'localhost' (using password: NO) . Which means you will need to make sure following 2 things: 1. First thing is that you are entering correct password for "ambari1" user in the sqoop command . using "--password" option. 2. Also make sure to add the Grant as following for the root user in MySQL DB so that it can connect to mysql from the host where you are running the sqoop command. Example: mysql> GRANT ALL PRIVILEGES ON *.* TO 'ambari1'@'localhost' IDENTIFIED BY 'XXXXXXXXXX' WITH GRANT OPTION;
mysql> FLUSH PRIVILEGES; Please replace the "XXXXXXXXXX' in the above command with your ambari1 password. Please share the output of the following command shows the entry for 'amabri1' user with host 'localhost' # mysql -u root -p
Enter Password: <YOUR_PASSWORD>
mysql> use mysql;
mysql> select user, host FROM user;
... View more
08-28-2019
12:36 AM
@vinodnerella It depends based on the scenario that how much Heap you should be allocating for the Zookeeper. In your case if you are keep noticing that the Zookeeper heap is reaching to its max 1GB then it is better to increase the Zookeeper heap to a larger value and if needed then enable GC logging for zookeeper to monitor the gc usages in a period of time to findout the approximate heap that you need to setup for your zookeeper based on the environment requirement. As you have already set the Zookeeper heap to 4GB it should be good for now. We can monitor it for some time. The common cause of Zookeeper OutOfMemory can be when clients submit requests faster than ZooKeeper can process them, especially if there are a lot of clients. The it can lead to OOM errors. You can also take a look into parameters like "zookeeper.snapCount" but better to monitor Zookeeper with 4GB heap for some time before tuning such parameters.
... View more
08-28-2019
12:24 AM
@Manoj690 Looks like you have marked an incorrect answer as "Solution" in this thread. .
... View more
08-28-2019
12:23 AM
@Manoj690 As your latest error is ERROR manager.SqlManager: Error executing statement: java.sql.SQLException: Access denied for user 'root'@'hostname' (using password: NO) Which means you will need to make sire that you are entering correct password for "root" user in the sqoop command . using "--password" option. Also make sure to add the Grant as following for the root user in MySQL DB so that it can connect to mysql from the host where you are running the sqoop command. Example: mysql> GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'XXXXXXXXXX' WITH GRANT OPTION; Please share the output of the following command # mysql -u root -p
Enter Password: <YOUR_PASSWORD>
mysql> use mysql;
mysql> select user, host FROM user;
... View more
08-28-2019
12:17 AM
@Manoj690 Are you sure that you have downloaded the "mysql-connector-java.jar" of version 5.7 (not version 😎 ? because i see that as per: https://dev.mysql.com/doc/connector-j/8.0/en/connector-j-api-changes.html The name of the class that implements java.sql.Driver in MySQL Connector/J has changed from com.mysql.jdbc.Driver to com.mysql.cj.jdbc.Driver. The old class name has been deprecated. So in order to test your JDBC driver please try to run the following command to see if it is listing the driver details? # javap -cp /usr/hdp/sqoop-client/lib/mysql-connector-java.jar com.mysql.jdbc.Driver Or can you download the MySQL connector version 5.x. from https://dev.mysql.com/downloads/connector/j/5.1.html
... View more
08-28-2019
12:10 AM
@Manoj690 Yes, in the " jdbc:mysql://xxxxx:3306/dbname" DB url "xxxxx" is MySQL Server hostname and the "dbname" will be the database which you are trying to connect inside MySQL.
... View more
08-28-2019
12:06 AM
@Manoj690 You will need to make sure that the "mysql-connector-java.jar" is placed inside the "/usr/hdp/sqoop-client/lib" directory. Also your SQOOP command seems to have incorrect mysql JDBC URL is not in correct format "jdbc:mysql://xxxxx:3306/dbname" # sqoop import --connect jdbc:mysql://xxxxx:3306/dbname --username root --password XXXXXXXXX --table emp --m 1
... View more