DNN Forums

Ask questions about your website to get help learning DNN and help resolve issues.

Merging and Splitting Individual Portals to/from one database

 3 Replies
 0 Subscribed to this topic
 40 Subscribed to this forum
Sort:
Author
Messages
Growing Member
Posts: 51
Growing Member

I have a few DNN sites that are very lightly used.  Currently they run in their own installations with their own databases.

I'd like to consider consolidating them into one site with multiple portals. 

Imagine the simplest case.  Install A with its own IIS Site and DB; and Install B with its own IIS Site and DB

Superficially this seems simple (hah!) most tables in the database contain a portal ID, so presumably to merge Install B's database into Install A's database requires...

  • Allocate a portal ID for each site in Install B that is unused in Install A
  • Copy all the tables in Install B into Install A - overwriting portal IDs as appropriate

...And in the file system..

  • Copy all the portal specific directories from B to A, again overwriting portal ID's as appropriate
  • Install any modules that were in B but not in A

Has anyone tried this in the past?  Are there any scripts/programs to do the job - even partial would be a helpful start

Of course the moment I thought about this I started to conside that I might want to do the reverse at some point in the future and extract a single portal from a multiportal site.  Are there any tools for that?

Am I just replicating what site import/export is intended to do?  Does site import/export actually work?

Veteran Member
Posts: 349
Veteran Member
3 Helpful Replier
Helpful Replier
Thanks for being such a helpful replier!
MVP
MVP
You're an MVP!
Engaged Reader
Engaged Reader
You are an engaged reader!
Avid Reader
Avid Reader
Avid Reader art thou!
For separating sites, it is kinda simple, you copy the whole instance somewhere else and delete all the portals you don't want. For merging (I never did it) but in theory you could export a whole site and import it in another instance assuming all of your extensions implement import/export properly.
Senior Member
Posts: 1607
Senior Member
MVP
MVP
You're an MVP!
New Poster
New Poster
Congrats on posting!
Oh, wow... That's a great question. I know I've done this before, but it was very tricky to do the last time I did it. The biggest pain is when a module doesn't export/import the way you intend. That will always require some manual work, and there will be plenty of SQL cleanup involved.
Veteran Member
Posts: 1182
Veteran Member
MVP
MVP
You're an MVP!
Separation is simple, as Daniel said. Merging never worked for me (Export/Import), but the sites always were too small and it was easier to set up a new site in the other protal and transfering the content manually. For a site with a lot of users I sent out an email that they have to "re-register".

Happy DNNing!
Michael

Michael Tobisch
DNN★MVP

DNN Connect

These Forums are for the discussion of the open source CMS DNN platform and ecosystem.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. If you have (suspected) security issues, please DO NOT post them in the forums but instead follow the official DNN security policy
  2. No Advertising. This includes the promotion of commercial and non-commercial products or services which are not directly related to DNN.
  3. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  4. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  5. No Flaming or Trolling.
  6. No Profanity, Racism, or Prejudice.
  7. Site Moderators have the final word on approving / removing a thread or post or comment.
  8. English language posting only, please.

Would you like to help us?

Awesome! Simply post in the forums using the link below and we'll get you started.

Get Involved