Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

i want to write a power shell script in which i want to write a farm backup command and it should fire a mail on backup error.

please help me to do this.

thanks.

share|improve this question
add comment

1 Answer 1

Here you jave the script about the backup

http://weblogs.asp.net/shahar/archive/2008/02/02/powershell-script-to-backup-sharepoint-site-collection.aspx

and here about the email

http://www.myexchangeworld.com/2010/07/send-email-through-powershell/

share|improve this answer
    
gilloux, i want to sent conditional mail. i mean when error occurs in backup then it should shoot an email. –  Ashish Dubey Mar 28 '11 at 8:25
    
You can use the trap and try/catch systen in powershell I looked up this : powershell.com/cs/blogs/tips/archive/2009/09/14/… –  GillouX Mar 28 '11 at 9:07
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.