3/27/09

uninstall fixpacks

Someone asked me how to troubleshoot fixpack uninstallation process.

Befroe going into that, read the following from UpdateInstaller README. You can find this under Update_Inst_Path/docs/raedme_updateinstaller.txt/pdf/html

3.0 Uninstalling maintenance packages

This topic describes how to use the Update Installer for WebSphere
Software to uninstall interim fixes, fix packs, and refresh packs. The
Update Installer for WebSphere Software is also known as the update
installer program, the updateInstaller program, and the Update
installation wizard.



Use the proper authorizations to successfully uninstall product updates.
Use the update installer program as the root user on a Linux or UNIX
platform, or as the administrator on a Windows platform.

The Update Installer wizard is an InstallShield for Multiplatforms
wizard that runs with either a graphical user interface or in silent
mode with a response file.

Important: See 4.3, "Known problems and workarounds for the update
command" for information about known problems and workarounds.

The following descriptions contain reference information about
uninstalling interim fixes, fix packs, and refresh packs on WebSphere
Application Server products:

Overview of the uninstall procedure
To uninstall a maintenance package:
1. Use the update installer to install the maintenance package,
which creates a backup file in the
app_server_root/properties/version/nif/backup directory. IBM
does not support user modifications to backup files.
2. Use the update installer program to remove the maintenance
package as described in this topic.

Viewing the fix level of the node
You can use the 5.0, "versionInfo command" in the
app_server_root/bin directory to display the exact fix and
version level of the product. However, do not use the
versionInfo command while installing or uninstalling a
maintenance package.

Do not launch multiple copies of the Update Installer wizard at one
time: Concurrent launches of the update installer program are not
supported. Performing more than one update at the same time can produce
unpredictable results, which might include a failed or faulty
installation.

Required information

The graphical interface requires the following information that you
must supply:

Table 4. Information required when uninstalling a maintenance package
+-----------------------+----------------------+----------------------+
| Field | Valid values | Description |
+-----------------------+----------------------+----------------------+
| File path of the | Identify the | The Update Installer |
| installation root | installation root | application defaults |
| directory of the | directory for one of | to the last-visited |
| WebSphere product and | the following | product location. |
| the Update Installer | products: | |
| | * IBM WebSphere | |
| | Application Server | |
| | * IBM WebSphere | |
| | Application Server - | |
| | Express | |
| | * Embedded version | |
| | of the IBM WebSphere | |
| | Application Server - | |
| | Express | |
| | * IBM WebSphere | |
| | Application Server | |
| | Network Deployment | |
| | * IBM WebSphere | |
| | Extended Deployment | |
| | * IBM Application | |
| | Client for WebSphere | |
| | Application Server | |
| | * IBM WebSphere | |
| | Business Integration | |
| | Server Foundation | |
| | * Web server | |
| | plug-ins for | |
| | WebSphere | |
| | Application Server | |
+-----------------------+----------------------+----------------------+
| File name of the | Select a maintenance | The default |
| maintenance package | package to uninstall | maintenance package |
| to uninstall. | from the | is the package with |
| | app_server_root/prop | the latest date |
| | erties/version/ | stamp and time stamp |
| | update/backup | in the |
| | directory. | app_server_root |
| | | /properties/version/ |
| | | update/backup |
| | | directory. |
+-----------------------+----------------------+----------------------+



The following procedure describes how to uninstall a maintenance
package.

1. Log on to the operating system.

[Linux] In addition, verify that the umask setting is 022. To verify
the umask setting, issue the following command:

umask

To set the umask setting to 022, issue the following command:

umask 022

2. Change directories to the updi_root directory.
3. [Windows] Use the Windows Services panel to stop all services for
WebSphere Application Server processes.
4. Stop all Java processes that use the IBM Software Developer Kit (SDK)
that the WebSphere Application Server product provides.

Before uninstalling interim fixes, fix packs, and refresh packs on a
machine, stop all Java processes on the machine that use the IBM SDK,
Java Technology Edition that WebSphere Application Server provides.



