Restore deleted folder from File Management

Vote:
 

Hi,

If a user accidentally deletes a folder in the Global files from the File Management, is there any way to recover and restore those fles? They don't seem to go to the recycle bin as pages do. 

Best, Leonard

#80844
Feb 03, 2014 17:45
Vote:
 

I suspect that there is no recycle bin. Would it be possible to copy/paste a folder with files from a test-environment to the live-environment? 

#80847
Feb 03, 2014 18:03
Vote:
 

Here is how you can get the files back: 

Step 1. From the web.config, check the physicalPath of the Global Files: 

<virtualPath customFileSummary="~/FileSummary.config">
        <providers>
          <clear />
          <add showInFileManager="true" virtualName="Page Files" virtualPath="~/PageFiles/" bypassAccessCheck="false" name="SitePageFiles" type="EPiServer.Web.Hosting.VirtualPathVersioningProvider,EPiServer" indexingServiceCatalog="Web" physicalPath="\\servername\site_content_livebackup\cms_content_live\pageFiles" />
          <add showInFileManager="true" virtualName="Global Files" virtualPath="~/Global/" bypassAccessCheck="false" name="SiteGlobalFiles" type="EPiServer.Web.Hosting.VirtualPathVersioningProvider,EPiServer" indexingServiceCatalog="Web" physicalPath="\\servername\site_content_livebackup\cms_content_live\global" />
        </providers>
        <filters />
      </virtualPath>    

This physicalPath contains a lot of folder, with a lot of subfolders, containing files with guid as names. 

 

Step 2. Get the connection between the filename from the File Manager and the guid.jpg from the physicalPath. 

Go to the db, and execute this query: 

SELECT pkID, fkSchemaId, Name, ItemData 
FROM tblItem
WHERE (Name = 'accidentilydeletedimage.jpg')

This gives you a Guid. Copy/paste this guid in the RelationListFrom-SP: 

exec RelationListFrom @FromId=N'pkID',@SchemaId=0 

This gives you another Guid. The accidentilydeletedimage.jpg has this guid in the physicalPath. 

See also http://world.episerver.com/Blogs/Petter-Klang/Dates/2011/4/Finding-your-Versioned-files-on-disk/

#80893
Edited, Feb 04, 2014 14:41
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.