James Nelli
James Nelli

Reputation: 1129

Multiple Session State databases on Database Instance

I know that multiple applications can use the same ASPState database, but does it cause any problems to have two ASPState databases on the same database instance?

We need to configure mirroring on the ASPState database so that we can configure a failover connection, but only one of the applications using the ASPState database needs have the failover. I'd rather not have the sessions for all the applications mirrored as that would cause extra unnecessary network traffic.

Alternatively if there is a way to configure the session state to fail over to the DR SQL server without having to mirror the temporary data that would be great.

Upvotes: 1

Views: 1379

Answers (1)

James Nelli
James Nelli

Reputation: 1129

I've seen a site or two that recommend having different ASPState databases for different applications and have not yet found any that say this is a bad practice, so I am going ahead with this plan.

Created the new ASPState with this command

Aspnet_regsql.exe -S -E -ssadd -sstype c -d ASPState_

(Aspnet_regsql.exe is in the C:\Windows\Microsoft.NET\Framework64\v4.0.30319 directory for me)

All looks good. Just need to make sure that user running the script has permissions to create the database or you can replace the -E with -U and -P or a user that does, and need to set permissions on the database created after.

Upvotes: 1

Related Questions