Hi
I know I can use power shell or central admin to backup SharePoint site collection or Site,is there a way to automate this process or I have to create a scheduled task that runs either power-shell or stsadm command?
normally what we use to do is create a batch file of stsadm commands for backup and associate it with windows scheduler job. and i think thats the best approach you can do the same for powershell scripts as well
You can automate the backing of sharepoint site collection using SPTimer Job.
Based on the schedule SPTimer will back your site collection/site periodically.
Since SPTimer job is integrated with SharePoint this can be implemented easily.
Take a look at this. It's descriptive.
http://community.bamboosolutions.com/blogs/sharepoint-2010/archive/2010/12/21/sharepoint-2010-cookbook-powershell-script-to-backup-a-site-collection-automatically.aspx
Related
On a SharePoint 2013 on premise installation, we have configured an incremental crawl, that runs every 15 minutes.
Now we need a possibility to start this crawl manually, too. Is there a WebService we can call to start the crawl manually? Maybe even a possibility to start the crawl on a smaller scope, like only a list or website?
You may just love Simple HTTP api for Executing PowerShell Scripts
In cases where you want to simply invoke a PowerShell script remotely,
a REST api is a good choice since all modern programming languages
make it simple to perform a HTTP GET operation.
and Simple HTTP api for executing PowerShell scripts (with source code) which is an out of the box solution of what the above is trying to accomplish. Here are the Windows PowerShell cmdlets to administer and configure search in SharePoint 2013 for more details.
Please also look at SharePoint Windows PowerShell Remoting if you are interested on more nitty-gritty remote SharePoint control.
Try to use powershell interface for this purpose.
It is pretty simple when you think about it.
We can use the Get-SPEnterpriseSearchCrawlContentSource command to get a ContentSource object.
After we have a reference to this object, we can start, stop, and pause crawls to our heart’s content.
This class has a few methods that you might be interested in:
StartFullCrawl, StartIncrementalCrawl, StopCrawl, PauseCrawl, and ResumeCrawl.
What each method does should go without explanation.
If it is necessary, you can create a wrapper for powershell call. Your web service will call powershell for this purpose.
I'm trying to make a SharePoint workflow start automatically for any new document that is uploaded to a specific doc library. I've configured the workflow in SharePoint Designer to auto start for new documents or changed documents. However, the workflow never starts automatically! I can run it manually, but it won't execute itself.
I've searched around and have found the core issue, which is reflected in my log:
"Declarative workflows cannot automatically start if the triggering action was performed by System Account. Canceling workflow auto-start."
However, all the fixes I've seen have not worked for me. A common solution is to not run or create the workflow as the SharePoint System Account. Well, my SharePoint service accounts are not the ones I'm logging in as to upload my documents nor was it the one I used to create the workflow. I've tried editing & re-publishing my workflow as a totally new account and it still won't auto-start.
Just focus on two things:
Workflow will never start automatically with system account.
Check the options Start workflow automatically when an item is created or changed from Workflow Start Options.
While publishing the workflow, u need to select the checkbox Start workflow automatically when an item is created or changed for the workflow to start automatically or else whatsoever the WF will not start automatically.
Instead of using Sharepoint system user account, u could use an account having contribute permission on site level and full control over the library
Run the command at the server in powershell
stsadm.exe –o setproperty –propertyname declarativeworkflowautostartonemailenabled –propertyvalue yes
After I did that, the workflow runs perfectly although it shows the created by as being "system account".
I'm looking for a way to duplicate the content of a SharePoint 2010 server in order to work against it without taxing the main (production) server. I would need the backup server to update as needed, but I'm not looking for a failover solution. It looks like 2010 includes replication features for failover, but I can't tell if this is appropriate for my solution as well (simply not configuring the switchover feature). Can someone with SP 2010 experience tell me if this feature would work for my needs?
You could attach a restored backup of your production content database. See this MSDN documentation for more info: Attach or detach content databases (Sharepoint Server 2010).
There is also a GUI tool http://sushi.codeplex.com/ which should help you. You could backup production and restore to dev site whenever you needed to.
You could also use either stsadm.exe and the backup/restore option OR the powershell cmd backup/restore.
In addition, there is a built in interface in Central Admin to backup/restore sites. I've generally found either the command line or the SUSHI tool to be quicker and easier.
In most cases, the taxing work is on the sharepoint side, not the SQL side. You could attach another front end to the farm but reserve it for only your traffic. Otherwise you're looking at some form of backup/restore to copy everything to a 2nd duplicate farm.
We want to activate the existing future for more than 100+ site-collections, what would be the right choice? can we achieve this through Powershell?
If you don't want to code yourself, you can always download the SharePoint Feature Admin Tool from Codeplex.com.
It will allow you to select a Web Feature and activate/deactivate in recursively on a Site Collection.
Yes powershell would make this easy.
But there is also the stsadm command "activatefeature".
Together with the stsadm command "enumsites" and a bit of creating command script building you should go a long way.
How to find the currently running SharePoint 2007 Timer jobs using STSADM?
Not sure if you can do that with default
stsadm commands, but possible if you write a
custom stsadm command.
Someone already wrote a stsadm command where
you can enumerate job definitions
with stsadm. Just download and
install.
There is also SharePoint
Manager available which shows
that information and many other. It
is a very good tool that I can
recommend for SharePoint developers
and Administrators.