WebSphere Application Server processes include:
* Application server processes
* The nodeagent process on an application server node when the node
is federated into a deployment manager cell
* The dmgr process for the deployment manager server



Stop all Java processes if necessary. If you uninstall a maintenance
package while a WebSphere Application Server-related Java process
runs, IBM does not guarantee that the product can continue to run
successfully, or without error.

5. Use the update installer to uninstall the maintenance package.

Uninstall the interim fix on each application server node in a cell
before uninstalling the maintenance package from the deployment
manager node.



Issue one of the following commands to uninstall with the graphical
interface:

Table 5. Update installer commands for uninstalling with the graphical
interface
+--------------------------------+-------------+----------------------+
| Command example | Type of | Description |
| | installatio | |
| | n | |
+--------------------------------+-------------+----------------------+
| update.bat -W | Graphical | Initializes the |
| update.type="uninstall" | interface | maintenance package |
| | mode | field with the name |
| | | of the maintenance |
| | | package that was |
| | | most recently |
| | | installed. |
| | | Accept all of the |
| | | default values to |
| | | uninstall the |
| | | maintenance package |
| | | with the most recent |
| | | date stamp and time |
| | | stamp. |
+--------------------------------+-------------+----------------------+
| update.bat -W | Graphical | Overrides the |
| product.location="e: | interface | graphical interface |
| \IBM\WebSphere\AppServer" -W | mode | with the location of |
| update.type="uninstall" | | the WebSphere |
| | | software to update. |
| | | The default |
| | | maintenance package |
| | | to uninstall is the |
| | | most recently |
| | | installed |
| | | maintenance package |
| | | for that software. |
+--------------------------------+-------------+----------------------+
| update.bat -W | Graphical | Overrides the |
| backup.package="PQ20029.pak" | interface | maintenance package |
| -W update.type="uninstall" | mode | field with the name |
| | | of the maintenance |
| | | package to |
| | | uninstall. |
+--------------------------------+-------------+----------------------+
| update.bat -W | Graphical | Overrides the |
| product.location="e: | interface | location of the |
| \IBM\WebSphere\AppServer" -W | mode | WebSphere software |
| backup.package="PQ20029.pak" | | to update and the |
| -W update.type="uninstall" | | name of the |
| | | maintenance package |
| | | to uninstall. |
+--------------------------------+-------------+----------------------+
| update.bat -options | Graphical | Overrides all |
| "responsefiles/file_name" | interface | default values with |
| | mode with | values that you |
| | an options | specified in the |
| | file | options response |
| | | file. |
| | | If you omit either |
| | | value from the |
| | | response file, the |
| | | default maintenance |
| | | package is the |
| | | installed package |
| | | with the most recent |
| | | date stamp and time |
| | | stamp. The default |
| | | software is the |
| | | software installed |
| | | in the parent |
| | | directory. |
+--------------------------------+-------------+----------------------+



Issue the following command to use the silent interface:

Table 6. Update installer command for uninstalling in silent mode
+--------------------------------+-------------+----------------------+
| Command example | Type of | Description |
| | installatio | |
| | n | |
+--------------------------------+-------------+----------------------+
| update.bat -silent -options | Silent mode | Overrides all |
| "responsefiles/file_name" | with an | default values with |
| | options | values that you |
| | file | specified in the |
| | | options response |
| | | file. |
| | | Always use a |
| | | response file that |
| | | is based on the |
| | | response file under |
| | | updi_root/responsefi |
| | | les. |
+--------------------------------+-------------+----------------------+



This procedure results in uninstalling maintenance packages to update
WebSphere software.



After uninstalling maintenance packages, you can continue to use the
WebSphere software.

Rolling back changes to existing profiles: Some maintenance packages
for WebSphere Application Server products, such as Refresh Pack 2,
update existing profiles. If you roll back a maintenance package that
contains a profile update, also use any undo scripts provided with the
profile update script to roll back changes to the existing profiles.

The readme file for a maintenance package describes scripts that update
and scripts that roll back profile fix levels. For example, Refresh Pack
2 for WebSphere Application Server includes required service for the
JDBC resource provider templates in existing profiles. See the readme
for the profile update and undo scripts for the JDBC-related update for
more information.

