Deleting a WebSphere Commerce instance

You can delete an instance when you no longer require any of the resources and services associated with the instance. You can also choose to delete the WebSphere Application Server profile and server associated with the instance. Deleting an instance that is not required can free up a significant amount of system resources and make the resources available for other purposes.

If your instance contains resources or customizations you might need to reuse in another instance, copy them first or take a backup before you delete the instance.
Important: Deleting an instance cannot be undone so be sure you really want to delete it.

Procedure

  1. To delete a WebSphere Commerce instance:
    1. Ensure that the Web server associated with the WebSphere Commerce instance has been stopped.
    2. Export the WebSphere Commerce Enterprise Application from the WebSphere Application Server Administration Console to save any customization that you have done to the WebSphere Commerce instance. For example, Store Publishing. Your Enterprise Application name is WC_instance_name.
    3. Delete the WebSphere Commerce instance by doing the following:
      1. If you have a federated or cloned environment you can optionally remove the cluster members from your cluster and remove the cluster using the WebSphere Application Server deployment manager Administrative Console. See Removing a cluster member.
      2. WebSphere Commerce EnterpriseWebSphere Commerce ProfessionalIf you are deleting a WebSphere Commerce instance from a deployment manager cell, you can optionally remove the WebSphere Commerce node from the deployment manager cell. For instructions, refer to Taking your first steps after installing WebSphere Commerce.
      3. SolarisLinuxAIXEnsure that you are logged on as the WebSphere Commerce non-root user.
      4. Start the default WebSphere Application Server application server (server1) associated with your WebSphere Commerce instance, if it is not already started.

        For instructions on starting an application server, refer to Starting or stopping WebSphere Application Server.

        In a federated or cloned environment you must ensure that the WebSphere Application Server deployment manager is started. For instructions on starting the deployment manager, refer to Starting or stopping WebSphere Application Server.

      5. Start a command prompt session or command line session.
      6. In the command prompt session or command line session, change directories to WC_installdir/bin/.
      7. Issue the following command:
        • For IBM i OS operating systemSolarisLinuxAIX
          ./config_ant.sh -DinstanceName=instance_name RemoveInstance 
        • Windows
          config_ant.bat -DinstanceName=instance_name RemoveInstance 
        Important:

        SolarisLinuxAIXEnsure you run this command as the non-root user created for WebSphere Commerce.

        Ensure that you enter the name of the WebSphere Commerce instance and not the name of the WebSphere Commerce application server.

        The command does the following:
        • Removes the WebSphere Commerce data source from WebSphere Application Server.
        • Removes the WebSphere Commerce virtual hosts from WebSphere Application Server.
        • Removes JAAS authentication data alias for the WebSphere Commerce database.
        • Removes the WebSphere Commerce JDBC Provider.
        • Uninstalls the WebSphere Commerce EAR from WebSphere Application Server.
        • Removes WebSphere Commerce Web server configuration file.
        • WindowsRemoves the Windows service.
        • Deletes the WebSphere Commerce instance directory.
        • Regenerates the WebSphere Application Server Web server plug-in configuration file.
        • Removes the WebSphere Commerce instance from Configuration Manager.
      8. The WebSphere Commerce instance directory might not have been removed by the previous step if there were files that could not be deleted. The WebSphere Commerce instance directory must be deleted, moved or renamed if you plan to create a new WebSphere Commerce instance of the same name. The directory to remove or rename is:
        • WC_installdir\instances\instance_name
      9. Drop your WebSphere Commerce database. The ANT command RemoveInstance in the step above does not drop the database automatically for you. Refer to your database software documentation for instructions on dropping a database.
    4. WebSphere Commerce EnterpriseFor IBM i OS operating systemSolarisAIXWindowsWebSphere Commerce ProfessionalDo the following, depending on your Web server:
      Web server Actions
      IBM HTTP Server

      No additional steps need to be performed when using a local IBM HTTP Server.

      For IBM i OS operating systemDelete the HTTP entry from the QATMHINSTC file located in the QUSRSYS library. The HTTP entry is the name of the WebSphere Commerce instance being deleted.

      If you are using a remote IBM HTTP Server:
      1. Delete the following directory on the remote IBM HTTP Web Server node:
        • WAS_installdir/installedApps/cell_name/WC_instance_name.ear
      2. For a remote IBM HTTP Server, copy the WebSphere Application Server Web server plug-in configuration file from the WebSphere Commerce node to the remote Web server node. For instructions, refer to Copying the plugin-cfg.xml file to Web server.
      3. Restart the Web server.
      Microsoft IIS
      1. Remove the following WebSphere Commerce aliases from the IIS configuration:
        • accelerator
        • adminconsole
        • orgadminconsole
        • wcadmin
        • wcorgadmin
        • wcs
        • wcsstore
      2. If the Microsoft IIS node is remote from the WebSphere Commerce node, delete the following directory on the Microsoft IIS node:
        • WAS_installdir/installedApps/hostname/WC_instance_name.ear
      3. If the Microsoft IIS node is remote from the WebSphere Commerce node, copy the WebSphere Application Server Web server plug-in configuration file from the WebSphere Commerce node to the remote Web server node. For instructions, refer to Copying the plugin-cfg.xml file to Web server.
      4. Restart the Web server.
      Refer to your Microsoft IIS documentation for instructions.
      Sun Java System Web Server 7.0 Update 4
      1. From the Sun Java System Web Server 7.0 Update 4 configuration files (for each WebSphere Commerce port), remove any sections delimited by the following text:
        IBM WebSphere Commerce  (Do not edit this section)
        
        
        End of IBM WebSphere Commerce
        	(Do not edit this section)
      2. If the Sun Java System Web Server 7.0 Update 4 node is remote from the WebSphere Commerce node, delete the following directory on the Sun Java System Web Server 7.0 Update 4 node:
        • WAS_installdir/installedApps/hostname/WC_instance_name.ear
      3. If the Sun Java System Web Server 7.0 Update 4 node is remote from the WebSphere Commerce node, copy the WebSphere Application Server Web server plug-in configuration file from the WebSphere Commerce node to the remote Web server node. For instructions, refer to Copying the plugin-cfg.xml file to Web server.
      4. Restart the Web server.
      Refer to your Sun Java System Web Server 7.0 Update 4 documentation for instructions.
  2. WebSphere Commerce EnterpriseWebSphere Commerce ProfessionalIf you are deleting an authoring server instance, complete the following steps:
    • WebSphere Commerce EnterpriseSolarisLinuxAIXWebSphere Commerce ProfessionalOracle Delete the Oracle user IDs that start with the Workspaces Read schema prefix (WCR) and the Workspace Write schema prefix (WCW).
    • WebSphere Commerce EnterpriseSolarisLinuxAIXWebSphere Commerce ProfessionalOracle When removing an authoring instance, ensure that all Oracle users that are associated with that authoring instance are removed. If these users are not removed, future attempted to create an instance may fail.
    • For IBM i OS operating systemTo delete the user profile associated with your WebSphere Commerce instance, run the following command.
      Note: All jobs associated with the user profile must be ended before the user profile can be deleted. This will also delete the database for your instance. If you want to save the information contained in your database, ensure that you backup the database before performing this step.
      DLTUSRPRF USRPRF(instance_name) OWNOBJOPT(*DLT)
      Where
      instance_name
      is the name of the WebSphere Commerce instance you want to delete.
    • If you want the authoring server database to remain, drop all database schemas that start with the Workspaces Read schema prefix (WCR) and the Workspace Write schema (WCW).
    • If you do not want the authoring server database to remain, drop the database according to the instructions included with your database software.
  3. Optional: You can clean up and remove the WebSphere Application Server profile and WebSphere Application Server server that WebSphere Commerce created. You should not do this if you have other applications using that profile.

    If you choose to remove the profile, the following steps will remove the server (server1), any other servers that might exist in the profile, related WebSphere Application Server configuration information, and all of the applications installed on those servers:

    1. Ensure that all of the WebSphere Application Server servers that belong to the profile are stopped. By default you will have one application server named server1. For more information, see Starting and stopping quick reference.
    2. Use the tools provided by WebSphere Application Server to delete the WebSphere Application Server profile that WebSphere Commerce created. The profile name is the same as your WebSphere Commerce instance name.
      To remove your WebSphere Application Server profile, see one of the following topics:
    3. WindowsRemove the WebSphere Application Server profile service from the Services panel. Run the following commands from a command prompt:
      cd WAS_installdir/bin
      WASService.exe -remove WC_instance_name
    4. Optional: Delete or rename the WebSphere Application Server profile directory from your file system. You must perform this step if you plan to create a new WebSphere Application Server profile or a new WebSphere Commerce instance of the same name.
      The directory to remove or rename is:
      • WAS_installdir\profiles\instance_name