By default Sqoop does not log details into files. Logs are only emitted on to the terminal.
- Logs are either written to standard out or standard error.
- If we have to capture logs that are written to standard out into a file, then we need to redirect 1
- If we have to capture logs that are written to standard out into a file, then we need to redirect 2
- Typically data generated by the command is redirected to standard out and log messages are redirected to standard error.
Here is an example which redirect data as well as logs of a sqoop eval command.
sqoop eval \ --connect "jdbc:mysql://ms.itversity.com:3306/retail_db" \ --username retail_user \ --password itversity \ --query "SELECT * FROM orders LIMIT 10" 1>query.out 2>query.err