7

When I tried to add my wsp solution I am getting the error,

An object in the SharePoint administrative framework, "SPSolutionLanguagePack Name=0 Parent=SPSolution Name=myeventreceiver.wsp", depends on other objects which do not exist.Ensure that all of the objects dependencies are created and retry this operation.myeventreceiver.wsp:

My environment is having 1 WFE, 1 App Server and 1 DB Server with SP 2013 installed.

This is happening in my staging environment only, not in my dev or test environment.

I tried restarting the timer service but in vain.I did the IISReset also which did not help either. The only option left is clearing the SPconfig cache from the ProgramData folder. But I am stuck at doing the clearing the cache. Should I clear the cache which will result into solving my issue? I got the script from this link: http://blogs.technet.com/b/sp/archive/2013/05/29/clear-sharepoint-config-cache-with-powershell.aspx

  Add-PSSnapin -Name Microsoft.SharePoint.PowerShell –erroraction 
      SilentlyContinue
        Stop-Service SPTimerV4
        $folders = Get-ChildItem C:\ProgramData\Microsoft\SharePoint\Config 
      foreach ($folder in $folders)
       {
      $items = Get-ChildItem $folder.FullName -Recurse
      foreach ($item in $items)
        {
           if ($item.Name.ToLower() -eq "cache.ini")
            {
                $cachefolder = $folder.FullName
            }
          }
        }
       $cachefolderitems = Get-ChildItem $cachefolder -Recurse
       foreach ($cachefolderitem in $cachefolderitems)
        {
         if ($cachefolderitem -like "*.xml")
            {
               $cachefolderitem.Delete()
            } }
         $a = Get-Content  $cachefolder\cache.ini
         $a  = 1
         Set-Content $a -Path $cachefolder\cache.ini
          read-host "Do this on all your SharePoint Servers - and THEN press  
           ENTER" 
        start-Service SPTimerV4
  • Did you try to restart the SharePoint Timer and Admin services on both App and WFE server? – Waqas Sarwar MVP May 15 '15 at 13:19
  • I restarted the SP Timer Service and Recycling of Application Pool on the App Server and WFE but not the Admin Service. – userAZLogicApps May 15 '15 at 13:22
  • try with admin services as well, dont recycle, stop and start it. – Waqas Sarwar MVP May 15 '15 at 13:22
8

I think This is especially the case if you have just done a retract/uninstall and you try to add straight away. If you try again in a few seconds it will work. Basically this is because when you delete a wsp from solution management and then immediately run this stsadm command, there will still be clean up operations going on in the background. So just leave a slight delay between uninstall of solution packages and re-deploys. Tell me if it is correct.

If this does not work the you can try below method

We can deploy any components using solution package (WSP). The below steps ensures that Config refresh timer service occurs.

  1. Stop the Windows SharePoint Timer Service
  2. Open C:\Documents and Settings\All Users\Application Data\Microsoft\SharePoint\Config\<> folder
  3. Take backup of Cache.ini file
  4. Delete all the XML files in the GUID folder
  5. Open the Cache.ini file in edit mode and delete the contents of it.
  6. Type 1.Save and close the file.
  7. Start the Windows SharePoint Timer Service. Thanks
| improve this answer | |
  • Thanks ,I already seen this solution,but my worry is Is there any negative impact if I clear this cache.Also should I do this for my WFE and App Server ? – userAZLogicApps May 15 '15 at 13:14
  • no there is no negative impact. – Manish Oswal May 15 '15 at 13:15
  • The above method always works for me and i can say that its one of the best solution i can think of – Manish Oswal May 15 '15 at 13:16
  • thanks Manish, clearing SPConfig Cache worked.My wsp got installed after running the script.I am marking your reply as answer though I took the script from the mentioned link. – userAZLogicApps May 15 '15 at 13:56
  • Answer here saved me. I just needed to wait in between retract/removal and adding it again. Erggh SharePoint can be so annoying with wrong errors! – vapcguy Apr 8 '19 at 19:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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