Create site collection in content database
I want to set by default to create a site collection in an independent content database when creating a new site collection automatically!
Ex: each content database only holds one site collection by default!
Is it possible to do that automatically without using code?
sharepoint-server 2016 site-collection
add a comment |
I want to set by default to create a site collection in an independent content database when creating a new site collection automatically!
Ex: each content database only holds one site collection by default!
Is it possible to do that automatically without using code?
sharepoint-server 2016 site-collection
add a comment |
I want to set by default to create a site collection in an independent content database when creating a new site collection automatically!
Ex: each content database only holds one site collection by default!
Is it possible to do that automatically without using code?
sharepoint-server 2016 site-collection
I want to set by default to create a site collection in an independent content database when creating a new site collection automatically!
Ex: each content database only holds one site collection by default!
Is it possible to do that automatically without using code?
sharepoint-server 2016 site-collection
sharepoint-server 2016 site-collection
edited Dec 17 '18 at 19:40
Tomaz
asked Dec 15 '18 at 14:59
TomazTomaz
776
776
add a comment |
add a comment |
2 Answers
2
active
oldest
votes
I don't think it's possible automatically.
Unfortunately, There is no event receiver triggered when creating/ created a site collection to handle this using event receiver.
However, you can adjust this manually by locking down the content database as the following:
Steps
Before creating a new site collection, you should plan to do the following:
- Lockdown all the web application content databases.
Create a new independent content database for the new Site Collection.
Create a new Site Collection will be created inside the newly created content database.
Check also Lockdown the web application content databases
Another workaround
Using PowerShell to Create a SharePoint Site Collection in an Independent Content Database
Download the full script at PowerShell: Create a SharePoint Site Collection in a Separate Content Database
@Tomaz be aware that this is not correct and it is possible to do what you're asking.
– Trevor Seward
Dec 17 '18 at 15:58
1
Thanks Trevor, but your answer is not doable in my situation, I need to do it automatically and your answer requires code too, I think Mohamed answer is the correct one, I cannot do this automatically without code! The lockdown solution is the best one in my case!
– Tomaz
Dec 17 '18 at 19:39
add a comment |
Yes, this is possible by overriding the class SPSiteCreationProvider. With this, you can select all of your existing content databases. If you cannot find a content database in the web application that meets the criteria, you could then create a new content database.
You should be aware that this would slow down the site creation process significantly as provisioning a new content database isn't an instant process.
I'm linking to Wictor's article below which references HNSC, but this will also apply to path-based site collections.
SharePoint: Specifying Content Database for new Site Collections when using Host Named Site Collections
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "232"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsharepoint.stackexchange.com%2fquestions%2f254369%2fcreate-site-collection-in-content-database%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
I don't think it's possible automatically.
Unfortunately, There is no event receiver triggered when creating/ created a site collection to handle this using event receiver.
However, you can adjust this manually by locking down the content database as the following:
Steps
Before creating a new site collection, you should plan to do the following:
- Lockdown all the web application content databases.
Create a new independent content database for the new Site Collection.
Create a new Site Collection will be created inside the newly created content database.
Check also Lockdown the web application content databases
Another workaround
Using PowerShell to Create a SharePoint Site Collection in an Independent Content Database
Download the full script at PowerShell: Create a SharePoint Site Collection in a Separate Content Database
@Tomaz be aware that this is not correct and it is possible to do what you're asking.
– Trevor Seward
Dec 17 '18 at 15:58
1
Thanks Trevor, but your answer is not doable in my situation, I need to do it automatically and your answer requires code too, I think Mohamed answer is the correct one, I cannot do this automatically without code! The lockdown solution is the best one in my case!
– Tomaz
Dec 17 '18 at 19:39
add a comment |
I don't think it's possible automatically.
Unfortunately, There is no event receiver triggered when creating/ created a site collection to handle this using event receiver.
However, you can adjust this manually by locking down the content database as the following:
Steps
Before creating a new site collection, you should plan to do the following:
- Lockdown all the web application content databases.
Create a new independent content database for the new Site Collection.
Create a new Site Collection will be created inside the newly created content database.
Check also Lockdown the web application content databases
Another workaround
Using PowerShell to Create a SharePoint Site Collection in an Independent Content Database
Download the full script at PowerShell: Create a SharePoint Site Collection in a Separate Content Database
@Tomaz be aware that this is not correct and it is possible to do what you're asking.
– Trevor Seward
Dec 17 '18 at 15:58
1
Thanks Trevor, but your answer is not doable in my situation, I need to do it automatically and your answer requires code too, I think Mohamed answer is the correct one, I cannot do this automatically without code! The lockdown solution is the best one in my case!
– Tomaz
Dec 17 '18 at 19:39
add a comment |
I don't think it's possible automatically.
Unfortunately, There is no event receiver triggered when creating/ created a site collection to handle this using event receiver.
However, you can adjust this manually by locking down the content database as the following:
Steps
Before creating a new site collection, you should plan to do the following:
- Lockdown all the web application content databases.
Create a new independent content database for the new Site Collection.
Create a new Site Collection will be created inside the newly created content database.
Check also Lockdown the web application content databases
Another workaround
Using PowerShell to Create a SharePoint Site Collection in an Independent Content Database
Download the full script at PowerShell: Create a SharePoint Site Collection in a Separate Content Database
I don't think it's possible automatically.
Unfortunately, There is no event receiver triggered when creating/ created a site collection to handle this using event receiver.
However, you can adjust this manually by locking down the content database as the following:
Steps
Before creating a new site collection, you should plan to do the following:
- Lockdown all the web application content databases.
Create a new independent content database for the new Site Collection.
Create a new Site Collection will be created inside the newly created content database.
Check also Lockdown the web application content databases
Another workaround
Using PowerShell to Create a SharePoint Site Collection in an Independent Content Database
Download the full script at PowerShell: Create a SharePoint Site Collection in a Separate Content Database
answered Dec 15 '18 at 16:14
Mohamed El-Qassas MVP♦Mohamed El-Qassas MVP
39.8k64084
39.8k64084
@Tomaz be aware that this is not correct and it is possible to do what you're asking.
– Trevor Seward
Dec 17 '18 at 15:58
1
Thanks Trevor, but your answer is not doable in my situation, I need to do it automatically and your answer requires code too, I think Mohamed answer is the correct one, I cannot do this automatically without code! The lockdown solution is the best one in my case!
– Tomaz
Dec 17 '18 at 19:39
add a comment |
@Tomaz be aware that this is not correct and it is possible to do what you're asking.
– Trevor Seward
Dec 17 '18 at 15:58
1
Thanks Trevor, but your answer is not doable in my situation, I need to do it automatically and your answer requires code too, I think Mohamed answer is the correct one, I cannot do this automatically without code! The lockdown solution is the best one in my case!
– Tomaz
Dec 17 '18 at 19:39
@Tomaz be aware that this is not correct and it is possible to do what you're asking.
– Trevor Seward
Dec 17 '18 at 15:58
@Tomaz be aware that this is not correct and it is possible to do what you're asking.
– Trevor Seward
Dec 17 '18 at 15:58
1
1
Thanks Trevor, but your answer is not doable in my situation, I need to do it automatically and your answer requires code too, I think Mohamed answer is the correct one, I cannot do this automatically without code! The lockdown solution is the best one in my case!
– Tomaz
Dec 17 '18 at 19:39
Thanks Trevor, but your answer is not doable in my situation, I need to do it automatically and your answer requires code too, I think Mohamed answer is the correct one, I cannot do this automatically without code! The lockdown solution is the best one in my case!
– Tomaz
Dec 17 '18 at 19:39
add a comment |
Yes, this is possible by overriding the class SPSiteCreationProvider. With this, you can select all of your existing content databases. If you cannot find a content database in the web application that meets the criteria, you could then create a new content database.
You should be aware that this would slow down the site creation process significantly as provisioning a new content database isn't an instant process.
I'm linking to Wictor's article below which references HNSC, but this will also apply to path-based site collections.
SharePoint: Specifying Content Database for new Site Collections when using Host Named Site Collections
add a comment |
Yes, this is possible by overriding the class SPSiteCreationProvider. With this, you can select all of your existing content databases. If you cannot find a content database in the web application that meets the criteria, you could then create a new content database.
You should be aware that this would slow down the site creation process significantly as provisioning a new content database isn't an instant process.
I'm linking to Wictor's article below which references HNSC, but this will also apply to path-based site collections.
SharePoint: Specifying Content Database for new Site Collections when using Host Named Site Collections
add a comment |
Yes, this is possible by overriding the class SPSiteCreationProvider. With this, you can select all of your existing content databases. If you cannot find a content database in the web application that meets the criteria, you could then create a new content database.
You should be aware that this would slow down the site creation process significantly as provisioning a new content database isn't an instant process.
I'm linking to Wictor's article below which references HNSC, but this will also apply to path-based site collections.
SharePoint: Specifying Content Database for new Site Collections when using Host Named Site Collections
Yes, this is possible by overriding the class SPSiteCreationProvider. With this, you can select all of your existing content databases. If you cannot find a content database in the web application that meets the criteria, you could then create a new content database.
You should be aware that this would slow down the site creation process significantly as provisioning a new content database isn't an instant process.
I'm linking to Wictor's article below which references HNSC, but this will also apply to path-based site collections.
SharePoint: Specifying Content Database for new Site Collections when using Host Named Site Collections
answered Dec 16 '18 at 1:13
Trevor SewardTrevor Seward
19.6k31644
19.6k31644
add a comment |
add a comment |
Thanks for contributing an answer to SharePoint Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsharepoint.stackexchange.com%2fquestions%2f254369%2fcreate-site-collection-in-content-database%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown