Solved

SharePoint 2010 Alerts broken

Posted on 2014-07-28
6
406 Views
Last Modified: 2014-08-17
SharePoint 2010 Install with the following symptoms:

1.  full admin rights: I create an alert on a list.
2. I receive an email correctly stating the "FROM" (it matches the outgoing info on server). The email states that I have created an alert on the aforementioned list.
3. I never get an alert.
4. On some lists, I get an alert. Same site collection, different lists. Some lists never give an alert at all.

Any suggestions?

(Server farm with 2 WFE, 1 app server and a SQL server)
0
Comment
Question by:Montoya
  • 3
  • 3
6 Comments
 
LVL 8

Expert Comment

by:Jayaraja Jayaraman
ID: 40227303
0
 
LVL 19

Author Comment

by:Montoya
ID: 40227335
i've had that link open a few days already, Jayaraja.. thanks though
0
 
LVL 8

Expert Comment

by:Jayaraja Jayaraman
ID: 40227337
if this still dosent help ? let me know , i can post you sme powershell scripts to fix the alerting issues when you restore the site collection backup from different environemnt or restored.
0
Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

 
LVL 19

Author Comment

by:Montoya
ID: 40238987
still not working. Your help would be greatly appreciated
0
 
LVL 19

Author Comment

by:Montoya
ID: 40252928
layaraja, you were going to post some powershell scripts for this? I would really appreciate that. Thanks you!
0
 
LVL 8

Accepted Solution

by:
Jayaraja Jayaraman earned 500 total points
ID: 40253050
$SPSiteURL = "http://NewSharePoint.com/sites/alerts" #Site Collection Url
$oldrooturl = "https://OldSharePoint.crescent.com" # Old URL of the webapplication
$rooturl = "http://NewSharePoint.com" # New URl for the new webapplication
 
$SPsite = Get-SPSite -Identity $SPSiteURL
$SPwebs = $SPsite.AllWebs
 
$updated = 0
 
foreach ($web in $SPwebs) #Get All the sub sites
{
  $alerts = $web.alerts  # Get All Alerts
 
  if ($alerts.count -ne 0)
   {    
   Write-Host -foregroundcolor green "Number of Alerts in: "$web.url ":" $alerts.count
   
    foreach ($alert in $alerts)
    {
  #preserve & Change the the Alert frequency, so that the so the datarow inside is touched by SharePoint API.
  $Status = $alert.Status
                $Frequency = $alert.AlertFrequency
                    if($Frequency -eq [Microsoft.SharePoint.SPAlertFrequency]::Immediate)
                     {
                         $alert.AlertFrequency = [Microsoft.SharePoint.SPAlertFrequency]::Weekly
                     }
                    else
                      {
                         $alert.AlertFrequency = [Microsoft.SharePoint.SPAlertFrequency]::Immediate
                      }
   
   $title = $alert.title
          $alert.title = "UPDATED" + $title
          $alert.Status = [Microsoft.SharePoint.SPAlertStatus]::Off
 
             $alert.Update()  #Update the modified values
             
       if ($alert.Properties -ne $null)
        {
          if ($alert.Properties["siteurl"] -ne $null -and $alert.Properties["siteurl"].Contains($oldrooturl))
           {
             $alert.Properties["siteurl"] = $alert.Properties["siteurl"].Replace($oldrooturl, $rooturl)
           }
           if ($alert.Properties["mobileurl"] -ne $null -and $alert.Properties["mobileurl"].Contains($oldrooturl))
           {
             $alert.Properties["mobileurl"] = $alert.Properties["mobileurl"].Replace($oldrooturl, $rooturl)
           }
 
          $updated++
 
         }
 
 
 #Reset the Values of alert, back to their original
      $alert.title = $title
             $alert.AlertFrequency = $Frequency
      $alert.Status = $Status
             $alert.Update()    
 
  write-host "Alert updated: " $title
        #$alert.Properties
 
    }
    Write-Host "Number of alerts updated: " $updated
  }
}
0

Featured Post

Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Pimping Sharepoint 2007 without Server-Side Code Part 1 One of my biggest frustrations with Sharepoint 2007 in the corporate world is that while good-intentioned managers lock down the more interesting capabilities of Sharepoint programming in…
SharePoint Designer 2010 has tools and commands to do everything that can be done with web parts in the browser, and then some – except uploading a web part straight into a page that is edited in SPD. So, can it be done? Scenario For a recent pr…
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now