About integrating RDBMS with Hadoop, you can use Sqoop. Look at the below example for the same:
Please follow the below steps to execute the sqoop import command.
Suppose there is a table in MySQL as below,
![image](https://attachment.freshdesk.com/inline/attachment?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpZCI6NDA2MzY0NzM0MSwiZG9tYWluIjoiZWR1cmVrYS5mcmVzaGRlc2suY29tIiwiYWNjb3VudF9pZCI6NDE0NTN9.UCIfAex9R6zwqJvZoX7lBSq3O5Evt2d1dLQmHUUXnyY)
Now, we will import the data from this table to hdfs with the sqoop command.
sqoop import --connect jdbc:mysql://mysqldb.edu.cloudlab.com/edureka --table student --username labuser -P --target-dir sqoop_stu1 -m 1
![image](https://attachment.freshdesk.com/inline/attachment?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpZCI6NDA2MzY0NzM1MCwiZG9tYWluIjoiZWR1cmVrYS5mcmVzaGRlc2suY29tIiwiYWNjb3VudF9pZCI6NDE0NTN9.MxVhk80mQ14IKNvtUFzUSv5ls-TLVuVRcojyL2DbrRg)
![image](https://attachment.freshdesk.com/inline/attachment?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpZCI6NDA2MzY0NzM1MSwiZG9tYWluIjoiZWR1cmVrYS5mcmVzaGRlc2suY29tIiwiYWNjb3VudF9pZCI6NDE0NTN9.KmNaRCQu18qA2LUj_Eoe3Q0c8HNfe1dx91x73wSOHmU)
![image](https://attachment.freshdesk.com/inline/attachment?token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpZCI6NDA2MzY0NzM1MywiZG9tYWluIjoiZWR1cmVrYS5mcmVzaGRlc2suY29tIiwiYWNjb3VudF9pZCI6NDE0NTN9.OECUgGdOF3_q3e1QXo_heftTXzUZBI7YxpOrLT6wekw)
The output will be stored in hdfs in the directory named sqoop_stu1