-
Notifications
You must be signed in to change notification settings - Fork 24
Migration tool
zguo edited this page Mar 29, 2017
·
4 revisions
Using the harvester tool, you can migrate metadata records from geoportal server 1.x to geoportal 2.x, following are the details:
- There is a working Geoportal 1.2.x database
- There is a working Geoportal 2.5.x instance
- There is a working Harvester 2.x instance
1. Define JNDI connection
- Go to the Harvester META-INF folder (e.g. C:\Program Files\Apache Software Foundation\Tomcat 8.0\webapps\harvester\META-INF)
- Open context.xml
- Enter JNDI info for the geoportal 1.2.x database, below is an example:
<Context path="/harvester">
<Resource name="jdbc/gpt" auth="Container" type="javax.sql.DataSource"
driverClassName="org.postgresql.Driver"
url="jdbc:postgresql://gpt1:5432/postgres"
username="geoportal"
password="*****"
maxActive="20"
maxIdle="10"
maxWait="-1" />
</Context>
- Save the file
- You will also need to copy appropriate jdbc driver to the Tomcat lib folder if not there already
- restart harvester application
2. Create Migration Tool broker
- Click "Brokers" on the left > Input brokers > Add
- Select a broker type "Migration Tool"
- Enter necessary information, e.g.
- Title: frommygeoportal1
- JNDI: the name of JNDI defined previously (e.g. jdbc/gpt)
- Submit
3. Create output broker
- Click "Brokers" on the left > Output brokers > Add
- Select a broker type (e.g. Geoportal Server 2.x)
- Enter necessary information, e.g.
- Title: myoutputgeoportal2
- URL: url to the geoportal 2 instance, e.g. http://gpt1:8080/geoportal2
- User name:
- User password:
- Index:
- Submit
4. Create harvest task
- Click on "Tasks" on the left > Tasks > Add
- Select the previously defined migration tool broker as input
- Select the previously defined geoportal 2 instance as output
- Submit
5. Run harvest task
- Click on "Tasks" on the left
- Click on "run" link for the migration task on the list
- Check "Ignore robots.txt" and Click on "Ok" to run the task
- Submit
6. Check results
- Click "Home" on the left
- Check the status of current running tasks in the "Processes" section
- When the status shown as "completed", click "Tasks" on the left
- Click "history" link for the task to show the harvest result
- Open geoportal 2 instance (e.g. http://gpt1:8080/geoportal2/) and do a search to see if the metadata is harvested.
Note
- When running the migration tool, while the metadata from geoportal 1.x will be harvested to geoportal 2, the registered sites defined in geoportal 1.x will be migrated as input brokers in harvester, if use want to harvest from those sites after migration, user can create tasks to associate those input brokers and geoportal 2 output broker, and either schedule the task to run regularly or run it manually.
- There is a cleanup option in geoportal 2.x output broker, when used with in the migration tool, the option is for synchronizing updates after the initial migration, it synchronizes metadata created through metadata editor or uploaded metadata, for metadata harvested from registered sites, suggest to synchronize using the harvester task within the new harvester after migration.