You can store the activity logs in external database by following below steps:
Step 1: Go to “DB Integration” option. Add the details like username, password, hostname, database name and table prefix.
Step 2: Click on Save Changes.
Step 3: Click on “Database Migration” in that two options will be available. One is “Migrate the data from current DB to external DB” and another one is “Migrate the data from external DB to current DB”.
Step 4: As per your requirement you can click on any option and migrate the data.