Deleting profiles created by a service level that is now rolled back:
See Profiles remain at the Version 6.0.2 level after roll back for a
description of a limitation that requires profiles to be at the same
service level or at a lower service level that the WebSphere Application
Server product.

For example, suppose that you install Fix Pack 1 for Version 6.1
(Version 6.1.0.1), create a new profile, and then roll back Fix Pack 1.
You must delete the profile that you created at the Version 6.1.0.1
level to avoid possible problems.

3.1 uninstall.txt

The Update Installer for WebSphere Software can use an options response
file to uninstall maintenance packages from a command line interface.

The uninstall.txt file has one directive that identifies the backup file
for uninstalling a service update. Comments in the file describe how to
set the string value.

The Update Installer for WebSphere Software wizard reads the options
file to determine uninstall choices. The Update Installer uninstalls the
maintenance package in silent mode, instead of displaying a graphical
user interface.

3.1.1 Location of the response file

The sample options response file is named uninstall.txt. The file is in
the updi_root/responsefiles directory after you unzip the Update
Installer for WebSphere Software into the installation root directory of
the WebSphere software product.

3.1.2 Uninstalling silently

The options file supplies the values to the Update installer wizard when
uninstalling silently. The wizard reads the options file to determine
responses and does not display the graphical user interface.

The following command uses a copy of the options file named
myresponsefile.txt to provide uninstall option responses during a silent
uninstall:

./update.sh -options "responsefiles/myresponsefile.txt" -silent

If you do not use the -silent option, the wizard uses the response file
to provide initial values for the graphical interface:

./update.sh -options "responsefiles/myresponsefile.txt"

3.1.3 Response file user entry validation

In a silent uninstall, response file validation has been coded into the
uninstall process. If the validation does not pass, the failure is
recorded in the log files in the app_server_root/logs/update/tmp
directory.

Location of the maintenance package to be uninstalled


Default directive setting
-W backup.package=""

Valid setting
You must set this directive to the location of the
backup file. The backup file reverses the application
of the maintenance. For example, you might specify the
following location on a Linux system:
/opt/properties/version/nif/backup/maintenance_package_to_uninstall


Error identifiers:

* The maintenance package cannot be uninstalled.
Uninstalling the maintenance would break the
following superseding maintenance packages.
Uninstall the superseding maintenance packages
first: list_of_superseding_maintenance_packages
* This maintenance package cannot be uninstalled. The
following maintenance packages are dependent on the
package that you are attempting to uninstall:
list_of_dependent_maintenance_packages
* This maintenance package cannot be uninstalled. The
following maintenance packages are dependent on the
APARs you are attempting to uninstall:
list_of_dependent_maintenance_packages
* No installation backup packages are available for
uninstalling maintenance.


Product location


Although uninstalling maintenance from another product is
possible, always use the Update installer wizard from the
directory structure of the product that you are updating if
possible. Problems can occur when a mismatch between product
SDKs occurs, for example.



Do not use this directive unless absolutely necessary.



Default directive setting
-W
product.location="SPECIFY_PRODUCT_INSTALL_LOCATION_HERE"

Valid setting
You must set this directive to the installation root
directory of the alternate product. For example, you
might specify the following location on a Linux
system:
/opt/IBM/WebSphere/AppServer2


Error identifiers:

* The maintenance package cannot be uninstalled.
Uninstalling the maintenance would break the
following superseding maintenance packages.
Uninstall the superseding maintenance packages
first: list_of_superseding_maintenance_packages
* This maintenance package cannot be uninstalled. The
following maintenance packages are dependent on the
package that you are attempting to uninstall:
list_of_dependent_maintenance_packages
* This maintenance package cannot be uninstalled. The
following maintenance packages are dependent on the
APARs you are attempting to uninstall:
list_of_dependent_maintenance_packages
* No installation backup packages are available for
uninstalling maintenance.
*

3.1.4 Usage notes

