This Confluence has been LDAP enabled, if you are an ASF Committer, please use your LDAP Credentials to login. Any problems file an INFRA jira ticket please.

Child pages
  • How to Contribute

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Install MySQL version 5.1.x with necessary client tools. You can install the server in a different host than your development host if necessary. However, you must have the client tools available on your development host including the JDBC driver, and batch utilities such as mysqldump and mysqlimport.
  • Place the JDBC driver in the third-party lib directory that you created earlier.
  • The location of MySQL server is specified in the build.properties file by the value for the property sqoop.test.mysql.connectstring.host_url. This property defaults to jdbc:mysql://localhost/ which assumes local installation and default port setup. If however your MySQL server is installed on a different host or on a different port you should specify it explicitly as follows:
    Code Block
    sqoop.test.mysql.connectstring.host_url=jdbc:mysql://<mysqlhost>:<port>/
    
  • In order to run the MySQL third-party tests, you would need to configure the database as follows:
    Code Block
    $ mysql -u root -p
    mysql> CREATE DATABASE sqooppasstest;
    mysql> CREATE DATABASE sqooptestdb;
    mysql> use mysql;
    mysql> GRANT ALL PRIVILEGES on sqooppasstest.* TO 'sqooptest'@'localhost' IDENTIFIED BY '12345';
    mysql> GRANT ALL PRIVILEGES ON sqooptestdb.* TO 'yourusername'@'localhost';
    mysql> flush privileges;
    mysql> \q
    
  • Note:
    • If the installation of MySQL server is on a different host, you must replace the localhost with the appropriate client host value.
    • You should replace yourusername with your actual user name before issuing the command.

...

  • Install PostgreSQL 8.3.9 or later along with client tools. You can install the server in a different host than your development host if necessary. However, you must have the client tools available on your development host including the JDBC driver and command line utility psql.
  • Place the JDBC driver in the third-party lib directory that you created earlier.
  • The location of PostgreSQL server is specified in the build.properties file by the value for the property sqoop.test.postgresql.connectstring.host_url. This property defaults to jdbc:postgresql://localhost/ which assumes local installation and default port setup. If however your PostgreSQL server is installed on a different host , enter its location in the build.properties file or on a different port you should specify it explicitly as follows:
    Code Block
    sqoop.test.postgresql.connectstring.host_url=jdbc:postgresql://pgsqlhost<pgsqlhost>:<pgsqlport>/
    
  • In order to run PostgreSQL third-party tests, you would need to configure the database as follows:
    • Edit the pg_hba.conf file and setup the authentication scheme to allow for testing. In a secured environment, it may be easy to setup up full trust based access by adding the following lines in this file, and commenting out any other lines referencing 127.0.0.1 or ::1.
      Code Block
      
      local  all all trust
      host all all 127.0.0.1/32 trust
      host all all ::1/128      trust
      
    • Also in the file postgresql.conf uncomment the line that starts with listen_address and set its value to '*' as follows:
      Code Block
      
      listen_address = '*'
      
    • Restart your PostgreSQL server after modifying the configuration files above.
    • Create the necessary user and database for Sqoop testing as follows:
      Code Block
      
      $ sudo -u postgres psql -U postgres template1
      template1=> CREATE USER sqooptest;
      template1=> CREATE DATABASE sqooptest;
      tempalte1=> \q
      $