Ways to handle Disk Image resources that are no longer needed?
search cancel

Ways to handle Disk Image resources that are no longer needed?

book

Article ID: 164799

calendar_today

Updated On:

Products

Deployment Solution

Issue/Introduction

In fast moving environment it is possible that disk images (.gho or .img) are created and used for a short period of time.

However based on the nature of those disk images they can take up a lot of space on the Symantec Management Platform server and on Package Server, and deleting them can be tricky (leaving orphaned items on the DB or files on the SMP server (Symantec Management Platform) / PS's (Package Server)).

 

Note:
When trying to delete an Image package, you may also see entries like:

Entry 1:

DS delete Items task 2fdea9c5-ec02-45b6-9fb2-16761819f0eb started
-----------------------------------------------------------------------------------------------------
Process: w3wp (4000), Thread ID: 265, Module: Symantec.Deployment.Web.dll
Priority: 4, Source: Altiris.Deployment.Web.DsItemsDeleteDlg.StartDeletingItems

 

Entry 2:

Failed to remove image resource f73221bf-bf2f-476f-8484-116cacd6704b

Image resource f73221bf-bf2f-476f-8484-116cacd6704b is referenced by other items.
   [System.InvalidOperationException @ Symantec.Deployment.Common]
   at Altiris.Deployment.Common.Resource.DSImageResource.DeleteImageResource(Guid resourceGuid, Boolean failWithException)

-----------------------------------------------------------------------------------------------------
Process: AeXSvc (1364), Thread ID: 51, Module: Symantec.Deployment.Common.dll
Priority: 1, Source: Altiris.Deployment.Common.Resource.DSImageResource.DeleteImageResource

Entry 3:

Error deleting item f73221bf-bf2f-476f-8484-116cacd6704b.

Image resource f73221bf-bf2f-476f-8484-116cacd6704b is referenced by other items.
   [System.InvalidOperationException @ Symantec.Deployment.Common]
   at Altiris.Deployment.Common.Resource.DSImageResource.DeleteImageResource(Guid resourceGuid, Boolean failWithException)
   at Altiris.Deployment.DsImaging.DsImagesDeleteTask.DeleteImages(DsItemsDeleteResult result)

-----------------------------------------------------------------------------------------------------
Process: AeXSvc (1364), Thread ID: 51, Module: Symantec.Deployment.dll
Priority: 1, Source: DsImagesDeleteTask

Environment

DS 7.x, 8.x

Cause


Resolution

The following steps are recommended to ensure the disk images that are no longer needed are first delete from disks (on the SMP and PS's) and then deleted form the Database:

  1. Locate the disk image you want to remove on the Symantec Management Console. You want to keep a copy of the Image Resource guid [1] and of the Disk Image package [2]
  2. Extracts the package folder from the "Disk Images" package [2]
  3. Cleanup the package source i.e. remove all files from the package to ensure no traces (Important Note! You may want to take a back up of the image files or double check that you are not removing an image that is still in use before completing this step and the next one)
  4. Run the package distribution point update task
  5. Delete the Image Resource [1] from the Management Console

The following SQL query can be used to track the cleanup process of the package servers (please make sure you use a specific package name instead of the generic %.gho filter highlighted in yellow below) :

select p.Name, p.[Package Location], p.[Package Size], p._Refreshed, p.Version, s.Version, s.Status, s.IntStatus, i.Name, i.Domain, i.[OS Name]
  from SWDPackage p
  left join SWDPackageServer s
    on p.PackageId = s.packageid
  left join Inv_AeX_AC_Identification i
    on s.PkgSvrId = i._ResourceGuid
 where p.Name like '%.GHO'
   and p._Latest = 1

[1] "Manage" > "All Resources" > "Organizational Views" > "Default" > "Software Component" > "Image Resource"
[2] "Settings" > "All Settings"> "Deployment" > "Disk Images"

 

POST-DS 8.5 RU4:

With the release of DS 8.5 RU4 release, new functionality was added to handle the need to cleanup unused image packages and similar DS files. Please take a look at:
"Deleting images, packages, and resources"

The structure of DS images was reorganized to process all types of images in the same way as we were doing with regular packages. DS image resource management from SMP console was implemented. Files deletion from SMP\PS was implemented as part of it. Copy file tasks (and some other tasks) were reworked to correctly process associated packages and related files.

Additional Information