* The file is not a read-only file.
* Edit this file directly with your flat file editor of choice, such as
Kate on SLES or WordPad on a Windows platform.
* The file must exist to perform a silent uninstall. The Update
installer wizard reads this file to determine uninstall parameters.
Provide the fully qualified file path to the backup file.
* Save the copy of the options file in the responsefiles directory for
best results.

3.1.5 Example uninstall.txt file

Edit the version of the file that is included in the Update Installer
for WebSphere Software ZIP file. The following example is not guaranteed
to be an accurate representation of the actual file.

################################################################################
#
# This is the silent install response file for uninstalling maintenance packages
# using the update installer.
#
# A common use of an options file is to run the wizard in silent mode. This lets
# the options file author specify wizard settings without having to run the
# wizard in graphical or console mode. To use this options file for silent mode
# execution, *uncomment* and modify the parameters defined within.
#
# Use the following command line when running the wizard from the update
# installer directory:
#
# update -options responsefiles/uninstall.txt -silent
#
# Please enclose all values within a single pair of double quotes.
#
################################################################################


################################################################################
#
# Used to input the maintenance backup package filename to be uninstalled.
# This is the same filename as the package that was originally installed.
# A maintenance package can only be uninstalled if a backup package exists.
#
# ie. -W backup.package="PQ20029.pak"
#
# Note: If no package is specified, a default of the last installed maintenance
# package will be used.
#
#-W backup.package=""


################################################################################
#
# Used to modify the product install location that will be updated.
# This value should be left commented out if the Update Installer is
# being run from the recommended location
#
# ie. -W product.location="C:\Program Files\IBM\WebSphere\AppServer"
#
# Note: The product install location should always been specified, and it should
# always be the full path.
#
-W product.location=""



################################################################################
#
# Do not edit these values.
#
-W update.type="uninstall"

.....................................................................


So, according to documentation,
1. uninstall process requires you to log in as correct privileges.
2. you need to make sure that you are using correct UpdateInstaller.
3. in general, if the uninstallation fails, may mean that, installation is partial success.
4. check the dependencies.
5. you need to tail app_server_root/logs/update/maintenance_package.uninstall this log for any issues and act accordingly
6. Sometimes, this could be a reason -
(Sep 27, 2006 12:33:10 PM), UpdateInstaller, com.ibm.ws.install.ni.ismp.actions.PopulateTitleBarAction, msg1, IBM Update Installer for WebSphere Software V6.0.2.7
(Sep 27, 2006 12:33:11 PM), UpdateInstaller, com.ibm.ws.install.ni.ismp.actions.PopulateUninstallMaintenancePanelAction, err, CWUPI0024E: /software/IBM/WebSphere/AppServer/updateinstaller/maintenance/6.0.2-WS-WAS-SolarisSparc-FP0000005.pak is not a valid maintenance package or may be corrupted.
(Sep 27, 2006 12:33:11 PM), UpdateInstaller, com.ibm.ws.install.ni.ismp.actions.SetExitCodeAction, msg1, CWUPI0000I: EXITCODE=1
(Sep 27, 2006 12:33:11 PM), UpdateInstaller, com.ibm.ws.install.ni.ismp.actions.ISMPLogSuccessMessageAction, msg1, INSTCONFFAILED

In such cases, you can manually remove the pack and update corresponding maintenance files.

3/24/09

3/2/09

Log Rotation

What is log rotation?

WebSphere Application Server process writes different logs to log different events and errors.
They are
1. Diagnostic Trace


You can set the max file size to say, 20MB, and when ever the file maxes out, the server rotates it taking historical number. Maximum number of Historical Files Specifies the maximum number of rolled over files to keep. If historical number is 1, means that, when trace.log maxes out, it renames the trace.log with trace_currentdate.log and keep on writing into trace.log and so on.

Here is the
${SERVER_LOG_ROOT}/trace.log

2. JVM Logs

These are SystemOut.log and SystemErr.log
You can rotate the with Size and time.

3. Process Logs

These are native_stdout.log and native_stderr.log
If you verbose gc, gc information will be written into native_Stdout.log. If you dump threads on a live process, this is file which dump thread process dumps the thread information. If you have any process related errors, native_stderr.log is the location to find them. You cannot rotate these files.
4. Service Log