Scenario: I have a java application which interacts with DB2 database deployed on Linux. The java application is used for basic Extract, Transform and Load operations. We connect to the database using jdbc type-4 driver having the URL :
jdbc:db2://<hostname>:<port>/<databaseName>
Problem: The above approach requires username and password but in our client environment the DB2 database is based on Unix authentication and doesn't require username and password. The UNIX user does not have a password.
Is it possible to access this database with the java application which runs on a different machine? Any sample JDBC code to accomplish this will be appreciated.
If it is not possible to access the database without password then how can we configure the database to have a password?