Export and import a Web content library

 

+

Search Tips   |   Advanced Search

 


Overview

You can export the contents of a Web content library to disk and also import a previously exported library. This feature enables you to make a backup copy of a Web content library and can also be used to move data between servers.

Before you begin, create an empty shared directory to hold the exported Web content library. If moving data between servers, both systems must have write access to this directory.


Export and import a Web content library versus syndication

Library export/import does not replace the syndication feature. Although this feature can be used to transfer data between servers, it is a manual process and is not meant to be used for regular updates between servers. Syndication should be used to automatically keep two or more servers synchronized.


Limitations of exporting and importing a Web content library.


Personalization components.

For Personalization rules created directly in Personalization you will also need to export and import your rules to and from the same servers as your Web content. To do this, you use the same process as moving Portal content from a staging system to a production system. Personalization export and import must be performed prior to exporting and importing Web content.


JSP components

For JSP components you will also need to copy any related JSP files to and from the same servers that you are using for exporting and importing.


Disable JCR text search.

IBM recommends disabling JCR text search indexing on the portal server before exporting or importing large libraries. Doing this will dramatically reduce the load on the database during export and import. To do this, edit...

...and set...

After the file is updated, restart your server for the changes to take effect. When you have completed exporting or importing your library then enable JCR text search again. It may take some time to rebuild the indexes when you re-enable JCR text search indexing.


Export and import large libraries

When importing Web content libraries, a temporary directory is used to store the library files during the upload process. If the size of the uploaded files exceeds the available disk space for the temporary directory, the import operation fails. When uploading large libraries, ensure that there is sufficient disk space to accommodate the import.

The location of the temporary directory is specified by the property...

...in...

When exporting or importing large libraries, increase the total transaction lifetime timeout and the maximum transaction timeout of your server to 360 seconds through the administrative console....


Export and import a Web content library

The server that the data is being exported from is called the source server, and the server that the data is being imported into is called the target server:

  1. Update...

      PROFILE_HOME/PortalServer/wcm/config/wcm60_conf.xml

    ...on both the source and target servers. Confirm that the following properties in the init section are set as specified, modifying the properties if necessary:

    ExportDir Directory on the source server where the exported data will be written.
    ImportDir Directory from where the exported data will be read when importing the data to the target server.

    If exporting and importing across a network, this can be the same directory as the one specified in "ExportDir". Otherwise, copy the exported data from the "ExportDir" to the "ImportDir" before running the import task in step 4.

    SourceServerPort The host name and port for the source server. By default, the port is 10040.
    TargetServerPort The host name and port for the target server. By default, the port is 10040.
    ExportUserId If the source administrator is not the default (wpsadmin), set this value to the source administrator short name.
    ExportPassword Set this value to the source administrator password.
    ImportUserId If the target administrator is not the default (wpsadmin), set this value to the target administrator short name.
    ImportPassword Set this value to the target administrator password.
    WebLib The name of the Web content library to transfer. If exporting multiple libraries enter each library name separated by a comma.

    For example...

      <property name="WebLib" value="Lib_1,Lib_2,Lib_3"/>
    WebLibProperty Set the value for this property to icm:title .

  2. Export the Web content library from the source server.

    1. Open a command prompt on the source server.

    2. Run...

        cd profile_root/ConfigEngine
        ./ConfigEngine.sh export-wcm-data -DPortalAdminPwd=password -DWasPassword=password

    3. Verify that this transfer step completed without errors.

      If any errors occurred, check the portal logs on the target server for extended diagnostic information.

    4. Verify that the export directories were populated correctly.

  3. Import the Web content library to the target server.

    1. Open a command prompt on the target server.

    2. Run...

        cd profile_root/ConfigEngine.
        ./ConfigEngine.sh import-wcm-data -DPortalAdminPwd=password -DWasPassword=password

      ...where profile_root is the name of the IBM WAS profile where WebSphere Portal is installed; for example, wp_profile.

    3. Verify that this transfer step completed without errors.

      If any errors occurred, check the portal logs on the target server for extended diagnostic information.

  4. Reset the Web content event log.

  5. Restart the server.

  6. To ensure all scheduled actions are reset, from the server you imported the libraries onto.

    To reschedule all libraries...

      cd profile_root/ConfigEngine
      ./ConfigEngine.sh run-wcm-admin-task-schedule-actions -DallLibraries=true -DPortalAdminPwd=password -DWasPassword=password

    ...where profile_root is the name of the IBM WAS profile where WebSphere Portal is installed; for example, wp_profile.

    To reschedule a single library...

      ./ConfigEngine.sh run-wcm-admin-task-schedule-actions -Dlibrary=libraryname -DPortalAdminPwd=password -DWasPassword=password

    ...where profile_root is the name of the IBM WAS profile where WebSphere Portal is installed; for example, wp_profile.


Export and import multiple libraries

The "import-wcm-data" command can be used to import multiple libraries at one time. To do this ensure all your exported libraries are in the same folder as specified in the ImportDir parameter in the wcm60_conf.xml file before using the "import-wcm-data" command.

To ensure all your exported libraries are in the same folder, you can export multiple libraries by entering the library names separated by commas in the WebLib parameter of the wcm60_conf.xml file before running "export-wcm-data".

For example...


Troubleshooting

If items are exported and imported twice between the same servers, and items have been moved or deleted between the first and second export and import, then manually delete these items from the target server before transferring the items again. If this is not done, an error similar to this example is generated:

If you receive 500 errors on ext2 and ext3 versions of Linux this means you have exceeded the number of children that a parent folder can hold. This is because you cannot store more than 32768 children under one folder on ext2 and ext3 versions of Linux. You will need to move some content items out of the affected site area to another site area so that none of the site areas contain more than 32 kilobytes of content and then try exporting again. You can move the content items back to the correct site areas once you have imported the library.


Parent topic:

Maintaining Web content


Related tasks


Resetting the Web content event log