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.

link|improve this question

45% accept rate
feedback

1 Answer

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/

link|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
feedback

Your Answer

 
or
required, but never shown

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