Legacy Knowledge Base
Published Jul. 2, 2025

Setup Liferay’s document management with an Amazon S3 as a repository

Written By

Kanchan Bisht

How To articles are not official guidelines or officially supported documentation. They are community-contributed content and may not always reflect the latest updates to Liferay DXP. We welcome your feedback to improve How to articles!

While we make every effort to ensure this Knowledge Base is accurate,it may not always reflect the most recent updates or official guidelines.We appreciate your understanding and encourage you to reach out with any feedback or concerns.

Legacy Article

You are viewing an article from our legacy "FastTrack" publication program, made available for informational purposes. Articles in this program were published without a requirement for independent editing or verification and are provided"as is" without guarantee.

Before using any information from this article, independently verify its suitability for your situation and project.

Issue

  • How to set up Liferay to use Amazon S3 storage instead of local storage and provide access information to S3.

Environment

  • Liferay DXP 7.2

Resolution

  • Steps to follow :
    • Amazon S3 requires a 'SAXParser' from the application server to operate. Apache Tomcat meets this requirement, therefore, the below property only needs to be added in a 'system-ext.properties' file
      • org.xml.sax.driver=com.sun.org.apache.xerces.internal.parsers.SAXParser
    • Place system-ext.properties file in a folder that resides in Liferay DXP installation’s classpath (e.g., /WEB-INF/classes/).
    • Set the following property in a portal-ext.properties file in the Liferay Home folder: 
      • dl.store.impl=com.liferay.portal.store.s3.S3Store
  • Restart Liferay DXP.
  • In the Control Panel, navigate to Configuration → System Settings → File Storage
  • In the S3 Store screen, configure the store:
    • Bucket Name: bucket’s name.
    • Access Key: AWS access key.
    • Secret Key: secret key.
    • S3 Region: The geographic region; the default is us-east-1.
  • Leave the other fields on the default settings.
  • Click Save
  • Restart Liferay DXP.
  • Now, the Liferay DXP instance is using the Amazon S3 store.

Additional Information

  • You may encounter an error that requires you to set the S3Endpoint parameter.
  • Amazon’s Simple Storage Service (S3) is a cloud-based storage solution that can be used with Liferay.
  • An Amazon Web Services (AWS) account is needed and then setup is very easy. After registering for an account, Amazon assigns some credentials (Access Key ID & Secret Key) via AWS Identity and Access Management (IAM). When creating an S3 bucket, you will be provided with a Bucket Name. All of these should be set as configuration values in Liferay.
  • Then the documents can be stored in the cloud from Liferay Application Server(s), seamlessly.
Did this article resolve your issue ?

Legacy Knowledge Base