Riva CRM Integration - Documentation and Knowledge Base

How to Delete Orphan Home Directories

Article ID: 143
Last updated: 13 Oct, 2010

Question:  How can you use EMU to find and delete orphan home directories?

Answer:  This requires three separate operations:

  • Use EMU to find the orphan home directories and generate a delete batch file.
  • Modify the batch file
  • Run the batch file


To Generate the Orphan Home Directories Delete Batch File

  1. Open EMU.
  2. Select "Tools" > "Reports" > "Orphan Home Directories".
  3. In the "Report" window, click Next >.
  4. In the "Select Reports Context" window, container in eDirectory that will contain the volume objects where the home directories are located and click Next >.
  5. In the "Directory Location" window select the volume that contains the home directories and click OK.
  6. This will produce a "Results" window.  Click Export to create a .csv file with the list of orphan directories.  Click Generate to create a batch file that will flag and remove orphan directories.

Modify the Batch File

EMU has an issue with creating the batch file and produces a lines similar to:

Code:
flag "\\sample-tree\.fs1_sys.servers.omni\Home\user1\*.*" n /s /c
del /Q /F /S "\\sample-tree\.fs1_sys.servers.omni\Home\user1"
rmdir "\\sample-tree\.fs1_sys.servers.omni\Home\user1"


Modify the batch file created to ensure that there are two flag, one del and one rmdir lines for each home directory.  Please ensure that the options displayed in this sample are used in your batch file:

Code:
flag "\\sample-tree\.fs1_sys.servers.omni\Home\user1\*.*" -sy -h -ri -di -ro /s /c /fo
flag "\\sample-tree\.fs1_sys.servers.omni\Home\user1\*.*" -sy -h -ri -di /s /c /do
del /Q /F /S "\\sample-tree\.fs1_sys.servers.omni\Home\user1"
rmdir "\\sample-tree\.fs1_sys.servers.omni\Home\user1" /s /q


Run the Batch File to Remove Orphan Home Directories

To run the FLAG command that is in the batch file, you need to ensure that there is a mapped drive that points to the SYS:PUBLIC directory on your netware server.  You can use the PATH command in a command prompt window to confirm if an appropriate path exists.

  • Run the modified .BAT file from a command prompt window to permanently remove the orphan home directories.

Article ID: 143
Last updated: 13 Oct, 2010
Revision: 1
Views: 6195