How to clone current mautic site without contacts?

Your software
My Mautic version is: 2.16.0
My PHP version is: 7.2.27

Your problem
My problem is: I want to clone my current mautic to new site but without current contact of the mautic site. How can I do this?

I think I have to do steps

  1. Copy current folder mautic to folder of new mautic site
  2. Export current mautic site’s database but don’t know how to export without contact.
  3. Create database to new mautic site
  4. Import database without contact to new database
  5. Configure new mautic site with new database.

If steps ok, please show me the way host to Export current mautic site’s database without contact. Thanks!

The trivial option would be to do a full clone and delete contacts via GUI afterwards - but that would have to be in chunks of 100 (unless you do a little tweaking in the browser - not user-friendly) , and may thus be heavy work.

The only other options I can think of require being comfortable with database manipulation, plus understanding Mautic’s database structure. Basically: Empty all tables that refer to contacts (“leads”) via “lead_id”.
One could do that after import, in the new instance.
Or one could have a little export script that does this for you during export.
-> I’d suggest find someone to create that script for you (and open source it : )

1 Like