You are on page 1of 97

ASE 15 Upgrade Checklist For Upgrading From ASE 12.

x To the Latest Version of ASE

Sybase Technical Support, CS&S Version: 3.0 Revised: May, 2012 www.sybase.com

TABLE OF CONTENTS

INTRODUCTION ............................................................................................................................................................... 7 Audience............................................................................................................................................................ 7 Purpose ............................................................................................................................................................. 7 Where To Get Help............................................................................................................................................ 7 Assumptions and Limitations of this Document ............................................................................................... 8 Platform Migrations ............................................................................................................................ 8 New ASE Installations .......................................................................................................................... 8 ASE Tuning Limitations ........................................................................................................................ 9 Major New Features of ASE 15 ....................................................................................................................... 10 Summary of New Features for ASE 15 ............................................................................................................ 10 Summary of New Features in ASE 15.7 ............................................................................................. 10 Summary of New Features for ASE 15.5 ........................................................................................... 12 RECOMMENDED READING ............................................................................................................................................ 13 ASE Product Documentation ........................................................................................................................... 13 Sybase White Papers ....................................................................................................................................... 13 DEFINITION OF TERMS .................................................................................................................................................. 15 References....................................................................................................................................................... 15 Release Terminology ....................................................................................................................................... 15 UPGRADE PATHS FOR ASE 15........................................................................................................................................ 19 ASE 15 Upgrade Path for ASE 12.0.x and Older .............................................................................................. 19 ASE 15 Upgrade Path for ASE 12.5.x ............................................................................................................... 19 ASE 15 Upgrade Path for ASE 15.X .................................................................................................................. 19 ASE 15 Upgrade Path for 32-bit Versions of ASE ............................................................................................ 19 ASE 15 Upgrade Restrictions ........................................................................................................................... 19 ASE Supported OS Platforms ........................................................................................................................... 20 DOWGRADE AND RECOVERY PROCEDURES ................................................................................................................. 21 Downgrading ASE ............................................................................................................................................ 21 Loading Database Dumps From a Higher to a Lower Version of ASE ............................................................. 21 Recovering From a Failed Upgrade ................................................................................................................. 22 GENERAL RECOMMENDATIONS.................................................................................................................................... 23 Upgrade to the Latest Version of ASE ............................................................................................................. 23

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________ Decouple Your ASE Upgrades from Other Migrations .................................................................................... 23 Test ASE 15s New Features ............................................................................................................................ 24 ASE Interoperability and Upgrading to the Latest Version of OpenClient...................................................... 24 ASE Compatability ........................................................................................................................................... 24 UPGRADE CONSIDERTATIONS FOR ASE 15s NEW OPTIMIZER..................................................................................... 25 Upgrade Considerations for ASE 15s Optimizer Goals .................................................................................. 25 The New Optimizer Goals ................................................................................................................. 25 Implementation Considerations ....................................................................................................... 25 Upgrade Considerations for ASE 15s Optimizer Levels.................................................................................. 25 The New Optimizer Levels................................................................................................................. 25 Implementation Considerations ....................................................................................................... 26 UPGRADE CONSIDERTATIONS FOR ASE 15s NEW THREADED KERNEL ........................................................................ 26 The New Threaded Kernel............................................................................................................................... 26 Implementation Considerations ..................................................................................................................... 26 NEW LICENSING CONSIDERTATIONS FOR ASE 15 ......................................................................................................... 27 SySAM2 Licensing Changes for ASE 15............................................................................................................ 27 SySAM is Now Required for All Licenses ......................................................................................................... 27 SySAM Sub-Capacity Licensing ........................................................................................................................ 28 KNOWN ISSUES ............................................................................................................................................................. 29 Known Upgrade Issues for ASE 15.7 ............................................................................................................... 29 Where to Learn About the Latest Known Issues and Fixes............................................................................. 31 Where to Get the Latest Software Fixes ......................................................................................................... 32 PROCEDURES FOR UPGRADING FROM ASE 12.5 TO THE LATEST VERSION OF ASE ..................................................... 33 Purpose ........................................................................................................................................................... 33 Approach ......................................................................................................................................................... 33 Overview of Procedures .................................................................................................................................. 33 UPGRADE CHECKLIST FOR UPGRADING FROM ASE 12.5 TO THE LATEST VESION OF ASE ........................................... 34 Step 1: Pre-Upgrade Planning Procedures ..................................................................................................... 34 Step 2: Pre-Upgrade Steps ............................................................................................................................. 35 Step 3: Upgrade Steps for the Test Environment .......................................................................................... 36 Step 4: Post-Upgrade Steps for the Test Environment .................................................................................. 37 Step 5: Upgrade Steps for the Production Environment ............................................................................... 38
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 2 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________ Step 6: Post-Upgrade Steps for the Production Environment ....................................................................... 39 DETAILED PROCEDURES FOR UPGRADING FROM ASE 12.5.x TO THE LATEST VERSION OF ASE ................................. 40 Step 1: Pre-Upgrade Planning Procedures ................................................................................................................... 40 Step 1.1: Review the ASE Documentation ...................................................................................................... 40 1.1.1: Recommended Reading ......................................................................................................... 40 1.1.2: Release Bulletin ...................................................................................................................... 40 1.1.3: Cover Letter ............................................................................................................................ 41 1.1.4: New Features Guide ............................................................................................................... 41 Step 1.2: Identify New Features of Interest .................................................................................................... 41 Step 1.3: Determine Your Upgrade Version: Consider the Latest Release .................................................... 41 Step 1.4: Determine Your Upgrade Method ................................................................................................... 42 Step 1.5: Understand the New Licensing Requirements for ASE 15 ............................................................... 43 Step 1.6: Understand the Increased Resource Requirements for ASE 15 ...................................................... 43 Step 1.7: Consider Using the Semantic Partitioning Option ........................................................................... 43 1.7.1: Paritioning .............................................................................................................................. 43 1.7.2: Semantic Paritioning .............................................................................................................. 44 1.7.3: ASE 15.7 Partitioning Strategies ............................................................................................. 44 Step 1.8: Determine Your ASE Database Device Attributes ........................................................................... 45 Step 1.9: Review and Understand the New Optimizer Goals ........................................................................ 45 Step 1.10: Review and Understand the New Optimizer Level Settings .......................................................... 46 Step 1.11: Review and Understand the New ASE Threaded Kernel ............................................................... 47 1.11.1: Overview of the New Threaded Kernel ................................................................................ 47 1.11.2: General Considerations ........................................................................................................ 48 1.11.3: Threaded Kernel Configuration Changes ............................................................................. 48 Step 1.12: Review Any Trace Flags Used at Startup........................................................................................ 49 Step 1.13: Evaluate Client Interoperability and Third Party Compatibility..................................................... 49 Step 1.14: Evaluate Application Interfaces and Replication ........................................................................... 49 Step 1.15: Evaluate Your Disaster Recovery Procedures ................................................................................ 49 Step 1.16: Evaluate the Latest Known Issues.................................................................................................. 50 Step 1.17: Create an Overall Project Plan ....................................................................................................... 50 1.17.1: Purpose ................................................................................................................................ 50 1.17.2: Considerations ..................................................................................................................... 50 Step 1.18: Create a Tactical Plan ..................................................................................................................... 51 1.18.1: Purpose ................................................................................................................................ 51

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 3 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________ 1.18.2: Considerations ..................................................................................................................... 51 Step 1.19: Create a Test Plan .......................................................................................................................... 52 1.19.1: Goals..................................................................................................................................... 52 1.19.2: Considerations ..................................................................................................................... 52 Step 2: Pre-Upgrade Procedures .................................................................................................................................. 53 Step 2.1: Build a Test Environment to Perform Post-Upgrade Testing .......................................................... 53 Step 2.2: Identify, Obtain and Deploy Your New ASE 15 Licenses .................................................................. 53 2.2.1: Overview ................................................................................................................................ 53 2.2.2: Idenifying Your ASE Licenses .................................................................................................. 53 2.2.3: Choosing a License Model ...................................................................................................... 54 2.2.4: Downloading Your ASE Core License ..................................................................................... 54 2.2.5: Download Your Optional ASE Licenses .................................................................................. 56 2.2.6: Deploy Your New SySAM2 Licensing Files.............................................................................. 56 2.2.7: SySAM Licensing Documentation........................................................................................... 56 2.2.8: Detect SySAM Errors and Take the Appropriate Action ........................................................ 57 Step 2.3: Create a Pre-Upgrade Baseline of Query Performance ................................................................... 58 Step 2.4: Generate and Save Abstract Plans ................................................................................................... 59 Step 2.5: Verify the Free Space in All Databases ............................................................................................ 59 Step 2.6: Verify the Number of Locks Configured for Upgrade ...................................................................... 60 Step 2.7: Consider Replacing the Update Statistics Command ...................................................................... 60 Step 2.8: Perform the Pre-Upgrade Steps in the Install Guide ....................................................................... 61 Step 2.9: Perform the Pre-Installation Tasks For a Clean Install (as needed) ................................................. 62 Step 2.10: Perform the Pre-Upgrade Steps for Applying an EBF .................................................................... 62 Step 2.11: Implement Your ASE Database Device Attributes ......................................................................... 62 Step 2.12: Check the Consistency of the Master and All User Databases ...................................................... 62 2.12.1: General Consistency Checks ................................................................................................ 62 2.12.2: Check System Tables ............................................................................................................ 62 Step 2.13: Backup All User Databases............................................................................................................. 63 Step 2.14: Backup the Master Database ......................................................................................................... 63 Step 2.15: Dump the Transaction Log ............................................................................................................. 64 Step 3: Upgrade Steps for the Test Environment ........................................................................................................ 65 Step 3.1: Bulk Copy Out Key System Tables .................................................................................................... 65 Step 3.2: Disable Replication........................................................................................................................... 65 Step 3.3: Unpartition All Partitioned Tables ................................................................................................... 66
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 4 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________ Step 3.4: Quiesce All Databases ...................................................................................................................... 66 Step 3.5: Perform the Upgrade ....................................................................................................................... 67 Step 3.6: Upgrade Your Client Software ......................................................................................................... 67 Step 3.7: Upgrade Your Middleware, Interfaces and 3rdParty Software ........................................................ 67 Step 3.8: Upgrade Any Other Software .......................................................................................................... 67 Step 4: Post-Upgrade Steps for the Test Environment ................................................................................................ 68 Overview ......................................................................................................................................................... 68 Step 4.1: Perform the Post-Upgrade Steps ..................................................................................................... 68 4.1.1: Post-Installation Tasks............................................................................................................ 68 4.1.2: Post-Upgrade Tasks For Your EBF .......................................................................................... 68 4.1.3: Rolling Back an EBF ................................................................................................................ 69 4.1.4: Re-Enable Replication ............................................................................................................ 69 Step 4.2: Recreate Table Partitions................................................................................................................. 69 Step 4.3: Replace the Update Statistics Command ..................................................................................... 69 Step 4.4: Delete or Update Stale Statistics ..................................................................................................... 69 4.4.1: Identify Stale Statistics ........................................................................................................... 70 4.4.2: Delete Stale Statistics ............................................................................................................. 70 4.4.3: Restore Statistics (as needed) ................................................................................................ 70 Step 4.5: Recreate Optimizer Statistics ........................................................................................................... 70 4.5.1: Missing Statistics .................................................................................................................... 70 4.5.2: Estimate Ideal Step Counts .................................................................................................... 71 4.5.3: Optimizer Statistics Documentation ...................................................................................... 72 Step 4.6: Configure and Tune the New ASE 15 Resources Requirements ...................................................... 72 Step 4.6.1: Overview ........................................................................................................................ 72 Step 4.6.2: Configure Procedure Cache ........................................................................................... 72 Step 4.6.3: Re-Size Tempdb ............................................................................................................. 72 Step 4.6.4: Semantic Partitioning and Sizing the Number of Open Partitions ................................ 73 Step 4.6.5: Statement Cache and Literal Auto-Parameterization.................................................... 73 Step 4.7: Configure and Tune the New Kernel Resource Settings .................................................................. 75 4.7.1: Overview ................................................................................................................................. 75 4.7.2: Switching Kernel Modes......................................................................................................... 75 4.7.3: Setting the File Descriptor Values .......................................................................................... 76 4.7.4: Setting the Kernel Resource Memory Parameter .................................................................. 77 4.7.5: Setting the Max Online Engines Parameter ........................................................................... 78 4.7.6: Setting the Idle Timeout Parameter ...................................................................................... 78 4.7.7: Errorlog Changes .................................................................................................................... 81
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 5 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________ 4.7.8: Testing .................................................................................................................................... 81 Step 4.8: Create and Maintain a Post-Upgrade Baseline ................................................................................ 81 Step 4.8.1: Overview ........................................................................................................................ 81 Step 4.8.2: Create a Post-Upgrade Baseline .................................................................................... 82 Step 4.8.3: Compare Pre-Upgrade and Post-Upgrade Performance ............................................... 82 Step 4.9: Test and Tune Your New Optimizer Settings .................................................................................. 82 Step 4.9.1: Test and Tune Your New Optimization Goals ................................................................ 82 Step 4.9.2: Advanced Tuning Techniques: Optimizer Level Settings ............................................... 85 Step 4.9.3: Advanced Tuning Techniques: The QPTune Tool .......................................................... 87 Step 4.9.4: Advanced Tuning: Query Processing, Abstract Plans and More .................................... 89 Step 4.9.5: The Optimizer Compatibility Mode: The Option of Last Resort ..................................... 89 Step 4.10: Test Any New Features You Will Be Using .................................................................................... 91 Step 4.11: Verify Application Consistency and Stability ................................................................................. 91 Step 4.12: Verify Backup and Recovery Procedures ....................................................................................... 91 Step 4.13: Standardize Your Upgrade Procedures .......................................................................................... 92 Step 5: Upgrade Steps for the Production Environment ............................................................................................. 93 Step 6: Post-Upgrade Steps for the Production Environment ..................................................................................... 93 Step 6.1: Perform Post-Upgrade Steps in Release Bulletin and Cover Letter ................................................ 93 Step 6.2: Recreate Table Partitions ................................................................................................................ 93 Step 6.3: Replace Update Statistics Command .............................................................................................. 93 Step 6.4: Recreate Optimizer Statistics .......................................................................................................... 93 Step 6.5: Configure the New Resource Requirements for ASE 15 ................................................................. 94 Step 6.5.1: Configure Procedure Cache ........................................................................................... 94 Step 6.5.2: Re-Size Tempdb ............................................................................................................. 94 Step 6.5.3: Semantic Partitioning and the Number of Open Partitions .......................................... 94 Step 6.5.4: Statement Cache and Literal Auto-Parameterization.................................................... 94 Step 6.6: Configure the New Kernel Resources ............................................................................................. 94 Step 6.7: Configure the New ASE 15 Optimizer Settings ............................................................................... 94 Step 6.7.1: Implement Your New Optimization Goals ..................................................................... 94 Step 6.7.2: Implement Your New Optimizer-Level Settings ............................................................ 94 Step 6.7.3: Implement Advanced Tuning Settings (as needed) ....................................................... 94 Step 6.8: Perform Other Software Upgrades as Needed ............................................................................... 95 Step 6.9: Verify Database Consistency ........................................................................................................... 95 Step 6.10: Backup Your Upgraded User and Master Databases .................................................................... 95

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 6 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

INTRODUCTION

AUDIENCE
This document was created by Sybase Technical Support and is intended for Sybase DBAs who are preparing to upgrade their existing Sybase Adaptive Server Enterprise (ASE) software to the latest version of ASE 15.

PURPOSE
The purpose of this document is to provide a single source of procedures to help ensure an efficient and seamless upgrade from 12.5 to ASE 15: For ASE installations on version 12.0 or older, it is important to note that Sybase strongly recommends that you first upgrade to ASE 12.5.4 ESD#10. Therefore, this document only addresses upgrading from ASE 12.5 to ASE 15. For those sites already on ASE 15, please see the companion to this guide: the ASE 15 Upgrade Checklist for Upgrading from ASE 15.x to the Latest Version of ASE at:
http://www.sybase.com/support/techdocs/migration

WHERE TO GET HELP


Given the complexities of a major upgrade, a single document cannot replace all of Sybases documentation and technical support resources. Therefore, it is important that you review the Sybase Product documentation and White Papers listed in the Recommended Reading section below, as well as other ASE product documentation as needed. You are also encouraged to call Sybase Technical Support with any questions before, during or after your upgrade. If you have specific questions or issues regarding this document, please contact us at migration_help@sybase.com.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 7 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

ASSUMPTIONS AND LIMITATIONS OF THIS DOCUMENT


PLATFORM MIGRATIONS This document does NOT address database migrations, these include: o o o o o Moving from one hardware platform to another (for example, from Sun to IBM). Moving from one OS platform to another (for example, from Windows to Linux). Moving from a non-ASE DBMS to ASE (for example, from Oracle to ASE). Increasing or decreasing database page size. Changing OS byte-order: Moving from a little endian byte order to a big endian byte order.

These migration tasks are outside the scope this document. However, this paper does reference documents for performing some of these tasks. NEW ASE INSTALLATIONS This document does NOT address the procedures for installing ASE for the FIRST time. Rather, this document is intended as a guide for upgrading your existing ASE server to the latest version of ASE 15. However, since many of the procedures for these two tasks are the same, this document can serve as a useful supplement to planning and implementing a new ASE installation. For more information on installing ASE, see the following: o ASE Product Guides: The ASE 15.7 Installation Guide for your OS platform. The ASE 15.7 Configuration Guide for your OS platform. The ASE 15.7 New Features Summary. The ASE Release Bulletin for your version of ASE and platform. These ASE product guides are available from our online Sybooks Product Documentation site at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.help.ase.15.7/ti tle.htm&docSetID=1797:

o o

Sybase White Papers: Please see the Recommended Reading section below for links to a number of these documents. Sybase also provides training and consulting services through our Education and Professional Services organizations to assist with performing, configuring and tuning new and existing ASE installations.

Lastly, if you have specific questions about your installation, please call Sybase Technical Support.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 8 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


ASE TUNING LIMITATIONS This document assumes you have a well functioning ASE 12.5 server.

Sybase ASE 15

_________________________________________________________________________________________________

Therefore, the configuration and tuning procedures presented in this document are limited to those directly affected by upgrading from ASE 12.5 to the latest version of ASE 15. This document does NOT address all the installation, configuration and tuning considerations for a newly installed or poorly performing ASE server. For more information on tuning ASE, please see the following: o o The performance and tuning White Papers referenced in the Recommended Reading section of this document below. For a compressive guide to tuning ASE 15, please see the ASE 15.7 Performance and Tuning Series Guides available on our Sybooks Product Documentation Site:
o Performance and Tuning Series: Basics: http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc20020.1570/html /basics/title.htm Performance and Tuning Series: Improving Performance with Statistical Analysis: http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00976.1570/html /statistics/title.htm Performance and Tuning Series: Locking and Currency Control: http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00938.1570/html /locking/title.htm Performance and Tuning Series: Monitoring ASE with sp_sysmon: http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00842.1570/html /spsysmon/title.htm Performance and Tuning Series: Monitoring Tables: http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00848.1570/html /monitor_tables/title.htm Performance and Tuning Series: Physical Database Tuning: http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00841.1570/html /phys_tune/title.htm Performance and Tuning Series: Query Processing and Abstract Plans: http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00743.1570/html /queryprocessing/title.htm Adaptive Server Enterprise 15.0 > Performance and Tuning: Query Processing and Abstract Plans > Controlling Optimization > Optimization Goals at: http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.dc00743_1500/html/qp_abstr pln/qp_abstrpln154.htm The QPTune Tool: http://www.sybase.com/products/databasemanagement/adaptiveserverenterprise/migrate Online Technical Resources: ASE 15 Post-Migration Performance Tuning

o o

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 9 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

MAJOR NEW FEATURES OF ASE 15


ASE 15.5 and ASE 15.7 introduced architectural changes that you must consider and test when upgrading from earlier versions of ASE 15: o The Threaded Kernel: ASE 15.7 introduces a new thread-based kernel. This replaces the process-based kernel in ASE 15.5 and below. Consequently, there are several configuration and resource settings that need to be implemented, tested and tuned. These are discussed in the Post-Upgrade section below.

Optimizer Level Settings: ASE 15.5 introduced optimizer level settings. Although these are advanced tuning settings, you may want to take advantage of these settings depending on your performance requirements.

Ongoing Optimizer Enhancements: ASEs optimizer is always being enhanced. Therefore, it is a good idea to test your most critical queries (at a minimum) whenever you upgrade to a newer version of ASE or apply a new EBF.

This guide includes procedures for addressing these new features and enhancements.

SUMMARY OF NEW FEATURES FOR ASE 15


The following is a summary of features introduced in the most recent releases of ASE. Only a few of these features are covered in this guide, since most of them are not directly involved in upgrading to the latest versions of ASE 15. However, these features include many significant enhancements that you may want to consider. If you decide to implement any of these features as part of your upgrade, plan to include them in your test plan. SUMMARY OF NEW FEATURES IN ASE 15.7 The following is a brief summary of new features in ASE 15.7. Please see the New Features Guide for more details:
The Application Functionality Configuration Group The New Adaptive Server Thread-Based Kernel Data Compression: Lets you use less storage space for the same amount of data, reduce cache memory consumption, and improve performance because of lower I/O demands. New Security Features: End-to-end CIS Kerberos authentication, dual control of encryption keys and unattended startup, securing logins, roles and password management extensions, and login profiles.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 10 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________ Abstract Plans in Cached Statements: Allows you to save abstract plan information in statement cache. Shrink Log Space: Allows you to shrink the log space and free storage without re-creating the database by using the alter database command to remove unwanted portions of a database log. Displaying Currently Set Switches: Allows you to see all traceflags at the server and session level. Changes for Large Objects: Includes storing in-row LOB columns for small text, image, and unitext datatypes, storing declared SQL statements containing LOBs, indirectly referencing a LOB in Transact-SQL statements, and allowing checking for null values of large objects. Showing Cached Plans in XML: The new show_cached_plan_in_xml function returns a showplan output in XML for a statement in cache. Padding a Character Field Using str: Allow a field to be padded with a specified character or numeric. Changes to select for update: Allows select for update command to exclusively lock rows for subsequent updates within the same transaction, and for updatable cursors. Creating Nonmaterialized, Non-null Columns: Allows creation of nonmaterialized, non-NULL columns. Sharing Inline Defaults: Allows sharing inline defaults between different tables in the same database. Retain Monitoring Data: Monitoring data is retained to improving query performance. Analyze Dynamic Parameters: Dynamic parameters (which are indicated by question marks) before running a query, can be analyzed to avoid inefficient query plans. Monitor Lock Timeouts: Allows you to monitor lock timeouts. Truncate Trailing Zeros: Enable or disable truncation of trailing zeros from varbinary and binary null data. Fully Recoverable DDL: Use dump transaction to fully recover the operations that earlier versions of Adaptive Server minimally logged. Transfer Rows from Source to Target Table Using merge: Allows transferring rows from a source to a target table. View Statistics and Histograms with sp_showoptstats: Allows you to extract and display, in an XML document, statistics and histograms for various types of data objects from system tables such as systabstats and sysstatistics. Changes to Cursors: Changes to how cursors lock, manage transactions, and are declared. Nested select Statement Enhancements: Expands the abilities of the asterisk (*). Chained Transactions: Some system procedures may run in sessions that use chained transaction mode. Expanded Variable-Length Rows: Redefines data-only locked (DOL) columns to use a row offset of up to 32767 bytes. Requires a logical page size of 16K to create wide, variable-length DOL rows. Like Pattern Matching: Treat square brackets individually in the like pattern-matching algorithm. Quoted Identifiers: Use quoted identifiers for tables, views, column names, index names, and system procedure parameters.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 11 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

Allowing Unicode Noncharacters: Enable permissive unicode configuration parameter, which is a member of enable functionality group, allows you to ignore Unicode noncharacters. Reduce Query Processing Latency: Enables multiple client connections to reuse or share dynamic SQL lightweight procedures (LWPs). The sybdiag Utility: A new Java-based tool that collects comprehensive ASE configuration and environment data for use by Sybase Technical Support. The Optimizer Diagnostic Utility: Adds the sp_opt_querystats system procedure, which allows you to analyze the query plan generated by the optimizer and the factors that influenced its choice of a query plan.

SUMMARY OF NEW FEATURES FOR ASE 15.5 The following is a brief summary of new features in ASE 15.5. Please see the New Features Guide for more details: In-memory databases that improve performance by operating entirely in-memory and not reading/writing transactions to disk. Relaxed-durability for disk-resident databases that improve performance by eliminating committed transactions. Dump database and load database functionality is available for both in-memory and relaxed-durability databases. Faster compression for backups is provided by two new compression options (level 100 and 101). Backup Server Support for the IBMs Tivoli Storage Manager. Deferred name resolution allows the creation of stored procedures before the referenced objects are created in the database. FIPS 140-2 encryption is now supported for login passwords that are transmitted, stored in memory or stored on disk. Incremental Data Transfer allows exporting only rows that have changed since a previous transfer, or extracting selected rows into an output file, and does so without blocking ongoing reads and updates. The new bigdatetime and bigtime datatypes provide microsecond precision. You can now create and manage user-created tempdb groups, in addition to the default tempdb group. The new monTableTransfer table provides historical transfer information for tables. The new system table, spt_TableTransfer, stores results from table transfers. The sysdevices table has been modified to list the in-memory storage cache under the name and phyname columns. Auditing options have been added to support in-memory and relaxed-durability databases, incremental data transfer, and deferred name resolution.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 12 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x RECOMMENDED READING

Sybase ASE 15

_________________________________________________________________________________________________

It is strongly recommended that you review the ASE product documentation and Sybase White Papers listed below before planning and performing your upgrade.

ASE PRODUCT DOCUMENTATION 1. The ASE Release Bulletin: Please read the Release Bulletin for the base-level version of ASE you
are upgrading to (such as 15.0 or 15.5). This contains important current information about the release.

2. The ASE EBF Cover Letter: If you are also applying an EBF, please read this document. It contains
the definitive list of fixes contained in the EBF, as well as important current information about this patch.

3. The ASE Installation Guide for your version and platform for ASE. For example, the Installation Guide for ASE 15.7 on Linux is at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc30119.1570/doc/html/title.html

4. The ASE Configuration Guide for your platform for ASE. For example, the ASE 15.7 Configuration Guide for UNIX is at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc35823.1570/html/uconfig/title.h tm

5. New Features in Adaptive Server Version 15.7:


http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc01165.1570/doc/html/title.hml

6. New Features in Adaptive Server Version 15.7 ESD#1:


http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00650.1570/html/nf b_157_1/title.htm

SYBASE WHITE PAPERS 7. Planning Your ASE 15.0 Migration:


http://www.sybase.com/files/White_Papers/PlanningASE15Migration-040307.pdf

8. The Migration Technology Guide: Please read the Migration Guide for the version of ASE you are upgrading to. For example, The ASE 15.5/ASE 15.7 Migration Technology Guide can be found at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00967.1550/html/MigrationGu ide/title.htm

9. Sybase ASE 15.0 Best Practices: Query Processing and Optimization:


http://www.sybase.com/files/White_Papers/ASE15-Optimizer-Best-Practices-v1-051209-wp.pdf
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 13 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

10. Required SQL Code Changes When Migrating To ASE 15:


http://www.sybase.com/files/White_Papers/SY-Required-SQL-Changes-for-ASE15-v.1-073009-WP.pdf

11. Semantic Partitions in ASE 15.0 (White Paper):


http://www.sybase.com/files/White_Papers/ASE-Partitions-040307-wp.pdf

12. Performance on Sybase Devices Using Direct I/O, Dsync and Raw Partitions:
http://www.sybase.com/content/1043413/DirectIO-082906-wp.pdf

13. Changes to Scope & Semantics of Session-Level Optimization Settings in ASE 15.0.2:
http://www.sybase.com/files/White_Papers/ASE1502_OptimizationCriteria_v1_0.pdf

14. Handling Long-running Rollbacks and Recovery:


http://www.sybase.com/detail?id=1062433&contentOnly=true

15. Upgrading to ASE 15 - An in-depth view of the (un)expected:


http://www.sybase.com/detail?id=1061943&contentOnly=true

16. Get the Latest Version of this ASE 15 Upgrade Guide: Be sure and double check that you have the latest version of this document at: http://www.sybase.com/support/techdocs/migration

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 14 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

DEFINITION OF TERMS

REFERENCES
Sybase uses a series of terms to distinguish its different types of software releases. Below, is a listing of release terms and their definitions used throughout this and other Sybase documentation. Understanding these terms will help with this and future Sybase installation and upgrade tasks. These definitions are based on common Support usage and several published documents, including the following: Versioning Policy for Sybase Products: http://www.sybase.com/detail?id=1091173 The Release Terminology section of the Targeted ASE 15.x Release Schedule and CR list Information:
http://www.sybase.com/detail?id=1038641 .

Sybase Product Life-Cycle Policies: http://www.sybase.com/products/databasemanagement/productlifecycle

RELEASE TERMINOLOGY
1. Release Designations: Sybase product releases are denoted in the form "X.Y.Z": Where 'X' represents the Major release version, 'Y' represents the Intermediate release version and 'Z' represents the Maintenance release version. As an example, the release designation of ASE 15.7 signifies an Intermediate release of ASE 15.x. 2. Release Family: A Release Family consists of all the software releases within the same Major release number. For example, ASE 15.0.1, 15.0.2, 15.0.3, 15.5 and 15.7 all belong to the same ASE 15 release family, since they all share the same major release number of 15. 3. General Availability (GA): This is an official release of Sybase software that is available to all customers and can be obtained from the Sybase Product Download Center (SPDC) portal. It is distinguished from several types of restricted releases that can only be obtained through Technical Support or Sybase Engineering. The term GA is also sometimes used by Customer Service to refer to the initial release of Sybase software, such as 15.0, 15.5, or 15.7. 4. Major Release: This is a full release of ASE software that contains major product enhancements, performance improvements and software bug fixes. It may also involve an upgrade of the database catalogs. A major release is designated by a change in the first (X) level of the version number. For example, versions 12 and 15 are major releases. Major releases must be installed into their own new directory and should not be installed over a prior release. For example, ASE 15 cannot be installed over ASE 12.5.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 15 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

5. Intermediate Release: This is a full release of ASE software that contains product enhancements, performance improvements and bug fixes. It may also include an upgrade of the system database catalogs. An intermediate release is designated by a change in the second (Y) level of the version number. For example, ASE 15.5 and ASE 15.7 are intermediate releases within the 15.x release family. An intermediate release is normally applied as a binary update to a previous full release, but it can also be installed into its own directory. For example, ASE 15.7 can be applied over 15.5 or into a new directory. In most cases, switching between intermediate releases can be achieved by following the guidelines and instructions noted in the ASE Release Bulletin or EBF Cover Letter. 6. Base Release: This term refers to the FIRST release of a Major or Intermediate version of ASE. Examples of ASE Base releases include ASE 12.5, 15.0, 15.5 and 15.7. A Base Release includes all the software necessary to run ASE and serves as a base for subsequent patches. It is typically installed into a new directory. However, in some cases it can be installed over an earlier version of the same release family (as stated in the Release Bulletin). For example, ASE 15.7 can be installed over ASE 15.0 or 15.5. 7. Maintenance Release (MR): A Maintenance Release is a full release of ASE software that contains all the software needed to run ASE plus all the fixes from previous patches (see ESDs below). In some cases, it also introduces new features as noted in the Release Bulletin and/or Cover Letter. An MR is sometimes referred to as a shelf copy replacement (SRC) and can be installed into a new directory or as a binary overlay of an earlier version within the same release family. A maintenance release is denoted by a change in the third (Z) level of the software version number. For example, 12.5.2, 12.5.4 and 15.0.3 are all maintenance releases. 8. Interim Release (IR): This type of release contains all the fixes in previous ESDs together with other bug fixes. It is similar to an MR with one important exception: IRs are NOT complete software versions, and they MUST be installed over their corresponding GA release. For example, 12.5.0.3 must be installed over the base 12.5 GA release or one of its ESDs. 9. ESD (Electronic Software Distribution): This is an official release that addresses multiple software bugs in a designated release. ESDs are often referred to as patches or patch levels. Please note the following about ESDs: An ESD is denoted by a # <patch_number> at the end of its release version and MUST be installed over its corresponding base release. For example: o ASE 12.5.4 ESD#10 contains software fixes for 12.5.4 and must be installed over the 12.5.4 base release directory. o o o ASE 15.0.3 ESD#2 contains fixes for 15.0.3 and must be installed over the 15.0.3 base release. ASE 15.7 ESD#1 contains software fixes for and 15.7 and must be installed over a 15.7 base release directory. NOTE: Although ESD numbers are the same across all software platforms, they are given a unique EBF number (i.e., EBF 19803) for each OS platform that ASE runs on. See the EBF section below.

ESDs do not typically contain new functionality. When they do, it is noted in the EBF Cover Letter. ESDs are cumulative for a given release. For example, ESD#3 would include all the fixes from ESD#1 and ESD#2.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 16 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

10. EBF (Emergency Bug Fix): This is the platform specific version of an ESD release. Each EBF is given a unique number for each ASE platform. For example: EBF 19803 is the unique release for 15.7 ESD#1 on AIX. EBF 19805 is the unique release for 15.7 ESD#1 on Linux X86-64. EBF 19807 is the unique release for 15.7 ESD#1 on Solaris. 11. EBF Cover Letter: An EBF Cover Letter accompanies each EBF and contains the final list of bug fixes as well as important information about the EBF. 12. Release Bulletin: A Release Bulletin accompanies each new release version. It contains special installation instructions and the latest known issues that are NOT contained in the Sybooks product documentation. It provides the most recent information about the release and supersedes the information in the product documents such as the Installation and Configuration Guides. It is critical that you review the Release Bulletin before installing Sybase software. 13. Major Upgrade: A major upgrade introduces significant new features and enhancements to ASE. It involves a move to a newer major release version of ASE. For example, upgrading from ASE 12.x to ASE 15.x is a major upgrade. 14. Intermediate Upgrade: An intermediate upgrade introduces moderate changes and additions to ASE. It results in a move to a more recent intermediate level of an ASE release family. For example, upgrading from ASE 15.5 to 15.7 is an intermediate upgrade. 15. Minor Upgrade: This is an upgrade that introduces minor enhancements to ASE along with new software fixes. It results in a version number increment at the third (Z) level. For example, moving from 15.7.0 to 15.7.1 is a minor upgrade. 16. Migration: A migration is distinct from an upgrade in that it involves moving from one major architecture to another. Examples of migrations include the following: Moving from one OS platform to another (Windows to Linux). Moving from one hardware platform to another (Solaris to AIX). Moving from little endian to big endian binary architecture (or vice versa). Moving from one database page size to another. Moving from one DBMS platform to another (non-ASE to ASE).

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 17 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

17. End-of-Life (EOL): A product is End-of-Lifed when Engineering support ends for all members within a release family. This means bug fixes are no longer provided or backported to any member of the EOLd release family. Instead, bug fixes are provided for the latest supported releases. For example, when ASE 12.5 was EOLd, all new bug fixes were delivered to the most recent version of 15. Please note the following about End-of-Life products: Before a product is EOLd, Sybase issues an End-of-Life (EOL) notice well in advance of the EOL date, usually a year or more. A product is not EOLd until after the introduction of a new release family. Technical Support is still provided to all EOLd products. However, since new bug fixes cannot be provided, the resolution of any bug related issue requires an upgrade to a more recent version of ASE (depending on where the issue is fixed). 18. CR: This is an acronym for Change Request. It is often referred to as a bug fix, although it may also refer to a feature request. CRs are identified by a unique number and are used to identify the discovery and resolution of a software issue or request. 19. Sybase Product Download Center (SPDC): This is Sybases online portal for obtaining official GA releases of licensed Sybase software. All full official releases of Sybase software can be obtained from this site. This site can be found at: https://sybase.subscribenet.com.

20. Sybase Support Download Portal: NOTE: What is not available on the SPDC site is software patches (EBFs). These are available from our Sybase.com Support>Download menu at:
http://downloads.sybase.com/swd/base.do?client=support .

21. Controlled Releases, Instrumented Releases and One-Offs: These are limited availability releases designed to address specific Customer or Engineering needs. They must be obtained through Sybase Technical Support and cannot be found on either the SPDC or EBF download portals.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 18 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

UPGRADE PATHS FOR ASE 15

ASE 15 UPGRADE PATH FOR ASE 12.0.X AND OLDER


For ASE installations of version 12.0.x and older, Sybase strongly recommends that you first upgrade to ASE 12.5.4 ESD#10, and then upgrade to ASE 15. Once you have upgraded to ASE 12.5.4, please see the ASE 15 Upgrade Checklist for ASE 12.5.x below.

ASE 15 UPGRADE PATH FOR ASE 12.5.X


For servers running on ASE 12.5.x, you can upgrade directly to any version of ASE 15. For these upgrades, please see the ASE 15 Upgrade Checklist for ASE 12.5 in the section below. Please note there is one exception for ASE 12.5 upgrades: You can NOT upgrade directly from ASE 12.5.3a to ASE 15. This was an early release of 12.5.x encryption functionality. To upgrade from ASE 12.5.3a, you must first upgrade to ASE 12.5.4 and then upgrade to ASE 15.x.

ASE 15 UPGRADE PATH FOR ASE 15.X


For ASE installations already on version 15, you can upgrade directly to the latest version of ASE 15: You can perform this upgrade using the Clean-Install (dump and load) method or as a binary overlay. For more details on this type of upgrade, see the companion to this document, the ASE 15.x Upgrade Checklist for ASE 15 on the ASE Migration Website at http://www.sybase.com/support/techdocs/migration .

ASE 15 UPGRADE PATH FOR 32-BIT VERSIONS OF ASE


You can upgrade from a 32-bit version of ASE to a 64-bit version of ASE. However, you can not upgrade or downgrade from a 64-bit version to a 32-bit version.

ASE 15 UPGRADE RESTRICTIONS


The following restrictions apply to ASE upgrades: 1. You can not use the upgrade procedures in this document to move from a higher version of ASE to a lower version of ASE. This is a downgrade. Further, downgrades are NOT supported between major versions of ASE. For example, you can not downgrade from ASE 12.5 to ASE 15. Please see the downgrade section below for more details.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 19 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

2. You can not change page sizes during an ASE upgrade. Changing the servers database page size requires a database migration. For detailed information about performing this type of migration, see the sybmigrate utility in the ASE Utility Guide. For example, the ASE 15.7 Utility Guide can be found online at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc30191.1570/html/utilitygu ide/title.htm

3. You can not change from a 64-bit version of ASE to a 32-bit version of ASE during an upgrade. 4. You can not upgrade from certain versions of the ASE 15.x Cluster Edition to an SMP version of ASE 15. That is, you can not upgrade from ASE Cluster Edition below 15.5 ESD#3 (such as 15.0.1 and 15.0.3) to a higher version of ASE 15.x (such as ASE 15.7 or above). However, you can load an ASE Cluster Edition 15.5 ESD#5 database into an ASE 15.7 SMP server. 5. You can NOT upgrade directly from ASE 12.5.3a to ASE 15. You must first upgrade to ASE 12.5.4 and then upgrade to ASE 15.x. 6. You can not change OS/Hardware platforms during an ASE upgrade. That is, you can not upgrade from an ASE version built on Solaris to an ASE version built on Linux. This is a crossplatform migration. There are several options for accomplishing this task, including Bulk Copy (BCP), Replication and Cross-Platform dump and load. These methods have documented restrictions, issues and procedures that are outside the scope of this document. In the case of a cross-platform dump and load, you must be cognizant of any change in the new platforms binary architecture (big endian vs. little endian). For more details on cross-platform dump and loads, please see the following: Adaptive Server Enterprise 15.7 > System Administration Guide: Volume 2 > Developing a Backup and Recovery Plan > Using the dump and load commands > Dumping and loading databases across platforms at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc31644.1570/html /sag2/sag2418.htm Adaptive Server Enterprise 15.7 > System Administration Guide: Volume 1 > Configuring Character Sets, Sort Orders, and Languages > Changing the character set, sort order, or message language > Handling suspect partitions at http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc31654.1570/html /sag1/sag1533.htm

ASE SUPPORTED OS PLATFORMS


The Operating Systems certified for ASE have not changed between ASE 12 and ASE 15. Therefore, you are not required to change OS platforms in order to upgrade from ASE 12 to ASE 15.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 20 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

DOWGRADE AND RECOVERY PROCEDURES

DOWNGRADING ASE
In general, downgrading is only possible between minor versions of ASE. When this option is available, it is documented in one or more of the product installation documents such as the ASE Installation Guide, the Release Bulletin, and/or the Cover Letter. For example, to load the dumps of 15.7 into a server of a lower minor version (such as 15.0.1) you would do the following: 1) Execute sp_downgrade in the 15.7 version Adaptive Server to downgrade the databases to be dumped. 2) After the downgrade succeeds, dump the downgraded databases. 3) Load the dumps of the downgraded databases into the lower version of ASE 15.x (such as 15.0.1). 4) For more details, see: The Downgrade Instructions in the Release Bulletin for your server and platform. For example, for ASE 15.7 on AIX, see Special Downgrade Instructions in the ASE 15.7 Release Bulletin for IBM AIX at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc72410.1570/doc/ html/git1315856527084.html

The sp_downgrade command in the System Procedures section of the ASE 15.7 Reference Manual: Adaptive Server Enterprise 15.7 > Reference Manual: Procedures > System Procedures at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc36273.1570/html /sprocs/BEICAGIG.htm

LOADING DATABASE DUMPS FROM A HIGHER TO A LOWER VERSION OF ASE


ASE upgrades result in changes to the underlying structures of ASE (such as system catalogs, object maps, and data structures). Therefore, you can NOT downgrade ASE by simply loading a database dump from a higher version to a lower version of ASE. Doing so will irreversibly corrupt your data. Consequently, NEVER load a database dump from a higher version of ASE to a lower version. To move data from a higher version of ASE to a lower version, you must consider one of the following methods: 1. ASE Downgrade: In this case, you must first downgrade the new server to the same version as your older target server, and then perform a database dump. However, a downgrade is NOT possible between most versions of ASE, especially between major versions of ASE. The architectural changes in major versions are too extensive to be removed. For example, downgrading from ASE 15.x to ASE 12.x is not possible. When a downgrade is possible, it is usually between minor versions and it is noted in the installation documentation. See the Downgrading section below.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 21 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

2. Binary Unload and Reload: In cases where data must be moved to a lower major version of ASE, one option is to perform a raw binary unload/reload using ASEs BCP utility or a similar third party product. For more information on Sybases BCP utility, see the chapter on Transfer Data to and from Adaptive Server with bcp in the ASE 15.7 Utility Guide at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc30191.1570/html/utilitygu ide/BABGCCIC.htm

3. Replication: A third option is to use Sybases Replication Server to move data between higher and lower versions of ASE. Since Sybases Replication Server uses log-based replication, data can be safely transferred between different versions of ASE (and with additional middle-ware, across different DBMS platforms such as Oracle or DB2). For more information, see the Replication Server documentation.

RECOVERING FROM A FAILED UPGRADE


If you need information on recovering from a failed upgrade, see Recovering From a Failed Upgrade in the ASE Installation Guide for your platform. For example, for ASE 15.7 on Linux, see Adaptive Server Enterprise 15.7 > Installation Guide Adaptive Server Enterprise 15.7 for Linux > Troubleshoot the Server > When an Upgrade Fails at
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc30119.1570/doc/html/ate1314567 116079.html .

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 22 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

GENERAL RECOMMENDATIONS
UPGRADE TO THE LATEST VERSION OF ASE
Unless you have a specific business requirement, or Sybase explicitly instructs you to do otherwise, we recommend that you upgrade to the latest full release of ASE plus the latest ESD. For example, ASE 15.7 ESD#1. The most recent versions of ASE contain the latest features and software fixes. It is also Engineerings most actively supported version of ASE software. To identify the latest version of ASE, check one of the following: 1. The Sybase Download Center at:
https://sybase.subscribenet.com/control/sybs/login?nextURL=%2Fcontrol%2Fsybs%2Findex

2. The ASE Product Page at:


http://www.sybase.com/products/databasemanagement/adaptiveserverenterprise

3. Sybase Technical Support.


4.

The Targeted ASE 15.x Release Schedule and CR list Information:


http://www.sybase.com/detail?id=1038641 .

DECOUPLE YOUR ASE UPGRADES FROM OTHER MIGRATIONS


It is not uncommon for an ASE upgrade to be part of a larger project involving a change to server hardware or operating system software. We strongly recommend that you separate these migrations: DO NOT combine a hardware platform and/or OS upgrade with your ASE upgrade. Performing these tasks simultaneously will make problem identification and resolution extremely difficult. Therefore, we recommend performing any necessary upgrades or migrations of your hardware and operating system before or after you upgrade ASE. From a Sybase perspective, we would prefer to upgrade ASE after the hardware and software platforms are stable and well tuned.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 23 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

TEST ASE 15S NEW FEATURE S


Given the significant changes in ASE 15, Sybase recommends that you thoroughly test your new ASE 15 installation before moving it into production. This should include the following: 1) Review the Documentation: Become familiar with ASEs new features, configuration options and special installation instructions by reading the latest documentation. This includes the New Features Guide, Installation Guide and the System Administration Guide. Additionally, review the White Papers listed in the Recommended Reading section of this guide. 2) Evaluate and Modify: Use the information in the Sybase documentation to evaluate and modify your client/server configurations and your application code as needed. 3) Plan and Test: Develop and implement a plan to thoroughly test your applications (as noted in the checklist below). In doing so, the test environment you create should simulate your production environment and application workload as close as possible. This should include parameters such as: Server configurations: Such as physical memory, number of locks, number of user connections, traceflags, startup options, user cache, procedure cache, statement cache. Data Base and Table Sizes: Such as user db, tables and user tempdb. Security, auditing, and encryption (if used). Application workload mix. LDAP (if used). 4) Note: A good test environment will enable you to proactively tune your configuration and help ensure a smooth and successful upgrade. The closer your test environment approximates production, the better your test results will reflect production.

ASE INTEROPERABILITY AND UPGRADING TO THE LATEST VERSION OF OPENCLIENT


In order to use all of ASE 15s new features, make sure that your client software supports them. Therefore, be sure to review the client-specific documentation for information about the features your client supports. When upgrading to ASE 15.7, we recommend that you upgrade your OpenClient software to OpenClient 15.7. OpenClient 15.7 contains optimizations that improve ASE performance, as well as providing support for all of ASEs latest features.

ASE COMPATABILITY
If you are using any third-party tools or applications, you need to verify if they are certified for use with the version of ASE 15 you are upgrading to.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 24 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

UPGRADE CONSIDERTATIONS FOR ASE 15S NEW OPTIMIZER

UPGRADE CONSIDERATIONS FO R ASE 15S OPTIMIZER GOALS


THE NEW OPTIMIZER GOALS In ASE 15.0, Sybase introduced a new optimizer that included optimizer goals. Optimizer goals provide hints to the optimizer that help it produce better query plans using fewer CPU cycles and less time. The three optimization goals introduced in ASE 15 were: 1. allrows_mix: This is the default server-level goal. It is designed for mixed-query environments comprised of online transaction processing (OLTP) and Decision Support (DSS). 2. allrows_oltp: This goal is optimized for OLTP environments. 3. allrows_dss: This goal is optimized for DSS queries of medium-to-high complexity. IMPLEMENTATION CONSIDERATIONS The best way to determine the most effective optimizer goals for your server is by thorough testing. This is recommended over accepting the default goal or by choosing a goal based on its description. In some cases, no single optimizer goal is best for ALL queries. In these situations, you will need to perform additional testing to identify the best goals for particular queries or applications. For more details, see the Pre-Upgrade Planning and Post-Upgrade sections later in the document.

UPGRADE CONSIDERATIONS FOR ASE 15S OPTIMIZER LEVELS


THE NEW OPTIMIZER LEVELS To further control ASEs optimizer behavior, ASE 15.5 introduced optimizer levels. These are dynamic settings that allow you to fine-tune ASEs standard optimizer goals. However, optimizer levels are advanced tuning mechanisms that should only be considered when query performance using the standard optimizer goals does not meet your application requirements. The current optimizer levels include the following settings: o o o ase_current: Enables all optimizer changes through the current release. ase_default: Disables all optimizer changes since version 1503 ESD #1. ase1503esd2: Enables all optimizer changes through version 15.0.3 ESD #2.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 25 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


o

Sybase ASE 15

_________________________________________________________________________________________________

ase1503esd3: Enables all optimizer changes through version 15.0.3 ESD #3.

IMPLEMENTATION CONSIDERATIONS By default, ASE does not enable the optimizer level settings; you must enable them using the set command. In most situations, the cost-based query plans generated by the standard three optimizer goals will be optimal. For an additional discussion of these considerations, see the detailed Pre-Upgrade Planning and Upgrade sections later in the document. Proper use of optimizer levels requires advanced tuning techniques that are outside the scope of this guide. For more information on how to use these settings, please see the ASE 15.7 Performance and Tuning Series: Query Processing and Abstract Plan at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00743.1570/html/queryproces sing/title.htm

UPGRADE CONSIDERTATION S FOR ASE 15S NEW THREADED KERNEL


THE NEW THREADED KERNEL
ASE 15.7 introduced a new thread-based kernel that replaces ASEs process-based kernel. This new threaded kernel is designed to streamline I/O handling, reduce wasted CPU cycles and improve efficiency. It also improves load balancing for CIS and Rep Agent, provides less interference between CPU & I/O bound work, and gives more consistent and predictable performance.

IMPLEMENTATION CONSIDERATIONS
The new threaded kernel affects and/or obsoletes several pre-ASE 15.7 server settings. Therefore, implementation involves understanding and modifying these configuration settings for your environment (see below). To mitigate risk and to provide for backward compatibility, the process-based kernel has been retained and can be enabled using the new kernel mode configuration option. However, reverting to the processed-based kernel should only be considered as a last resort for resolving an issue, or if you are specifically instructed to do so by Technical Support. Otherwise, we strongly recommend using the threaded kernel. Further, the process-based kernel mode may not support all the new features of ASE 15.7 and later. For a more detailed discussion of upgrade considerations for ASEs threaded kernel, please see the Review and Understand the New ASE 15 Threaded Kernel and the Configure and Tune the New Kernel Resource Settings steps presented later in this document.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 26 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

NEW LICENSING CONSIDERTATIONS FOR ASE 15


Sybase uses a utility called SySAM (Sybase Software Assets Manager) to install, maintain and verify Sybase product licenses. In ASE 15, Sybase introduced a new version of this utility called SySAM2. This version significantly changes the way you install and upgrade ASE software.

SYSAM2 LICENSING CHANGES FOR ASE 15


SySAM2 introduces a number of changes to the way Sybase monitors and manages its software licenses. These include the following: o o o o o o o o New asset management and reporting tools. A single installation method for all Adaptive Server editions. SySAM usage is no longer optional. SySAM configuration options are provided. SySAM licenses are no longer shipped along with order fulfillment. You must obtain license certificates from the Sybase Product Download Center (SPDC). SySAM license keys include information about the support plan you purchased. You must update these licenses whenever you renew your support plan. Licensing policies are strictly and consistently enforced. ASE will function normally under grace periods if it is not able to obtain a license. This grace period is typically 30 days. ASE features and/or the server itself may shut down at the end of the grace period if the licensing issues are not resolved. You can receive real-time e-mail notifications about licensing events. Licenses issued from SPDC include information about the host machine where the licenses will be deployed. These licenses cannot be used on another machine without being reissued from SPDC.

o o

SYSAM IS NOW REQUIRED FOR ALL LICENSES


One of the biggest changes in SySAM2 is the mandatory use of SySAM to manage ALL Sybase software licenses. Previously, the use of SySAM was optional for the ASE Core licenses. SySAM was only required for optional licenses that extended ASEs core functionality. In version 15, this has changed. SySAM license registration is now required for ALL licenses. Therefore, it is important that you plan your SySAM deployment before installing ASE 15. Therefore, in order to license your ASE 15 server, you must do the following: 1. Identify the components and options to install or upgrade. 2. Choose a SySAM license model. 3. Obtain (download) a license. 4. Install/deploy the license.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 27 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


Note: o o

Sybase ASE 15

_________________________________________________________________________________________________

SySAM 2 licenses are generated at the secure Sybase Product Download Center (SPDC) Web site When you generate licenses at the Sybase Product Download Center (SPDC), you must specify the host ID of the machine where the licenses will be deployed.

For more details on how to license ASE 15, please see the Pre-Upgrade Planning and Pre-Upgrade steps (Steps 1.5 and 2.2) later in this document.

SYSAM SUB-CAPACITY LICENSING


Sub-capacity licensing refers to licensing a Sybase product on a subset of the CPUs available on a physical machine. As of ASE 15.5, Sybase offers sub-capacity licensing options for ASE Enterprise. Sub-capacity Licensing is not supported in the ASE 15.5 Cluster Edition. A sub-capacity licensing agreement with Sybase must be in-place before you can enable subcapacity licensing. As with other Sybase licenses, this license must be obtained through Sybase sales. Sub-capacity licenses are restricted to specific hardware and software platforms. For more information on sub-capacity eligible platforms, see the latest Release Bulletins. For example, for ASE 15.7 on Linux, see the Adaptive Server Enterprise 15.7 > Release Bulletin Adaptive Server Enterprise 15.7 for Linux > Installation and Upgrade > Special Licensing Instructions at
http://infocenter.sybase.com/help/topic/com.sybase.infocenter.help.ase.15.7/title.htm

For more details on using sub-capacity licensing, please see the following:
o

For information on how to configure sub-capacity license using the sysamcap utility, see the SySAM Documentation > Users Guide > SySAM Sub-capacity Licensing at
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00530.0200/doc/html/jon 1265323502828.html

For more details on sub-capacity licenses and using SySam in general, see the following:
The SySAM Users Guide at: http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00530.0200/doc/ html/title.html

The SySAM Quick Start Guide at


http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc70043.0200/ doc/html/title.html

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 28 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

KNOWN ISSUES
KNOWN UPGRADE ISSUES FOR ASE 15.7
Below, are several configuration issues that result in the sqluprade program failing when performing an in-place upgrade for 15.7. These issues are not applicable to most sites, but they are provided proactively for consideration in your pre-upgrade planning. CR #696227: o o Title: sqlupgrade fails to start ASE 15.7 due to lack of kernel resource memory. Description: An In-place upgrade to ASE 15.7 may fail because the new ASE fails to start with the error "The configured value '4096' for parameter 'kernel resource memory' is too low." This occurs when ASE is configured with a large value for both the "number of user connections" and the "number of open indexes". Workaround: Temporarily reduce the number of user connections and the number of open indexes to DEFAULT. This allows ASE 15.7 to start. There may be other configurations that will affect this.

CR# 705390: o Description: Upgrade to 15.7 fails when the number of checkpoint tasks is greater than 1. o Workaround: On the pre-upgraded ASE server, reconfigure the number of checkpoint tasks to be equal to 1 or the default, by doing one of the following: 1. Use sp_configure to set the value: sp_configure "number of checkpoint tasks", 1 2. Manually edit the configuration file and set the number of checkpoint tasks=DEFAULT. CR# 702339: o Description: LDAP login fails to authenticate after upgrade in-place to ASE 15.7. o Workaround: 1. First, reset the access accounts for the ldap server by doing the following: > sp_ldapadmin 'set_access_acct', <access account>, <password> 2. If the above does not work, then do the following: Drop all attributes, Class 17. Repeat your LDAP setup.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 29 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

The Number of OS File Descriptors: o Problem: In ASE 15.7, the resource requirements for the new threaded-kernel can be significantly greater for servers with many CPU's and many user connections. If the number of OS file descriptors (ulimit n) is too low, the sqlupgrade program may fail. For example, on a server with 44 engines and 550 user connections and a file descriptor setting of ulimit -n = 1024, the sqlupgrade program fails with the following error:
Number (5849) Severity (16) State (1) Server (XXXXX) Procedure (sp_configure) Verification failed for parameter 'number of user connections'. The number of file descriptors per ASE process required to support the configuration resulting from the value 550 of the configuration parameter \'number of user connections\'exceeds the limit 1024 by 7.

Workaround: Use the following formula to compute the maximum number of file descriptors per ASE process for the SMP edition in threaded mode: the number of user connections + number of remote sites + max cis remote connections + number of java sockets + max number of network listeners + max native threads per engine + overhead.

CR 697533: o o Title: Numerous Disk I/O errors when ASE is running in threaded mode: "sddone: write
error on virtual disk 235 block 10690289"

Description: ASE on Solaris platforms reports 694 or 823 errors along with messages like "kernel sddone: write error on virtual disk 3 block 145536", "kernel sddone: 16384 bytes passed, 0 returned on write for virt disk 3 block 145536" or "kernel sddone: read error on virtual disk 6 block 6812351", "kernel sddone: I/O error". There are no corresponding disk i/o error messages reported in the Operating System logs. Workaround: Call Sybase Technical Support. Fixed: ASE 15.7 ESD#2.

o o

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 30 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

WHERE TO LEARN ABOUT THE LATEST KNOWN ISSUES AND FIXES


To learn about all the known issues for your ASE release and where they are fixed, please see the documents listed below. 1. The Cover Letter: A Cover Letter accompanies each ESD and it contains a complete list of CRs that ARE FIXED in this release. For a list of the latest CRs fixes available to all customers, see the Cover Letter for the most recent ESD in your major release family. Cover Letters can be found under the Support>Download menu on the Sybase EBF download site at: Sybase.com website at:
http://downloads.sybase.com/swd/base.do?client=support

From within the list of all products, choose ASE. Then, choose the hardware platform and the ESD version you are interested in. For example, the Cover Letter for ASE 15.7 ESD#1 on Linux x86-64 (EBF 19805) can be found at:
http://download.sybase.com/swr/15448/EBF19805_README.html

2. The Release Bulletin: A Release Bulletin accompanies each major release of ASE such as ASE 15.7.0. This document contains important information about the GA release and it includes a list of known issues and the recommended methods for working around these issues. The Release Bulletins for all ASE platforms (along with all the online documentation for ASE) can be found at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.help.ase.15.7/title.htm

From within the list of all Release Bulletins, choose the Release Bulletin for your platform. For example, the Release Bulletin for ASE 15.7 on the Linux platform can be found at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc78565.1570/doc/html /title.html

3. The Targeted ASE 15.x Release Schedule and CR list Information: The Targeted Release Schedule provides a listing of CRs that are targeted to be fixed. This listing is visible to all customers as follows: The summary page for these listings can be found at: http://www.sybase.com/detail?id=1038641. These lists are updated on a regular basis, and these schedules are subject to change. From the listing on the summary page, choose the ASE release and ESD number you are interested in. For example, the list of CRs to be schedule to be fixed in ASE 15.7 ESD#2 can be found at: http://www.sybase.com/detail?id=1096303. 4. Customer Service: You may also call Sybase Customer Service if you have any questions about a known or suspected issue.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 31 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

WHERE TO GET THE LATEST SOFTWARE FIXES


The latest software fixes are in the latest software releases. Therefore, we recommend that you install the latest release of ASE 15 possible. That is, do the following: 1. Download and install the most recent base release (from the SPDC portal). For example, ASE 15.7. 2. Then, download and install the most recent EBF (from the Support Download portal). For example, ASE 15.7 ESD#1. A definitive list of the bug fixes provided by an ESD is contained within the EBF Cover Letter for each release. Use this information to determine where a particular CR is fixed. If you have any questions about what version to install or where a particular CR is fixed, please call Sybase Technical Support.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 32 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

PROCEDURES FOR UPGRADING FROM ASE 12.5 TO THE LATEST VERSION OF ASE

PURPOSE
The following procedures are only applicable for upgrading from ASE 12.5.x to the latest version of ASE (ASE 15.7 and above).

APPROACH
The following procedures represent a Best Practices approach to an ASE upgrade. Therefore, they include procedures for testing and tuning your upgraded software before moving into production.

OVERVIEW OF PROCEDURES
The procedures for upgrading from ASE 12.5 to ASE 15 consist of the following two sections: 1. The Upgrade Checklist: The upgrade checklist contains a list of significant steps that you can check-off as you proceed with the upgrade process. It also serves as a ready reference as you move from one phase of your upgrade to another. Your site may have additional or more detailed upgrade requirements. Please feel free to modify this checklist to meet needs. However, we strongly recommend thoroughly testing your upgrade before moving into production. 2. Detailed Upgrade Procedures: The detailed upgrade procedures section contains a detailed explanation of the procedures to be performed within each step listed in the checklist.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 33 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

UPGRADE CHECKLIST FOR UPGRADING FROM ASE 12.5 TO THE LATEST VESION OF ASE
PLEASE NOTE: The following Checklist is only applicable to upgrades from ASE 12.5.x to ASE 15.x.

STEP 1: PRE-UPGRADE PLANNING PROCEDURES


The following steps are required to develop a plan for your upgrade:

[ [ [ [ [ [ [ [ [ [ [ [ [ [ [ [ [ [

] Step 1.1: Review the ASE Documentation. ] Step 1.2: Identify New Features of Interest. ] Step 1.3: Determine the Upgrade Version: The Latest Release is Recommended. ] Step 1.4: Determine the Upgrade Method. ] Step 1.5: Understand the New License Requirements. ] Step 1.6: Understand the Increased Resource Requirements. ] Step 1.7: Consider the Semantic Partitioning Option. ] Step 1.8: Determine the ASE Database Device Attributes. ] Step 1.9: Review and Understand the New Optimization Goals. ] Step 1.10: Review and Understand the New Optimizer Level Settings. ] Step 1.11: Review and Understand the New ASE Threaded Kernel Settings. ] Step 1.12: Review Any Trace Flags Used at Startup. ] Step 1.13: Evaluate Client Interoperability and Third Party Compatibility. ] Step 1.14: Evaluate Application Interfaces and Replication. ] Step 1.15: Evaluate Disaster Recovery Procedures. ] Step 1.16: Evaluate the Latest Known Issues. ] Step 1.17: Create a Project Plan. ] Step 1.18: Create a Tactical Plan.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 34 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x [ ] Step 1.19: Create a Test Plan.

Sybase ASE 15

_________________________________________________________________________________________________

STEP 2: PRE-UPGRADE STEPS


The following steps should be performed in preparation for the actual upgrade:

[ [ [ [ [ [ [ [ [ [ [ [ [ [ [

] Step 2.1: ] Step 2.2: ] Step 2.3: ] Step 2.4:

Build a Test System. Identify, Download and Install the New ASE Licenses. Create a Pre-Upgrade Performance Base Line. Generate and Save Abstract Plans.

] Step 2.5: Verify the Free Space in All Databases. ] Step 2.6: ] Step 2.7: ] Step 2.8: ] Step 2.9: Verify the Number of Locks Configured for the Upgrade. Consider Replacing the Update Statistics Command. Perform the Pre-Upgrade Steps in the Install Guide (as needed). Perform the Pre-Installation Tasks (Clean-Install Only).

] Step 2.10: Perform the Pre-Upgrade Tasks in the Cover Letter (as needed). ] Step 2.11: Implement Your ASE Database Device Attributes. ] Step 2.12: Check the Data Consistency of the Master and User Databases. ] Step 2.13: Backup All User Databases. ] Step 2.14: Backup the Master Database. ] Step 2.15: Dump the Transaction Log.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 35 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 3: UPGRADE STEPS FOR THE TEST ENVIRONMENT


The following steps will be performed as part of the actual upgrade:

[ [ [ [
[ [ [ [

] Step 3.1: Bulk Copy Out (BCP) the Key System Tables. ] Step 3.2: Disable Replication (as needed). ] Step 3.3: Unpartition All Partitioned Tables. ] Step 3.4: Quiesce and Dump All Databases.
] Step 3.5: Perform the ASE Upgrade (Using Your Method of Choice). ] Step 3.6: Upgrade Client Software (as needed). ] Step 3.7: Upgrade Middleware, Interfaces and 3 -Party Software (as needed). ] Step 3.8: Upgrade Other Software (as needed).
rd

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 36 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 4: POST-UPGRADE STEPS FOR THE TEST ENVIRONMENT


The following steps should be performed following the upgrade into your test environment:

[ [ [ [ [ [

] Step 4.1: Perform the Post-Upgrade Steps. ] Step 4.2: Recreate Table Partitions. ] Step 4.3: Replace the Update Statistics Command. ] Step 4.4: Delete or Update Stale Statistics. ] Step 4.5: Recreate Optimizer Statistics. ] Step 4.6: Configure and Tune the New Resource Requirements: [ [ [ [ ] Step 4.6.1: Configure Procedure Cache. ] Step 4.6.2: Re-Size Tempdb. ] Step 4.6.3: Semantic Partitioning and the Number of Open Partitions. ] Step 4.6.4: Statement Cache and Literal Auto-Parameterization.

[ [ [

] Step 4.7: Configure and Tune the New Kernel Resources. ] Step 4.8: Create and Maintain a Post-Upgrade Baseline. ] Step 4.9: Test and Tune the New ASE 15 Optimizer Settings: [ ] Step 4.9.1: Test and Tune the New Optimizer Goals. [ ] Step 4.9.2: Advanced Tuning: Optimizer Levels. [ ] Step 4.9.3: Advanced Tuning: The QPTune Tool. [ ] Step 4.9.4: Advanced Tuning: Query Processing, Abstract Plans & More. [ ] Step 4.9.5: The Optimizer Compatibility Mode (The Last Resort).

[ ] Step 4.10: Test Other New Features (as needed). [ ] Step 4.11: Verify Application Consistency and Stability. [ ] Step 4.12: Verify Backup and Recovery Procedures. [ ] Step 4.13: Standardize the Upgrade Procedures for Production.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 37 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 5: UPGRADE STEPS FOR THE PRODUCTION ENVIRONMENT


Once you have completed the post-upgrade steps for the test phase of your upgrade, you are ready for the production upgrade and post-upgrade steps. The production steps consist of repeating the upgrade procedures used in test, PLUS implementing the post-upgrade configuration settings determined in your previous testing phase. In addition, if your production and test environments are different, any OS, hardware, physical memory, or ASE database device changes you made for test may need to be repeated for production.

[ [ [ [
[ [ [ [

] Step 5.1: Bulk Copy Out (BCP) the Key System Tables. ] Step 5.2: Disable Replication (as needed). ] Step 5.3: Unpartition All Partitioned Tables. ] Step 5.4: Quiesce and Dump All Databases.
] Step 5.5: Perform the ASE Upgrade (Using Your Method of Choice). ] Step 5.6: Upgrade Client Software (as needed). ] Step 5.7: Upgrade Middleware, Interfaces and 3 -Party Software (as needed). ] Step 5.8: Upgrade Other Software (as needed).
rd

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 38 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 6: POST-UPGRADE STEPS FOR THE PRODUCTION ENVIRONMENT


The post-production steps for production consist of repeating the post-upgrade steps in test, with the addition of using the configuration settings determined in your previous testing phase.

[ [ [ [ [

] Step 6.1: Perform the Post-Upgrade Steps. ] Step 6.2: Recreate Table Partitions. ] Step 6.3: Replace the Update Statistics Command. ] Step 6.4: Recreate Optimizer Statistics. ] Step 6.5: Configure the New Resource Requirements: [ [ [ [ ] Step 6.5.1: Configure Procedure Cache. ] Step 6.5.2: Re-Size Tempdb. ] Step 6.5.3: Semantic Partitioning and the Number of Open Partitions. ] Step 6.5.4: Statement Cache and Literal Auto-Parameterization.

[ [

] Step 6.6: Configure the New Kernel Resources. ] Step 6.7: Configure the New ASE 15 Optimizer Settings: [ [ [ ] Step 6.7.1: Implement the New Optimization Goals. ] Step 6.7.2: Implement the New Optimizer-Level Settings (as needed). ] Step 6.7.3: Implement other Advanced Tuning Settings (as needed). Perform Client, Middleware, or Application Upgrades (as needed).

[ [ [

] Step 6.8: ] ]

Step 6.9: Verify Database Consistency. Step 6.10: Backup the Upgraded User and Master Databases.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 39 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

DETAILED PROCEDURES FOR UPGRADING FROM ASE 12.5.X TO THE LATEST VERSION OF ASE
PLEASE NOTE: The following detailed procedures are only applicable for upgrading from ASE 12.5.x to ASE 15.7 and above

STEP 1: PRE-UPGRADE PLANNING PROCEDURES

STEP 1.1: REVIEW THE ASE DOCUMENTATION

1.1.1: RECOMMENDED READING Please review the documents listed in the Recommended Reading section of this guide. In particular, it is important to read the ASE Installation Guide, Release Bulletin and Cover Letter for your version and platform. These documents contain the most recent and important installation instructions and considerations.

1.1.2: RELEASE BULLETIN The Release Bulletin contains important information about the software you are installing. This includes the following topics:
o o o o o o o o o o o o o o o o o o Product Summary Interoperability Product Compatibility Changes that Affect Existing Applications Backup Server Open Client and Open Server Changed Functionality Special Installation Instructions Special Licensing Instructions SySAM Licensing Checkout Sub-capacity licensing Special Configuration Instructions Special Upgrade and Downgrade Instructions Loading Database Dumps During Downgrade Known Installation Issues for Adaptive Server Documentation Updates Downloading Sybase EBFs and Maintenance Reports Sybase Product and Component Certifications

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 40 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

1.1.3: COVER LETTER The EBF Cover Letter contains important information about the software patch you are about to install, such as: o Technical Notes o Platform Specific Details o Backup o New features o Changes o Known Issues o Loading Instructions o Post installation tasks o New Fixes in the EBF 1.1.4: NEW FEATURES GUIDE ASE 15 introduces many new features; therefore, it is important to review this guide in order to have a high-level understanding of what these features are and how they might affect your applications.

STEP 1.2: IDENTIFY NEW FEATURES OF INTEREST


Once you have reviewed the New Features Guide, you may want to consider implementing one or more new features. If you choose to implement any of these new features, be sure to include them in your test plan.

STEP 1.3: DETERMINE YOUR UPGRADE VERSION: CONSIDER THE LATEST RELEASE
ASE is continually being enhanced. New features, improved performance, improved diagnostics and the latest bug fixes are introduced in every major and intermediate release. For example, the MDA tables (installed by default in 15.0.2) are now vital tools for identifying and analyzing poorly running queries. Further, new bug fixes are applied to the most recent versions first and are not automatically backported to earlier releases. Therefore, it is important to consider upgrading to the most recent release of ASE. By this, we mean the most recent full release, plus the most recent ESD, for example, ASE 15.7 ESD#1. We strongly recommend doing so unless you have a specific business requirement or have been instructed by Sybase to do otherwise. To find a chart of the latest releases, see the Targeted Release Schedule at: http://www.sybase.com/detail?id=1038641 .

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 41 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

To find an overview of the latest ASE release, see the ASE product page at: http://www.sybase.com/products/databasemanagement/adaptiveserverenterprise To find and download the latest full releases of ASE, go to Sybase SPDC site at https://sybase.subscribenet.com. From this portal, click on the Adaptive Server Enterprise link, then select the ASE Enterprise Edition link, and then select the latest version for your platform. For example, ASE Enterprise Edition 15.7 Linux x86-64 64-bit. To find the most recent patches (ESDs) for ASE, go to the Sybase.com Support>Download menu at: http://downloads.sybase.com/swd/base.do?client=support. From this portal, click on the Adaptive Server Enterprise link, then navigate to your platform and then click on the EBF number for the ESD of your choice. For example, for ASE 15.7 ESD#1 Linux on POWER, you would select EBF 19810: 15.7 ESD #1 - 64 Bit To learn about the latest features in the latest releases, go to the ASE Product Documentation portal (at http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter) and then navigate to the latest versions.

STEP 1.4: DETERMINE YOUR UPGRADE METHOD


In ASE 15, there are four basic methods of upgrading. Three methods were available in ASE 12.0, and a fourth method was introduced in ASE 12.5 and above: 1. In-Place Upgrade: Also referred to as a Binary Overlay. 2. Clean Install: Also referred to as Dump and Load. 3. BCP (BCP-In/BCP-Out): This refers to bulk copying ASE data out of the tables on the old server and bulk copying the data into the tables on the new server using ASEs BCP utility. Note: The database upgrade occurs during the online phase of the data load. 4. Mount and Unmount (Quiesce, Copy and Move): With the introduction of the mount/unmount feature added in ASE 12.5, there is now a fourth method that may be considerably faster than dump/load for customers that use SAN disk technology. The steps required for this method are: 1. Quiesce the database using a manifest file. 2. Copy/move the devices along with the manifest file to the ASE 15 host. 3. Mount the database using the mount database command. 4. Bring the database online via the online <database_name> command. It is during the online database step that the database upgrade will be performed. Note: This method is only supported between machines from the same hardware and OS platform. Cross platform migrations are not supported.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 42 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

If you are not combining your upgrade with various schema changes that require a bcp-in/bcp-out approach, then Sybase Support recommends that you use either the Clean Install (dump and load) method or the mount and unmount method of upgrading ASE.

STEP 1.5: UNDERSTAND THE NEW LICENSING REQUIREMENTS FOR ASE 15


Since ASE 15 now uses the SYSAM 2.0 license management system for all ASE features, you will want to familiarize yourself with the new procedures for licensing ASE 15. These procedures consist of the following steps: o o o o Identifying the components and options to install or upgrade. Choosing a SySAM license model. Obtaining a license from the Sybase SPDC portal. Installing the license.

You will need to know your host-id, Product Edition, and License type for all of your ASE licenses. For more details on these licensing procedures, see Step 2.2 in the Upgrade Planning section below. For an introduction to the latest licensing procedures, see the following Sybase documents: o For SySAM pre-installation planning and SySAM installation information, see the SySAM Users Guide at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00530.0200/doc/html /title.html

For an a summary of SySAM usage, see the SySAM Quick Start Guide at
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc70043.0200/doc/html /title.html

STEP 1.6: UNDERSTAND THE INCREASED RESOURCE REQUIREMENTS FOR ASE 15


This step provides you advanced notice if your ASE 15.x upgrade requires additional resources. Your current hardware platform may need to be reconfigured to support the additional requirements of ASE 15. See the Post-Upgrade Steps for the Test Environment below (steps 4.6-4.7) for more details.

STEP 1.7: CONSIDER USING THE SEMANTIC PARTITIONING OPTION


1.7.1: PARITIONING ASE 15.0 introduced horizontal partitioning, horizontal partitioning, in which a selection of table rows can be distributed among partitions on different disk devices. Individual table or index rows are assigned to a partition according to a semantic or to a round-robin partitioning strategy.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 43 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

Partitioning allows you to divide large data sets into smaller, manageable chunks, known as partitions. Data in each partition can be processed independently of other partitions. DBA tasks such as update statistics, index creation, truncate, reorg, dbcc's, bcp, etc., can be broken down into smaller sub-tasks. This represents a divide-and-conquer strategy to manage large and increasing volumes of data. ASE 15.7 provides one random type of partitioning (round-robin), plus three types of semantic partitioning (hash, list and range). 1.7.2: SEMANTIC PARITIONING Semantic partitioning is an optional license that must be purchased. For a complete listing of ASE 15.7 standard and optional features, see the following documents: o o ASE 15.7 Features: http://www.sybase.com/files/Data_Sheets/Sybase_ASE_15.7_Features_DS.pdf ASE Options: http://www.sybase.com/files/Data_Sheets/Syb_ASE_Editions_US_DS_Feb2012_WEB.pdf

Unlike the round-robin partitioning strategy (which assigns rows randomly without reference to data values), semantic partitioning allows you to control the placement of data into partitions. It uses the data values in a specific column to determine the partition assignment for each row. 1.7.3: ASE 15.7 PARTITIONING STRATEGIES ASEs partitioning strategies are as follows: 1. Hash partitioning (semantic): A system-supplied hash function determines the partition assignment for each row. 2. List partitioning (semantic): Values in key columns are compared with sets of user-supplied values specific to each partition. Exact matches determine the partition assignment. 3. Range partitioning (semantic): Values in key columns are compared with a user-supplied set of upper and lower bounds associated with each partition. Key column values falling within the stated bounds determine the partition assignment. 4. Round-robin partitioning: This is the default strategy: Rows are assigned randomly to partitions in a round-robin manner so that each partition contains an approximately equal number of rows. Configuration Notes: o You can create partitions when you create a table or index using the CREATE TABLE and CREATE INDEX. o o o You can use the ALTER TABLE add partition command to add a partition to certain existing tables (list or range, but not hash or round-robin). You can use the ALTER TABLE command to change the partitioning strategy of an existing table. For more details, see the Partitioning Tables and Indexes chapter in the ASE 15.7 T-SQL Guide at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc32300.1570/html/sqlug/B HAHDJBA.htm

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 44 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


STEP 1.8: DETERMINE YOUR ASE DATABASE DEVICE ATTRIBUTES
Dsync:

Sybase ASE 15

_________________________________________________________________________________________________

Prior to ASE 15.0, Sybase recommended that the dsync setting be turned on for devices initialized on UNIX operating system files. The dsync flag ensures that writes to the device file occur directly on the physical storage media. Each write will wait for both the file data and file status to be physically updated, so that ASE can recover data on the device in the event of a system failure. However, this functionality yields much slower performance during write operations, when compared to using raw partitions. Directio: o In ASE 15, the directio parameter allows you to configure ASE to transfer data directly to disk, bypassing the operating system buffer cache. File system devices with directio perform IO in the same manner, and provide the same performance benefits, as raw devices. The directio option is a feature of the file system whereby writes go directly to the storage device. Direct I/O is invoked by opening a file with the O_DIRECT flag. The direct I/O parameter is used with disk init, disk reinit, and sp_deviceattr commands.

Advantages of direction over dsync: o No double buffering. o o Improved performance for write and cold reads since the overhead of the FS cache is eliminated. Gives performance on par with raw with the manageability of a file system (significantly better than dsync).

Recommendations: o In summary, using the directio option is recommended whenever file system devices are used. o Note: The directio and dsync parameters are mutually exclusive. If a device has dsync set to true, you cannot set directio to true for this device. To enable directio for a device, you must first reset dsync to false.

STEP 1.9: REVIEW AND UNDERSTAND THE NEW OPTIMIZER GOALS


First, it is critical that you familiarize yourself with each of the ASE 15 optimizer goals. To do so, see the following documents: o Adaptive Server Enterprise 15.7 > Performance and Tuning Series: Query Processing and Abstract Plans > Controlling Optimization > Optimization goals at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00743.1570/html/que ryprocessing/queryprocessing186.htm

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 45 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


o

Sybase ASE 15

_________________________________________________________________________________________________

Adaptive Server Enterprise 15.0 > Performance and Tuning: Query Processing and Abstract Plans > Controlling Optimization > Optimization Goals at
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.dc00743_1500/html/qp_abstrpln/q p_abstrpln154.htm

The Migration Technology Guide:


http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00967.1550/html/Mig rationGuide/title.htm

Changes to Scope & Semantics of Session-Level Optimization Settings in ASE 15:


http://www.sybase.com/files/White_Papers/ASE1502_OptimizationCriteria_v1_0.pdf

Upgrading to ASE 15 - An in-depth view of the (un)expected:


http://www.sybase.com/detail?id=1061943&contentOnly=true

Second, plan to assess the affects of each optimizer goal on your queries by comparing your preASE 15 baseline with your post-upgrade performance tests. Testing each goal is strongly recommended over accepting the default server-level setting (allrows_mixed), or choosing a goal based on its description. In planning your testing, keep the following in mind: o o o In general, it is best to first test the performance of your queries using the default goal of allrows_mixed. Next, test each of the other goals. If no single optimizer goal is best for ALL queries, identify the goal that provides the best performance for the most queries. Use this for your server-level setting. Then, set the optimizer goal at the session level or query level as needed to meet the performance requirements of other queries.

For more details on testing strategies, see the Post-Upgrade section of this guide.

STEP 1.10: REVIEW AND UNDERSTAND THE NEW OPTIMIZER LEVEL SETTINGS
ASE 15.5 introduced optimizer levels. These dynamic settings allow you to specify the level of optimization the ASE optimizer uses. In most situations, the cost-based query plans generated by the standard optimizer goals will be optimal. Therefore, optimizer levels should only be considered when query performance using the standard optimizer goals is unsatisfactory. Optimizer levels are dynamic (do not require a reboot) and allow you to override the decisions made by the Adaptive Server query processor. Therefore, use these techniques with caution, since misuse can have an extremely negative effect on performance. When using these settings, you should understand the impact on the performance of both your individual query and the possible implications for overall system performance.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 46 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

Using optimizer levels involve advanced tuning techniques that are outside the scope of this document. For more details on the techniques for using optimizer levels, see "Chapter 7, Controlling Optimization, in the Performance and Tuning Series: Query Processing and Abstract Plans at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00743.1570/html/queryprocessi ng/X29769.htm

A summary of optimizer levels is also provided in the Post-Upgrade section of this document.

STEP 1.11: REVIEW AND UNDERSTAND THE NEW ASE THREADED KERNEL
1.11.1: OVERVIEW OF THE NEW THREADED KERNEL ASE 15.7 introduced a new thread-based kernel that replaces ASEs process-based kernel. This new threaded kernel is designed to streamline I/O handling, reduce wasted CPU cycles and improve efficiency. To mitigate risk and to provide for backward compatibility, the process-based kernel has been retained and can be enabled using the sp_configure kernel mode command. However, the process mode should only be used if you encounter a threaded-mode issue, or if you are specifically instructed to do so by Sybase Technical Support. Further, the process-based kernel may not support all the features of Adaptive Server 15.7 and later. The kernel mode setting determines which kernel ASE uses: o Threaded mode: This is the default kernel-mode. In threaded kernel mode, Adaptive Server is a single process running on the operating system; and it uses operating system threads to support its engines and specialized tasks. Note: Adaptive Server supports only threaded kernel mode on the Windows platform.

The Process mode: The process mode is the same kernel used by Adaptive Server versions earlier than 15.7. In the process mode, each engine is a distinct process running on the operating system; and Adaptive Server uses individual processes to support its engines. Note: The process mode may not support all the features for Adaptive Server 15.7 and later.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 47 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

1.11.2: GENERAL CONSIDERATIONS The new threaded kernel affects previous server settings and requires that a number of parameters be considered with its use. Therefore, when upgrading from the processed-based kernel to the threaded kernel, consider the following: o o All execution classes lose their engine groups and are associated with syb_default_pool. The administrator may then associate the execution classes with engine thread pools. Engine groups are obsolete when running in threaded mode. In this mode, use sp_addexeclass to bind execution classes to user thread pools. Thread pools separate processor resources between applications within Adaptive Server. The value of sp_configure max online engines must be greater than the current number of engines online. Because online is a reserved keyword, you must use quotes. Note: Onlining engines (using sp_engine online) in the threaded mode increases the thread count for syb_default_pool by 1.

o o

If switching from the default of threaded mode to process mode, consider the following: o o Adaptive Server ignores thread pool information in the configuration file when it starts. Execution classes lose their thread pool association and are associated with the existing ANYENGINE engine group. The administrator may then associate the execution classes with engine groups. The reassignment of an execution class to a thread pool (or engine group) applies to existing connections associated with that execution class in addition to new logins. The process mode may not support all the features for Adaptive Server 15.7 and later.

1.11.3: THREADED KERNEL CONFIGURATION CHANGES When using the threaded kernel, the following configuration parameters will need to be changed: o o o o o The number of OS file descriptors. The ASE kernel resource memory parameter. The ASE idle timeout parameter. The ASE max online engines parameter. For in-place upgrades the number of user connections and number of open indexes may need to be temporarily reduced (per CR #696227 listed above).

For more on these configuration settings, see the Configure and Tune the New Kernel Resource Settings step in the Post-Upgrade section below.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 48 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


STEP 1.12: REVIEW ANY TRACE FLAGS USED AT STARTUP

Sybase ASE 15

_________________________________________________________________________________________________

ASE 15 has changed the way many trace flags are used. Some have been removed, while others are now controlled using the sp_configure, sp_dboption or other mechanisms. Therefore, the trace flags you are using (in your run server file, at startup, or during run-time) may need to be changed. To determine any necessary changes, you must first identify which traceflags (if any) you are using, and then research the status of these traceflags:
1. To determine the trace flags you are using, do the following: a. Review your run server file(s) and make a note of the trace flags in these files. Trace flags are preceded by the T flag. b. Run the following commands on your production ASE prior to upgrading. This command will list all the traceflags enabled for your server and session: 1> dbcc traceon(3604) 2> go 1> dbcc traceflags 2> go 2. Once you have a compiled a complete list of the traceflags used in your environment, refer to the ASE 15.x documentation for more information, or check with Sybase Technical Support on how to move forward with these traceflags. Note, some traceflags are not publicly documented and are typically used at the request of Sybase Technical Support or Engineering to resolve specific issues. If you know (or discover) that you are using such traceflags, please call Sybase Technical Support for more information.

STEP 1.13: EVALUATE CLIENT INTEROPERABILITY AND THIRD PARTY COMPATIBILITY


Evaluate the compatibility and interoperability of any client, middleware, third-party tools or thirdparty applications you are using. This would include products such as Sybase OpenClient, OpenServer, ODBC, JDBC, DBA Utilities (SQL Backtrack, BMC), etc.

STEP 1.14: EVALUATE APPLICATION INTERFACES AND REPLICATION


Identify and evaluate any batch interfaces you are using to move data into or out of ASE. Identify and evaluate any replication you are using, such as Sybase Replication Server.

STEP 1.15: EVALUATE YOUR DISASTER RECOVERY PROCEDURES


If you have disaster recovery procedures, you may want to plan to test these before moving into production.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 49 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 1.16: EVALUATE THE LATEST KNOWN ISSUES


For any release of ASE, there is a possibility of known issues. To determine if there are any known issues that might affect your upgrade or your applications, consider the following: 1. Review the Known Issues section of the Release Bulletin for your version of ASE:
o http://downloads.sybase.com/swd/base.do?client=support

2. Review the Known Issues section of the Cover Letter for your version of ASE:
o http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.help.ase.15.7/title.htm

3. Review the Targeted Release Schedule: http://www.sybase.com/detail?id=1038641. 4. Review the Known Upgrade Issues for 15.7 in the introduction section of this document. 5. Contact Sybase Technical Support.

STEP 1.17: CREATE AN OVERALL PROJECT PLAN


1.17.1: PURPOSE While the Test and Tactical plans discussed below address the specific steps of testing and implementing your upgrade, an overall project plan allows you to build a plan that outlines the steps, dates, owner and responsibilities assigned for each step within all the phases of your upgrade: Pre-Upgrade, Test Upgrade, Post-Upgrade for Test, Production Upgrade, and Post-Upgrade for Production. 1.17.2: CONSIDERATIONS Determine your upgrade version and specific upgrade method as described in the Pre-Upgrade Planning section above. Determine the new license requirements for your version of ASE per the Pre-Planning steps above. Evaluate all aspects of the environment that might be affected by the upgrade. For example: o Evaluate the compatibility or certification of 3rd party products. You may need certification or upgrades to the client interfaces like OCS, ODBC, jdbc, etc. Evaluate interfaces with upstream/downstream applications to determine impact. Review versions and feature compatibility. The interfaces may need to be upgraded as well.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 50 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


o Evaluate data/batch needs for all the interfaces: o o

Sybase ASE 15

_________________________________________________________________________________________________

Downtime required for migration/upgrade and post upgrade checks/tests. Changes to system functions/commands affecting the upstream / downstream applications. Pay close attention to data-type conversion and format issues. CIS, JAVA, XML, Replication, Parallelism, DTM/ASTC/rpc etc. Review default settings and document any extra/special steps required to ensure that the functionality and data are not impacted. Include dump and load times required to restore the system to pre-upgrade state. Set clear GO-no-GO decision timeframes.

Evaluate specific ASE features in use for special needs:

Evaluate Rollback strategies:

Evaluate ASEs new features. Include time to create a tactical plan. Include time to create a test plan. Include time to build a test environment.

STEP 1.18: CREATE A TACTICAL PLAN


1.18.1: PURPOSE The Tactical Plan outlines the specific steps you must take in order to perform the actual upgrade. 1.18.2: CONSIDERATIONS Consider the following when developing your tactical plan: Include any inter-step dependencies and recovery plans in case something goes wrong. Specify your rollback strategies: o Include dump and load times required to restore the system to pre-upgrade state. o Set clear GO-no-GO decision timeframes. Include dump and load times required to restore the system to the pre-upgrade state. Set clear GO-no-GO decision timeframes.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 51 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


STEP 1.19: CREATE A TEST PLAN
1.19.1: GOALS

Sybase ASE 15

_________________________________________________________________________________________________

While the Tactical plan covers the steps to follow on upgrade day, the test plan must cover the functional and performance testing of your application environment. It should also define success or failure criteria for each critical module. Continued testing should follow until all criteria are met. Knowing how and what to test will avoid serious unexpected problems in production. This testing phase is critical to the success of your upgrade, since ASE 15s new features will affect your current settings and query performance. As part of a best practices approach, you need to build a robust test environment in order to run, verify, and tune your server configuration, your query performance, your query results and your upgrade procedures. Further, this test environment should simulate your production environment and application workload as close as possible in order to achieve the best results. See Step 2.1 below for more details. 1.19.2: CONSIDERATIONS Evaluate the type of testing strategy you want to use, and then select an appropriate method for testing your application. Several different strategies are documented in Chapter 6 Ensuring Stability and Performance --- Summary of testing techniques, at the following link:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.dc34982_1500/html/mig_gde/X21853.htm

Identify the functional areas of your application that are critical to your business and to the success of the upgrade. These could include the following: o o Periodic batches (nightly, weekly, monthly, etc). Functional modules including, but not limited to: Online functionality Upstream/downstream interfaces, data feeds, etc.

Determine the success criteria for each module to determine acceptable variances in performance or resource utilization after the upgrade/migration. Develop Single User functionality tests for all (or at least the most critical) modules. The plan must include at least one end-to-end test of all the critical modules identified. Develop application Stress Tests that simulate peak workloads wherever possible. Develop a plan to test the new configurations and features described in the Pre-Upgrade Planning section of this document. Identify the optimal settings for your applications when using these features. Develop a plan to build a test environment that simulates your production. This will ensure the validity of your testing and the usefulness of any tuning or configuration changes you make as a result of your testing. Plan for a second test cycle using any later ESDs released by Sybase subsequently to the start of your testing. These may include fixes for issues encountered during testing saving valuable time later.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 52 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 2: PRE-UPGRADE PROCEDURES


STEP 2.1: BUILD A TEST ENVIRONMENT TO PERFORM POST-UPGRADE TESTING
The best way to avoid unpleasant surprises in production is to test and tune your upgraded server in test. This requires a test environment that closely simulates your production environment and application workload. The closer your test system resembles your production system, the more valid and useful your test results will be. The parameters for your test environment should include: o o o o o o Server Configuration: Physical memory, number of locks, number of user connections, traceflags, startup options, user cache, procedure cache, statement cache. Database and Table Sizes: User databases, user tables, system tables and tempdb. Security: Accounts, auditing, encryption, and LDAP. Workload: At the least, test your most critical and/or most frequently executed queries. Perform tests that simulate critical peak and batch workloads. Interfaces: Verify the performance of any data feeds into and out of your server. Backups: Consider verifying backup and restore procedures and throughput.

STEP 2.2: IDENTIFY, OBTAIN AND DEPLOY YOUR NEW ASE 15 LICENSES
2.2.1: OVERVIEW The SySAM licensing procedures for ASE consist of the following steps: 1. 2. 3. 4. Identifying the components and options to install or upgrade. Choosing a SySAM license model. Obtaining a license from the Sybase SPDC portal. Installing the license.

2.2.2: IDENIFYING YOUR ASE LICENSES You need one ASE Core license, and an additional license for each optional feature you are using. Review your current ASE server to identify your current license usage and type. You may also want to choose additional licenses based on your review of ASEs newest optional features. For a complete listing of ASE 15.7 standard and optional features, see the following documents: o ASE 15.7 Features: http://www.sybase.com/files/Data_Sheets/Sybase_ASE_15.7_Features_DS.pdf o ASE Options: http://www.sybase.com/files/Data_Sheets/Syb_ASE_Editions_US_DS_Feb2012_WEB.pdf

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 53 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


2.2.3: CHOOSING A LICENSE MODEL

Sybase ASE 15

_________________________________________________________________________________________________

When installing SySAM, you have a choice of two license management models, server and unserved: o o o Unserved: With this license model, the ASE license for each server is stored locally within the $SYBASE directory. Served: With this license model, the ASE licenses for multiple servers are stored in a centralized location on the network. Each of these models has their own advantages and disadvantages. The served model simplifies license management by providing a centralized repository for all licenses. However, it requires installation of additional software and is a potential point of failure unless additional configurations are employed as described in the SySAM Users Guide. For more details, see the SySAM Users Guide: Determining Your License Deployment Model at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00530.0200/doc/html /san1263843576833.html

2.2.4: DOWNLOADING YOUR ASE CORE LICENSE Where to get your license: Licenses are generated and downloaded from the Sybase Product Download Center (SPDC) at https://sybase.subscribenet.com/. For more details on generating licenses, see the SySAM Users Guide, Generating Licenses at SPDC at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00530.0200/doc/html/jon1271803 489638.html .

Some things you will need to know: o Know your host-id: Licenses are generated specific to a Host Machine. Therefore, when you generate licenses at the Sybase Product Download Center (SPDC) website, you must specify the host ID of the machine where the licenses will be deployed: The SPDC portal will provide instructions for obtaining your host-id. This procedure varies for each platform. Note: Licenses cannot be directly swapped between machines. If you are moving this license to a new host, you will have to check the license back in at the SPDC website and regenerate it for the new host if moving.

Know the Product Edition (PE) you will need: The licenses generated for ASE software are Product Edition Specific. Be sure you know what product edition you are using before downloading and installing your ASE software. Know which License Type you will need: The licenses generated for your product are also Type Specific. Be sure that you know your license type (LT) prior to installing the software.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 54 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

Summary of download steps: NOTE: If you have any questions or problems with these procedures, pleases call Sybase Technical Support. o o Go to Sybase SPDC site at https://sybase.subscribenet.com and login in using the Sybase account and password for your site. This is the site where you download your ASE software. From this portal, navigate to the platform version of ASE you want to install: Click on the Adaptive Server Enterprise link; Click the ASE Enterprise Edition link; and Select the latest version for your platform. For example, ASE Enterprise Edition 15.7 Linux x86-64 64-bit. Note: If you do not see your product on this site, contact your Sales Representative to have your profile updated to list all your licensed products. Accept the license. Click on the License Key tab. Select site license type. Select server or unserved. Follow the instructions.

For more details on generating a license key, see the following: o The SySAM Quick Start Guide at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc70043.0200/doc/html/titl e.html

The SySAM Users Guide at:


http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00530.0200/doc/html/titl e.html.

If you have any questions about this procedure, please call Sybase Technical Support. For additional troubleshooting information, see the Troubleshooting chapter in the ASE 15.7 Installation Guide for your platform. For example, see Adaptive Server Enterprise 15.7 > Installation Guide Adaptive Server Enterprise 15.7 for Linux > at
http://infocenter.sybase.com/help/topic/com.sybase.infocenter.help.ase.15.7/title.htm

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 55 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

2.2.5: DOWNLOAD YOUR OPTIONAL ASE LICENSES If you are using optionally licensed features, you will also need to download and deploy the ASE 15 version of these license files as well. The procedures for downloading optional licenses are similar to those above. Please note: o o When upgrading from ASE 12 to ASE 15, you may need to Check-in your old license and then Check-out your new ASE 15 license. If this is an intermediate or minor upgrade (upgrading from ASE 15.0 to ASE 15.7), you will have the option of upgrading your ASE license.

For more information, see the SySAM documents listed above, or call Sybase Technical Support.

2.2.6: DEPLOY YOUR NEW SYSAM2 LICENSING FILES To deploy your licenses, you need to know the information below. SySAM uses the information stored in two special license files: 1) The *.lic file: You generate this license file from the SPDC (Sybase Product Download Center) Web Site. You must generate and download a *.lic file whenever you download ASE installation or upgrade software. If you are using the unserved model, the .lic file should be placed in the local $SYBASE/SYSAM-2_0/licenses/ directory for your server. If you are using the served model, the .lic file will be placed in the $SYBASE/SYSAM-2_0/licenses/ directory on the license server host.

2) The <nameofASE>.properties file: This is the new license property file created when you install a new ASE 15 server. It is located in the $SYBASE/ASE-15_0/sysam/ directory. This file is updated every time the server boots with any knew updates or new licenses that are added to the $SYBASE/SYSAM-2_0/licenses/ directory.

2.2.7: SYSAM LICENSING DOCUMENTATION For more details on regenerating, renewing and rehosting SySAM licenses, see: Regenerating, Renewing, and Rehosting Licenses in the SySAM Users Guide:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00530.0200/doc/html/san12 63843596255.html

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 56 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

For more details on the use of SySAM, please see the following product Guides: o For information on Generating Licenses at SPDC (in the SySAM Users Guide), see:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00530.0200/doc/html/jon 1271803489638.html

For SySAM pre-installation planning and SySAM installation information, see the SySAM Users Guide at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00530.0200/doc/html/titl e.html

For Troubleshooting, see the Troubleshooting chapter in the ASE 15.7 Installation Guide for your platform. For example, see Adaptive Server Enterprise 15.7 > Installation Guide Adaptive Server Enterprise 15.7 for Linux > at
http://infocenter.sybase.com/help/topic/com.sybase.infocenter.help.ase.15.7/title.htm

2.2.8: DETECT SYSAM ERRORS AND TAKE THE APPROPRIATE ACTION To avoid interruptions in service, it is CRITICAL that you regularly scan your log for SySAM messages and take the appropriate action to resolve any error messages or warnings. Therefore, consider the following: SySAM performs licensing checks at various times during the servers runtime cycle: o o Some licenses are checked at startup, some upon access of the feature and some are checked at both times. Licenses are also checked periodically during the servers runtime according to a heartbeat interval of 2 to 24 hours. When invoked, a mechanism checks for any changes and updates to ASE licenses.

Because SySAM checks for license issues on a regular basis during the servers run cycle, SySAM errors can be detected and reported at any time: o o When a message is issued, it is important that you take the appropriate action in a timely manner. All SySAM-related errors are printed in the ASE error log and are prefixed with "kernel SySAM:. For example:
<timestamp> kernel SySAM: Failed to obtain 1 license(s) For ASE_CORE feature from license file(s) or server(s).

o o o o

If e-mail alerts are configured, recipients also receive an e-mail whenever a SySAM event occurs. When a license problem is first noted, ASE provides a 30-day grace period from the time of build, if applicable. SySAM error messages will provide date information to indicate if and when ASE will be shutdown. Permanent licensing will support a runnable grace or run-time grace period. To avoid interruptions in service, it is CRITICAL that you regularly scan your log for SySAM messages and take the appropriate action to resolve any error messages or issues.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 57 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


o For more information on Fault Tolerance, License Grace and Redundancy, see:

Sybase ASE 15

_________________________________________________________________________________________________

http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc70043.0200/doc/html/san1263 843579787.html

STEP 2.3: CREATE A PRE-UPGRADE BASELINE OF QUERY PERFORMANCE


In order to determine how well ASE is performing after the upgrade, it is crucial to have a quantitative understanding of how ASE performed prior to the upgrade. One of the best ways of doing this is to establish a baseline of pre-upgrade performance: Baseline Environment: Your pre-upgrade baseline is best created using your production environment. If this is not feasible, then the next best option is a non-production environment that very closely simulates your production environment. The closer your baseline environment matches your production environment, the greater the validity of your baseline data. Baseline Data Generation: At a minimum, we recommend the execution of your most frequently used and business-critical queries, stored procedures, reports, data feeds and batch applications. The more queries you test, the less chance of surprises. Baseline Data Measurements: Baseline measurements should consist of the following: o Measurement of query execution times. If possible, divided into three components: o o o Network time from the client to ASE. Execution time within the ASE server. Network time from ASE back to the client.

Measurement of logical I/Os. A collection of ASE Query Plans for each query being tested (see the following section for more details). A collection of result sets and report output from key applications for later comparison to post-upgrade results.

Baseline Data Collection Methods: There are various methods of collecting baseline performance data, such as the following: o o Canned stored procedures to query the MDA tables. A wrapper type of stored procedure that executes and times your compiled objects. MDA and Wrapper stored procedures are available at the following links:

MDA Link: http://www.sybase.com/files/Technical_Documents/MDA_Collector.zip Wrapper Link: http://www.sybase.com/files/Technical_Documents/gen_collector.zip

o o

Third-party tools. Your own method of measuring performance. The important point here, is that you use some method of quantitatively measuring how your system runs, at as detailed a level as possible, before you begin your upgrade.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 58 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 2.4: GENERATE AND SAVE ABSTRACT PLANS


Beginning with ASE 12.0, abstract plan capture can be used to intercept client-submitted SQL text. This text is stored in the sysqueryplans table along with the abstract query plan. This captured query text can be retrieved directly from this table. In ASE 15, the new feature of query metrics capture uses this same underlying mechanism of abstract plan capture to collect execution metrics (such as I/O counts and execution times), along with the SQL text. These metrics are also stored in sysqueryplans, but should be accessed through a view called sysquerymetrics. It is strongly recommended that you capture and save query plans from your pre-upgraded production server for the following purposes: o o For later comparison to post-upgrade query plans. Query plans can be used to help resolve performance problems in the event there is an issue with a particular query. For import into your post-upgraded server. Ideally, these query plans are from production or they may not be useful. Keep in mind that many of the Abstract Plans in ASE 12.5.x will not import to 15.x because of the optimizer differences.

For more information about query metrics capture, see the ASE 15.7 Performance and Tuning Series: Query Processing and Abstract Plans at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00743.1570/html/queryprocessing /title.htm

STEP 2.5: VERIFY THE FREE SPACE IN ALL DATABASES


User Databases Make sure that you have plenty of free space within your pre-upgraded databases. While the preupgrade utility will help verify that ample space is present, it is always advisable to have at least 25% of free space available within each user database. You can verify this by reviewing the output of either dbcc checkstorage or dbcc checkalloc (from the previous step) which report the amount of free space. System Databases Due to the increased space required for the system catalog, Sybase recommends that system databases such as master and sybsystemprocs be no more than about 50% full.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 59 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 2.6: VERIFY THE NUMBER OF LOCKS CONFIGURED FOR UPGRADE


In order to help ensure that you configure ASE with enough lock structures for the upgrade process to complete successfully, we recommend that you perform the following steps: 1. In every user database, execute the following query:
1> select 2 * (count(*)) + 100 from systabstats 2> go

2. Record the highest value returned. 3. Run the following command from any database:
1> sp_configure number of locks 2> go

4. If the value from Step 2 above is less than the current number of configured lock structures, then increase the configured value to the value from Step 2, as shown below:
1> sp_configure number of locks, <new value> 2> go

STEP 2.7: CONSIDER REPLACING THE UPDATE STATISTICS COMMAND


One of the major enhancements to ASE 15s new query optimizer is its increased use of statistical attributes. That is, prior to ASE 15.x, the optimizer only used statistics from the leading column of a multi-column/composite index. Therefore, the update statistics command only creates statistics for the leading column of each index. In ASE 15, this has changed and the optimizer will now consider statistics on all columns of a composite index. Therefore, we strongly recommend the following for ASE 15: 1. Run the update index statistics <tablename> whenever possible. 2. If feasible, replace your update statistics commands with the update index statistics command. This command will generate statistics on all columns of a composite index and will help ASEs optimizer make the best decisions. Note: Since the "update index statistics" command is doing more work in ASE 15 than in ASE 12.5, updating a tables statistics will take longer in ASE 15 than in ASE 12. That is, at least for indices with more than one column. On very large datasets, you may need to consider alternate ways of gathering statistics in order to meet maintenance windows and/or resource constraints. Some of these methods include: o Running update statistics <table> <optional index> to generate statistics for the leading column of one or all indices, as well as densities of all pre-fix permutations of columns in composite indices. Then running update statistics <table> <column(s) > for all unique columns in the table that are contained in one or more indices. These can run in parallel, given sufficient CPU, memory, and tempdb space.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 60 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

Running update index statistics with sampling percentage. However, keep in mind that there are no recommended values for the sampling. Therefore, you will need to test and balance between too low a percentage (rendering the statistics ineffective), and too high a percentage (not yielding any significant savings in time). Running update statistics as needed, determined by using the datachange() function, with the understanding that the percentage can vary depending on the cardinality of underlying data. Importing current statistics from a Disaster Recovery or Development server with the same data using optdiag. For more information and examples, see the Migration or Administrators guide.

o o

STEP 2.8: PERFORM THE PRE-UPGRADE STEPS IN THE INSTALL GUIDE


Perform the pre-upgrade steps specified in the ASE Installation Guide. These are found in the Performing Pre-Upgrade Tasks section within the ASE 15.7 Installation Guide for your platform. For example, on Linux, these would be found at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc30119.1570/doc/html/jon1257988 586420.html

These steps include, but are not limited to: o Check the system and upgrade requirements. o Verify that master is the default database for the "sa" user. o Confirm that you have enough space for the upgrade to succeed. You may need to increase the size of sysprocsdev before upgrading Adaptive Server. o Ensure you have sufficient physical memory. o Ensure that the directory to which your TEMP environment variable points exists. o Run a Reserved Word Check
o o Verify that the text of all stored procedures you upgrade is available in syscomments. If you deleted text from the syscomments system table, drop and then re-create the stored procedures to re-add the text. Sybase recommends that you use the sp_hidetext stored procedure to hide text, rather than deleting text.

o Prepare the database and devices for upgrade using the preupgrade utility, and fix any problems that the preupgrade utility identifies. o If you use auditing, obtain the current audit settings for the pre-15.7 Adaptive Server using sp_displayaudit; you use this saved information to re-enable auditing after you complete the installation. o If you modified any system stored procedures without altering their names, back them up before you upgrade Adaptive Server.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 61 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 2.9: PERFORM THE PRE-INSTALLATION TASKS FOR A CLEAN INSTALL (AS NEEDED)
If you have chosen the Clean Install (dump and load) method of upgrading ASE, then you will need to perform the pre-installation tasks specified in the Installation Guide for your platform. For example, if you are installing ASE 15.7 on Linux see:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc30119.1570/doc/html/title.html

If you are not using the Clean-Install method, then you can skip this step and continue with the upgrade steps listed below.

STEP 2.10: PERFORM THE PRE-UPGRADE STEPS FOR APPLYING AN EBF


Applying an EBF overwrites your existing ASE software. Therefore, if you are applying an EBF, backup your $SYBASE directory, in case you need to roll back to the original version of the software.

STEP 2.11: IMPLEMENT YOUR ASE DATABASE DEVICE ATTRIBUTES


Implement any changes you decided to make to your database device attributes.

STEP 2.12: CHECK THE CONSISTENCY OF THE MASTER AND ALL USER DATABASES
2.12.1: GENERAL CONSISTENCY CHECKS Attempting to upgrade a corrupted database is a recipe for a failed upgrade and a time-consuming recovery process. Therefore, we strongly recommend that you complete consistency checks prior to attempting an upgrade to ASE 15.x. That is, we strongly recommend running dbcc checkstorage on the master and all user databases. If you prefer not to run dbcc checkstorage, then it is probably sufficient to run dbcc checkdb and checkalloc on the master and all user databases. Resolve any issues reported by these procedures before continuing with the upgrade. 2.12.2: CHECK SYSTEM TABLES You should manually review the sysusers and the sysroles tables to ensure that any manually inserted user or role IDs are within the normal Sybase user range.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 62 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

If the upgrade process attempts to add a new user or role and one already exists with the same ID, then the attempt will fail and the entire upgrade could be compromised. This can occur because in ASE 12.5.x some of the user roles (such as dtm_tm_role, ha_role) were not automatically installed in the user databases by ASE. If these roles were added to the database in 12.5.x as a user defined roles, the lrid and uid of this role can conflict with the system roles that are automatically created in databases by ASE 15. o To verify this, execute the following: select * from master..syssrvroles select * from dbname..sysroles select * from dbname..sysusers o The relationships are: db.sysusers.uid <-> db..sysroles.lrid db.sysroles.id <-> master.syssrvroles.srid

The workaround is to remove the entries of mismatched roles.

STEP 2.13: BACKUP ALL USER DATABASES


Backup your user databases after running consistency checks. If there is an issue with the upgrade, you will use this backup to recover your databases.

STEP 2.14: BACKUP THE MASTER DATABASE


Backing up the master database is the cornerstone of any backup and recovery plan. The master database contains details about the structure of your entire database system. Its keeps track of the ASE databases, devices, and device fragments that comprise those databases. Because ASE needs this information during recovery, it is crucial that you maintain an up-to-date backup copy of the master database at all times. To ensure that your backup of master is always up to date, back up the database after each command that affects disks, storage, databases, or segments. This means you should back up the master after performing any of the following procedures: Creating or deleting databases. Initializing new database devices. Adding new dump devices. Using any device mirroring command. Creating or dropping system stored procedures, if they are stored in master. Creating, dropping, or modifying a segment. Adding new Adaptive Server logins.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 63 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

To back up the master db to a tape device, start isql and enter the following command:
1> dump database master to "tape_device" 2> go

Note: tape_device is the name of the tape device-for example, /dev/rmt0):

STEP 2.15: DUMP THE TRANSACTION LOG


Dump the transaction log after backing up your user and master databases.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 64 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 3: UPGRADE STEPS FOR THE TEST ENVIRONMENT


STEP 3.1: BULK COPY OUT KEY SYSTEM TABLES
We recommend that you bulk copy (BCP) the contents of the following system tables from the master database and have them available after the upgrade:
sysdevices (optional, depending on usage) sysconfigures sysservers syscharsets sysremotelogins syslogins sysloginroles sysusages sysdatabases

STEP 3.2: DISABLE REPLICATION


You can use Sybase Central or the procedure below to quiesce a system consisting of several Replication Servers. Quiesce a Replication System 1. Execute the suspend log transfer from all command at each Replication Server. This prevents the RepAgent from connecting to the Replication Servers. 2. Execute admin quiesce_force_rsi at each Replication Server. This command forces the Replication Server to deliver all queued messages to other Replication Servers, then reports whether the system is successfully quiesced. Quiescing occurs most efficiently if you follow the flow of the data. For example, if data flows from TOKYO_RS to MANILA_RS to SYDNEY_RS, quiesce the Replication Servers in that order. Verify the Quiescent State 1. Check that the Replication Server is quiescent using the admin quiesce_check command. If necessary, repeat steps 2 and 3 until all Replication Servers are quiescent. 2. After all Replication Servers are quiescent, execute admin quiesce_force_rsionce more at each Replication Server. Check that each Replication Server is quiescent using the admin quiesce_check command. If necessary, repeat this step until all Replication Servers are quiescent. This step is necessary because, although a Replication Server may be quiescent, it may have recently sent messages to another Replication Server. These messages may initiate more communication between these two Replication Servers or between several Replication Servers in the replication system. Repeating steps 2 and 3 ensures that you have quiesced the entire replication system.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 65 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


STEP 3.3: UNPARTITION ALL PARTITIONED TABLES

Sybase ASE 15

_________________________________________________________________________________________________

Because of changes to the system tables, and the changes made to support semantic partitioning, tables that are partitioned on pre-ASE 15.x servers will be unpartitioned during the upgrade process. Prior to unpartitioning any tables, please be sure to record exactly which tables are partitioned and to what degree. This can be done by running the below procedure:
1> sp_helpartition 2> go

There are two ways to unpartition your tables: o o You can manually execute an alter table <table_name> unpartition command for every partitioned user table. Or, you can execute the following stored procedure: 1> sp_unpartition <dbname> 2> go Note: The sp_unpartition procedure is not a normal Sybase system stored procedure, but documentation for it can be found at the following link:
http://www.sybase.com/files/Technical_Documents/ase15_mig_stored_procs.zip

STEP 3.4: QUIESCE ALL DATABASES


This step is to prevent the occurrence of uncommitted transactions in the log. These can cause problems during the database upgrade process. This step also helps to ensure overall consistency and efficiency of the upgrade process. To quiesce the database, we use the same process as used for performing a Cross-Platform Dump/Load: 1. Execute dbcc checkdb and dbcc checkalloc to verify the database is clean. 2. To prevent concurrent updates from open transactions by other processes during dump database, use sp_dboption to place the database in a single- user mode. 3. Flush statistics to systabstats using sp_flushstats. 4. Wait for 10 to 30 seconds, depending on the database size and activity. 5. Run checkpoint against the database to flush updated pages. 6. Run dump database.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 66 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 3.5: PERFORM THE UPGRADE


When you reach this step, it is time to execute the upgrade method that you determined in the PreUpgrade Planning phase (Step 1.2) of this process. If you have not already done so, you should also perform any pre-upgrade steps specified in the ASE Installation Guide, Release Bulletin or EBF Cover Letter.

STEP 3.6: UPGRADE YOUR CLIENT SOFTWARE


If you need to upgrade your client software (such as your Sybase OpenClient, ODBC, jConnect, etc), this is a good time to do so. If you are upgrading to ASE 15.7, we recommend that you upgrade your OpenClient software to version 15.7.

STEP 3.7: UPGRADE YOUR MIDDLEWARE, INTERFACES AND 3 RD PARTY SOFTWARE


This is the step to perform any necessary upgrades to your middleware, interface processes, 3rd-Party utility or application software such as DirectConnet, SQL Backtrack, Trizetto, Informatica, etc.

STEP 3.8: UPGRADE ANY OTHER SOFTWARE


This last step is a reminder to perform any other software upgrades necessary to support your applications running on the upgraded server.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 67 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 4: POST-UPGRADE STEPS FOR THE TEST ENVIRONMENT


OVERVIEW
As part of a best practices approach, you will upgrade your ASE server in a test environment before upgrading in production. In this phase, you will evaluate the impact of the upgrade on your applications, tune ASEs new features and standardize your upgrade procedures. Doing so, will ensure a successful upgrade and avoid any unpleasant surprises in production.

STEP 4.1: PERFORM THE POST-UPGRADE STEPS Your post-upgrade steps will vary depending on a number of factors including the type of upgrade method you choose (in-place vs. clean-install), the EBF you are applying, and your use of Replication. 4.1.1: POST-INSTALLATION TASKS If you are using the Clean Install method of upgrading, then this is the step to perform any post-upgrade steps specified in the Post-Installation Tasks section of the ASE 15.7 Installation Guide for your platform. For Linux, this would be the ASE 15.7 Installation Guide for Linux at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc30119.1570/doc/html/rsa12362074338 82.html

4.1.2: POST-UPGRADE TASKS FOR YOUR EBF This is the step to perform the post-upgrade steps specified in the Cover Letter of the EBF you are applying For example, the EBF Cover Letter for ASE 15.7 ESD#1 for Linux on Power can be found at: http://download.sybase.com/swr/15483/EBF19810 README.html Per the Cover Letter, the post-installation steps for an EBF may include the following: o o Reload any Sybase system stored procedures you have modified. Run Required Scripts: Run the new installmaster script included with the release. o Run the instmsgs.ebf script to bring your ASE messages up to the level of the software you are installing. Run the installdbccdb script if you have created a dbccdb database. Run the installmontables script if you have previously installed the Monitoring Tables. Run the installcommit script if you use two-phase commits or distributed transactions. Run the installsecurity script if the ASE Auditing functionality was enabled in your installation of ASE.

Run the Optional Scripts:

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 68 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


Run the installhasvss script if you are using the HA functionality.

Sybase ASE 15

_________________________________________________________________________________________________

Run the installmsgsvss script if you are using the RTDS ASE MESSAGING. Run the installpcidb script if you are using the Java in database functionality during the installation or upgrade. Run the installjsdb script if you have installed Adaptive Server with the Job Scheduler feature enabled.

4.1.3: ROLLING BACK AN EBF If for any reason it is necessary to revert to the previously installed release, you will need to use the backup copy you created earlier in the pre-upgrade phase of this upgrade process. You will also need to rerun the install scripts located in your backup copy. This will ensure that all scripts and messages are returned to their former versions. 4.1.4: RE-ENABLE REPLICATION Re-enable Replication if you are using it.

STEP 4.2: RECREATE TABLE PARTITIONS


Since partitioned tables in pre-15 will be un-partitioned after upgrading to 15, you will need to repartition your tables. The pre-15 syntax for partitioning remains valid, and the results are equivalent to using the new round robin partitioning syntax. The only exception is alter tableun-partition. This syntax is not valid, since un-partitioned tables do not exist in 15. That is, by default, each table has at least one round robin partition. Also note: Each partition has its own partition ID in the page header. Therefore, a new partition-id is stamped on every page during the database upgrade process. This requires additional time and resources during the upgrade, because every page of the table is modified and logged, even though no data is moved.

STEP 4.3: REPLACE THE UPDATE STATISTICS COMMAND


This is the step to test the use of the update index statistics <tablename> instead of the update statistics command as discussed in step 2.7. Since the ASE 15 query optimizer is now able to use the additional information generated by the update index statistics command, providing this data will improve query performance by providing the optimizer with more information.

STEP 4.4: DELETE OR UPDATE STALE STATISTICS


___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 69 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

In this step, you will identify and delete old statistics pre-upgrade statistics that were created using one of the update statistics commands: update statistics, update index statistics, update all statistics, or update statistics tablename (<columnname>). 4.4.1: Identify Stale Statistics Stale statistics will negatively affect performance if the histogram, density and selectivity values are no longer representative of the data contained in the columns. Generating current statistics, or removing unused statistics, will help the optimizer choose the most efficient access plan. Use the following query to identify stale statistics. (Note: This output is ordered by oldest to newest statistics:
use <database> go select "Oldest to Newest Statistics" = convert(varchar(40), object_name(sc.id) + "." + sc.name), "Last updated On " = convert(varchar,ss.moddate,0) from syscolumns sc, sysstatistics ss where ss.id = sc.id and ss.colidarray = convert(varbinary,sc.colid) and ss.formatid = 100 and ss.id > 99 order by ss.moddate asc, sc.name

4.4.2: Delete Stale Statistics To remove unused statistics, use the delete statistics command. For example, delete statistics <table_name> (column_name). Note: Dropping an index does not drop the statistics for that index. Further, if the distribution of keys in the columns change after the index is dropped, the outdated statistics will negatively affect query plans. 4.4.3: Restore Statistics (as needed) When used with just the table name, the delete statistics command removes all statistics for a table, even where indexes exist. In this case, you must run update index statistics on the table to restore the statistics for the index.

STEP 4.5: RECREATE OPTIMIZER STATISTICS


Since ASE 15s query optimizer uses more statistical information about data column attributes than in previous versions, it is extremely important to give the optimizer all the data it can use. This step presents procedures for generating missing statistics and step counts. Note: This step can be performed whenever you experience a slow performing query. 4.5.1: MISSING STATISTICS
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 70 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

To check for missing statistics, ASE 15.0.2 and above provides a new option, show_missing_stats on. This option displays a short message for each column or column group where the availability of additional statistics would have helped the optimizer. Below, are examples of how it may be used both by a user with sa_role and a user without sa_role: o User with sa_role: This option requires either Trace Flag 3604 or 3605 for all users!
set option show_missing_stats on dbcc traceon(3604) go User with sa_role granting permission to DevUser: grant set tracing to DevUser go

User without sa_role:


User DevUser: Trace Flag 3605 sends messages to the error log. set option show_missing_stats on go

In addition to using the new set option above, we also recommend making the following configuration changes:
1> sp_configure number of histogram steps, 200 2> go 1> sp_configure histogram tuning factor, 10 2> go

4.5.2: ESTIMATE IDEAL STEP COUNTS To estimate the new ideal step count value, use the following process for all user tables: 1. For each large or key table, use the data_pages function to determine the number of data pages that the table currently occupies. Then, divide this number by 10,000. (Sybase estimates each table will have one histogram step per 10,000 data pages; but never to exceed 2,000 steps). For example:
1> select data_pages(db_id(), object_id(<table_name>) ) / 10000 2> go

2. Note: If the result from the above query is either of the following: Greater than 2,000: Then use 2,000 histogram steps for indices on that table. Less than 20: Then use 20 histogram steps for indices on that table. 3. Then for each key table, execute the following command:
1> update index statistics <table_name> using <# steps> values 2> go

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 71 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

4.5.3: OPTIMIZER STATISTICS DOCUMENTATION For more information on using optimizer statistics, see Understand & Managing Optimizer Statistics in ASE at: http://www.sybase.com/files/Technical_Documents/understanding_optimizer_stats.zip

STEP 4.6: CONFIGURE AND TUNE THE NEW ASE 15 RESOURCES REQUIREMENTS
STEP 4.6.1: OVERVIEW ASE 15s new features and enhancements require more resources than in ASE 12. Consequently, several configuration parameters must be adjusted to achieve optimal server performance. In this step, you will configure and tune these resource settings as needed for your application. Note: Testing these settings can occur in parallel with the query performance testing described below. However, optimizing these settings requires the use of ASEs sysmon utility as you perform your other testing. STEP 4.6.2: CONFIGURE PROCEDURE CACHE ASE 15s new query processing engine requires more procedure cache than in previous versions. This increased requirement applies to both the optimization and execution of queries. ASE 15 also has many more join methods and data access algorithms than in prior versions. This is especially true for allrows_dss, which generally consumes more procedure cache than allrows_mix, which in turn usually requires more procedure cache than allrows_oltp. It is difficult to predict exactly how much more memory ASE 15 than before. As a rule of thumb, Sybase recommends increasing ASE 15s procedure cache between 2 to 6 times, over what it was in ASE 12.5. Use the procedure cache section of sp_sysmon to monitor and tune procedure cache usage. Note: There is a new sizing limitation for procedure cache: As of ASE 15.0.2 ESD#2, a limitation was imposed on the maximum amount of procedure cache than can be used by the query optimizer. This is based on the value of the "max resource granularity" configuration parameter. This setting is an integer between 1 and 100, reflecting a percentage. The default setting is 10. This parameter can be set at the session level with set resource_granularity. STEP 4.6.3: RE-SIZE TEMPDB ASE 15 requires a larger tempdb than ASE 12.5. This is partly due to an increase in the workspace requirements of more join methods and access algorithms. Additionally, several new features also increase tempdb utilization, such as scrollable cursors, computed columns, and functional indexes.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 72 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

Keep this increased utilization in mind when planning disk space, and when observing I/O rates in tempdb. The amount of increased tempdb usage will vary, depending on the optimization goals you use, the features you use, and your specific workload mix. STEP 4.6.4: SEMANTIC PARTITIONING AND SIZING THE NUMBER OF OPEN PARTITIONS Table partitioning is another new feature of ASE 15. Although semantic data partitioning is an optional license feature, its introduction affects resource consumption even when it is not enabled. That is, each table and index consists of at least one partition in ASE 15. Consequently, the value of the configuration parameter number of open partitions must be set high enough to avoid unnecessary performance overhead in the reuse of this resource. As a starting point, Sybase recommends using sp_countmetadata to estimate the required setting for this parameter and then use sp_monitorconfig to monitor usage. Keep in mind that temp tables are not included in the results of sp_countmetadata. STEP 4.6.5: STATEMENT CACHE AND LITERAL AUTO-PARAMETERIZATION Advantages of Enabling S tatement Cache and Literal Auto Parameterization Due to the increased complexity of query optimization in ASE 15, the query optimizer will typically use significantly more resources (compilation time and procedure cache) than in prior versions. Therefore, if you are running many identical, or similar SQL queries (queries that differ only in their search argument), we strongly recommend enabling both statement cache and the new literal autoparameterization feature (introduced in ASE 15.0.1). These settings will improve overall performance by reducing the time and resources required by the query optimizer. Statement Cache: When statement cache is enabled, the first execution of a query results in the caching of its query plan. When the query runs again, it reuses the cache plan rather than recompile it again, thus improving performance by saving time and resources. Literal Auto-Parameterization: With literal auto-parameterization enabled, caching is extended to almost-identical queries that differ only in a constant value, and are likely to end up with the same plan. Therefore, literal auto-parameterization can greatly improve the effectiveness of your statement cache. We recommended that you enable and test this feature if your application uses many almost-identical SQL queries that are not part of stored procedures and are not run in executeimmediate. Enabling Statement Cache The statement cache is enabled sever-wide with the configuration parameter: 1> sp_configure "statement cache size" 2> go Note: The statement cache can be disabled at the session level using the set statement cache off.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 73 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

Enabling Literal Auto-Parameterization Literal auto-parameterization is enabled with a new server-wide configuration parameter:
1> sp_configure "enable literal autoparam" 2> go

At the session level, literal auto-parameterization can be enabled using the set command. Note: This setting will only take affect if statement cache is enabled:
> set literal_autoparam [off | on]

Sizing Statement Cache A cached statement requires approximately 1K memory in the statement cache (depending on the length of the SQL text), plus 2k for the cached plan, plus a few hundred bytes of overhead per plan. Since the statement cache will contain duplicate plans when two or more users request a plan concurrently, usage depends on the number of queries and the size of cached statements. Be careful NOT to make the statement cache too large. If it is too large, then the time it takes to search the cache will exceed the time saved by not having to read the statement into cache. Therefore, start with a small statement cache and monitor it with sp_sysmon. For example, we recommend the following procedure: o o Start with a statement cache size of 25 Mbs to 100 Mbs. Then, monitor statement cache usage by reviewing the Statements Dropped counter in the sysmon reports. The Statements Dropped counter displays the number of statements that were dropped from the cache. A high value usually indicates either an insufficient amount of procedure cache, or the statement cache size is too small. If the number of statements dropped is high, consider increasing size of the statement cache. For more details on monitoring statement cache, see Monitoring the statement cache in the Adaptive Server Enterprise 15.7 > System Administration Guide: Volume 2 > Configuring Memory > The statement cache > Setting the statement cache at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc31644.1570/html/sag2 /sag299.htm

o
o

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 74 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 4.7: CONFIGURE AND TUNE THE NEW KERNEL RESOURCE SETTINGS
4.7.1: OVERVIEW Once you have configured the new resource settings in the previous step, you will need to configure and tune the new kernel resource settings. These configurations include the following: o o All execution classes lose their engine groups and are associated with syb_default_pool. The administrator may then associate the execution classes with engine thread pools. Engine groups are obsolete when running in threaded mode. In this mode, use sp_addexeclass to bind execution classes to user thread pools. Thread pools separate processor resources between applications within Adaptive Server. The value of sp_configure max online engines must be greater than the current number of engines online. Because online is a reserved keyword, you must use quotes. When onlining engines using sp_engine online, note the following: In the threaded mode, online increases the thread count for syb_default_pool by 1.

Therefore, in this step you will configure and tune these resource settings as needed for your application: o o o o o The number of OS file descriptors. The ASE kernel resource memory parameter. The ASE idle timeout parameter. The ASE max online engines parameter. The number of user connections and number of open indexes may need to be temporarily reduced (per CR #696227 listed above) if you are performing an in-place upgrade.

4.7.2: SWITCHING KERNEL MODES Purpose: o In ASE 15.7 and above, the server is configured to use the new thread-based kernel mode by default. o o o However, the previous process-based kernel has been retained for risk mitigation, and can be enabled using the new kernel mode configuration option. This static parameter sets the kernel mode to process or threaded. The server must be rebooted for this option to take effect. Reverting to the processed-based kernel mode should only be considered as a last resort for resolving an issue or if you are specifically instructed to do so by Technical Support. Otherwise, we recommend using the threaded kernel.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 75 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


o

Sybase ASE 15

_________________________________________________________________________________________________

For more details on setting this or other configuration settings, please see Alphabetical Listing of Configuration parameters in the Adaptive Server Enterprise 15.7 > System Administration Guide: Volume 1 > Setting Configuration Parameters > Configuration parameters at
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc31654.1570/html/sag1 /sag1113.htm

Syntax: o sp_configure kernel mode, 0, <process/threaded> Process vs. Threaded Mode: o Usage: o Interactive: To interactively set the kernel mode to process-based, do the following: 1>sp_configure "kernel mode", 0, process 2>go o Then, restart the server for this option to go into affect. Using the Configuration File: Edit your server configuration file to explicitly set the kernel mode to process: Add the following: kernel_mode = process. This option will take affect the next time the server is started. Verification: o To verify which kernel mode is operational, you can query the new global variable for the kernel mode: 1> select @@kernelmode 2> go o You will also see the following message in the startup sequence of the ASE error log when using the threaded-kernel mode:
00:0000:00000:00000:2011/12/02 13:19:24.19 kernel Adaptive Server is using the threaded kernel mode.

New to ASE 15.7. Independent of kernel. Can be set in either mode to switch kernel mode.

4.7.3: SETTING THE FILE DESCRIPTOR VALUES Purpose: o Sets OS file descriptions for ASE. Syntax: o The syntax for setting file descriptions varies by OS platform. Process vs. Threaded Mode: o Changes: Both process and threaded kernel modes use file descriptors. However, the formula for estimating the number of file descriptors differs between the two.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 76 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


o

Sybase ASE 15

_________________________________________________________________________________________________

In Threaded Mode: When using the new Threaded Kernel mode (default), you will use a different formula to estimate file descriptors than used in the process-based mode. The Formula for Estimating File Descriptors in Threaded Mode: Use the following formula to compute the maximum number of file descriptors per ASE process in threaded mode: The number of user connections + number of remote sites + max cis remote connections + number of java sockets + max number network listeners + max native threads per engine + overhead. For UNIX, this is the value for the ulimit n parameter.

In Process Mode: When using the previous Process Kernel mode, each engine adds to ASEs descriptor pool. The Formula for Estimating File Descriptors in Process Mode: Total descriptors = per-process limit * engines.

Tuning: o You may need to adjust your shell limits for large user configurations.

4.7.4: SETTING THE KERNEL RESOURCE MEMORY PARAMETER Purpose: o Controls the amount of memory available for kernel allocations. Syntax: o sp_configure kernel resource memory Process vs. Threaded Mode: o o Changes: None. This parameter applies to both kernel modes and the formula for estimating the value for this parameter remains the same and is as shown below. Rules of Thumb for Both Process and Thread Modes: 1. <= 8 engines: 1 page per two user connections. 2. 8+ engines: default + 1 page per user connection. o Also, see CR #696227 in the Known Upgrade Issues section above.

Verification: o Check utilization with sp_monitorconfig : 1> sp_monitorconfig "kernel resource memory" 2> go

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 77 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

4.7.5: SETTING THE MAX ONLINE ENGINES PARAMETER Purpose: o Places an upper limit on the number of engine threads that can be brought online. It does not take into account the number of CPUs available at start-up, and allows users to add CPUs at a later date. See Chapter 5, Managing Multiprocessor Servers, in System Administration Guide: Volume 2 for a detailed discussion of how to set this parameter for your SMP environment. Syntax: o sp_configure max online engines, 8 reboot alter thread pool syb_default_pool with thread count = 8 Usage: o The value of sp_configure max online engines must be greater than the current number of engines online. Because online is a reserved keyword, you must use quotes. Process vs. Threaded Mode: o In Threaded Mode: max online engines is still a static parameter. The number of engines at startup is ignored. Engines are based on explicit thread pool sizes. Use alter thread pool to online & offline engines When using the sp_engine online procedure, the online value increases the thread count for syb_default_pool by 1. Verification: o To verify how many engines are configured: Total engines = syb_default_pool thread count + user pool thread counts. o
o

Select count(*) from sysengines still works, but it cannot return a value greater than max online engines.

Relevant CRs: o CR 684046: Free the Kernel Resource Memory after copying the thread pool configuration. 4.7.6: SETTING THE IDLE TIMEOUT PARAMETER Purpose: o In threaded kernel mode, the Idle timeout parameter for the alter thread pool command replaces the runnable process search count (RPSC) parameter from the process kernel mode. Syntax: o alter thread pool pool_name with { pool name = new_name thread count = thread_count, [pool description = description]} [idle timeout = time_period]
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 78 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

Usage: o For example, to modify the test_pool so that threads sleep if they do not find work after 500 microseconds: 1>alter thread pool test_pool with idle timeout = 500 2>go Process vs. Threaded Mode: o RPSC: For the process-based kernel, the RPSC parameter controls how engines spin before sleeping: Set via sp_configure. It is server-wide, and applies to all engines. It is a loop count, and specifies how many times ASE loops looking for work. This can result in drastically different times across different computers. The RPSC setting remains available for the process mode only. o Idle Timeout: For the new threaded kernel, the idle timeout setting controls how engines spin before sleeping: Set the idle timeout value using the alter thread pool command. idle timeout is an attribute of the thread pool and therefore you can mix values within an ASE server. Is a time value in microseconds (one millionth of a second) that is consistent across different computers. Tuning Considerations: o o o o o o o This is a dynamic configuration setting that can be easily modified as needed. The default is 100 microseconds (one millionth of a second). If this value is set too low, it can lead to added latency due to engine sleep. A value of 0 means never spin, sleep immediately. At this setting, latency can be increased by the overhead of re-acquiring the CPU. If this value is too high, it can result in wasted CPU cycles. A value of -1 means never sleep, always spin, never yield. At this setting, the engines consume 100% of the CPU. Note: ASE at lower values (under 100) ASE may not precisely honor the timeout period.

Tuning Recommendations: o Start with the default, and then use the sp_sysmon output for CPU Yields, Engine Utilization and Context Switches at OS to determine whether this parameter needs to be adjusted.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 79 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


Tuning Examples: o CPU Yields: Sample output (sp_sysmon):

Sybase ASE 15

_________________________________________________________________________________________________

CPU Yields by Engine per sec per xact count % of total -------------------------------------- ------------ ---------- ---------ThreadPool : syb_default_pool Engine 0 Full Sleeps 0.1 0.2 2 0.5 % Interrupted Sleeps 2.0 5.5 60 16.5 % Analysis: Full sleeps are good. A high percentage of interrupted sleeps may indicate the idle timeout value is too low. Sample output (sp_sysmon): Engine Utilization (Tick %) User Busy System Busy I/O Busy Idle ----------------------------------------- -------------- ----------------- -------------- --------ThreadPool : syb_default_pool Engine 0 1.0 % 0.0 % 54.0 % 45.0 % Analysis: If Engine utilization is greater than OS utilization, this could mean the idle timeout is too high. If User Busy percentage is low (single digits), and I/O Busy percentage is high and context switching high (see below), then consider adjusting the idle timeout value, or take one or more engines offline because threads are not being used effectively.

Engine Utilization:

Engine OS Context Switching: Sample output (sp_sysmon): Context Switches at OS per sec per xact -------------------------------------------- ------------ -----------ThreadPool : syb_default_pool Voluntary 0.0 0.0 Non-Voluntary count % of total --------- --------------0 0.0 %

Analysis: If non voluntary context switches on the syb_default pool are high, consider reducing the idle timeout.

Relevant CRs: o CR#686282: Fixed in ASE 15.7 ESD #1 Idle timeout value for a thread pool is set to 0, if it is set to 'DEFAULT' in configuration file.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 80 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


4.7.7: ERRORLOG CHANGES

Sybase ASE 15

_________________________________________________________________________________________________

In both threaded and process kernel mode, each line entry in the ASE log is preceded by a header row of information. This format is as follows: instance id : engine number : family id : spid : date time: msg When running in threaded mode, the internal thread id replaces the engine number. This allows us to identify messages from non-engine threads. o For example: 00:0024:00000:00000:2011/04/27 10:28:07.82 kernel Thread 24 (LWP 24390) of Threadpool syb_default_pool online as engine 0 In this example, we can see that engine 0 came online as thread 24, and that 0024 is reported as engine 0 in the message. You can also lookup the ThreadID in the monEngine table: 1> select EngineNumber, ThreadID from monEngine 2> go EngineNumber ThreadID ------------------- ------------0 24 1 25 2 26 (3 rows affected) 4.7.8: TESTING Testing these settings can occur in parallel with the query performance testing presented below. However, optimizing these settings may also require the use of ASEs sysmon utility to monitor and evaluate these settings as you perform your other testing.

o o

STEP 4.8: CREATE AND MAINTAIN A POST-UPGRADE BASELINE


STEP 4.8.1: OVERVIEW Now that your ASE software has been upgraded, the next step is to evaluate how it is performing. The best way to accomplish this is by conducting a thorough and methodical testing of your applications on the newly upgraded server. One of the primary goals of the testing phase is to tune ASE 15s new optimizer features. Secondarily, you will also want to use this environment to verify the resource configurations settings (described in the steps above), perform consistency and stress tests, and to test any new ASE 15 features you want to implement.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 81 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

The following sections present a discussion of recommended procedures for accomplishing this goal. STEP 4.8.2: CREATE A POST-UPGRADE BASELINE In order to quantitatively asses the impact of your upgrade, create a post-upgrade baseline for comparison to your pre-upgrade baseline. Repeat the same steps used earlier to create a pre-upgrade baseline. This includes: o o o o At a minimum, running your most frequently used and/or key stored procedures, queries, reports and batch applications. Measuring query execution times. Measuring logical I/Os. Collecting Query Plans as needed to help resolve any performance problems you encounter.

STEP 4.8.3: COMPARE PRE-UPGRADE AND POST-UPGRADE PERFORMANCE Once you have collected post-upgrade data, the next step is to compare this data to your pre-upgrade baseline. In general, this is an iterative process. That is, you will need to perform repeated testing and creation of post-upgrade levels of performance as you test, tune and evaluate ASE 15s new features and configuration settings.

STEP 4.9: TEST AND TUNE YOUR NEW OPTIMIZER SETTINGS

STEP 4.9.1: TEST AND TUNE YOUR NEW OPTIMIZATION GOALS 1. Optimizer Goals Optimization Goals are an important new concept in ASE 15.0. They provide hints to the Query Optimizer about the type of queries it will be optimizing. This enables the optimizer to generate better query plans in less time than before. Therefore, the goals you choose will affect the types of query plans generated and the time spent on optimization. The three supported optimization goals are as follows: 1. allrows_mix: This is the default server-level goal for ASE 15. This is the best goal for application environments running a mixture of simple online transactions and more complex decision support queries. 2. allrows_oltp: This is the best goal for application environments consisting primarily of OLTP, simple point queries using NLJ and sort based grouping.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 82 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

3. allrows_dss: This is the best goal for Decision Support (DSS) applications, medium-to-high complexity applications that use NLJ, SMJ, HJ sort/hash based grouping, bushy tree plans, and parallelism. To allow for fine-tuning of query performance, optimizer goals can be set at the server, session or query level. Goals set at the session level override the server level; goals set at query level override the session level. 2. Testing Goals In ASE 15, the allrows_mix goal was chosen as the server-level default because it can accommodate the widest range of queries. However, this goal may not be the best for all, or even some, of your queries. Therefore, the purpose of testing ASEs optimizer goals is two-fold: 1) To identify the best serverlevel optimizer goal; 2) To identify any queries or applications that require a different session level or query level goal. 3. One Goal May Not Work for All In complex processing environments, no single optimizer goal will be best for ALL queries. This is especially the case where there is a skewed workload mix. That is, where the applications mix is comprised mostly of one type of processing with a small number of another type. For example, mostly OLTP with just a few DSS reports; or, mostly DSS reports/batch processing with a small mix of OLTP. In these cases, it is best to set the server-level optimizer goal to the one goal that provides the best performance for the greatest number of queries. Then, override this server-level setting at either the session level, or query level, as needed to meet the performance requirements of a particular application or individual query. 4. Testing Strategies To determine which optimizer goals are best for your server, test all of the optimizer goals and compare the results to your pre-upgrade performance baseline: In general, it is best to begin your performance testing using the default goal of allrows_mixed. Depending on your performance results and requirements, test each of the other two goals using all or just some of your queries: o o You may find that all of your queries perform as well or better than they did on your preupgrade server when using the default goal. In this case, you may not need to continue testing. However, you may find that some of your queries do not perform as well as they did on your pre-upgraded server. In this case, repeat your tests using one of the other optimizer goals for those slow performing queries. The recommended approach is to test ALL of your queries using all three optimizer goals. This way, you will identify the optimizer goal that works best for each query, as well as which goal works best for the majority of queries.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 83 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


o

Sybase ASE 15

_________________________________________________________________________________________________

Use the goal that performs the best for the most number of queries as your server-level setting. Than, override this goal at the session or query level as needed for individual queries or applications.

5. Implementation Examples To set the optimizer goal at the Server Level, do the following:
> sp_configure "optimization goal", 0, "allrows_dss"

To set the optimizer goal at the Session Level:


> set plan optgoal allrows_mix

To set the optimizer goal at the Query Level:


> select * from blah plan "(use optgoal allrows_oltp)"

The individual optimization algorithms used under various optgoals can also be turned on and off at the session level, for example: o set nl_join ON/OFF o set parallel_query ON/ OFF o set merge_join ON/OFF 6. Additional Testing Considerations If you are still finding that one or more queries, stored procedures or other compiled objects have worsened in performance, we recommend you consider the following: o First, review Steps 2.7, 4.3, 4.4 and 4.5 regarding table and index-level statistics and ensure that the tables and indices involved all have up-to-date statistics. Second, if you have not already done so, re-run the query or procedure under each of the different optimization goals (in Step 4.9) to see if one generates a better plan than the others. Third, verify that your new server level configuration settings (in steps 4.6 and 4.7) are satisfactory. Fourth, for troubleshooting slow performing queries, it is very useful to compare the postupgrade query plans to you pre-upgrade query plans. This comparison can be used in performing the advanced tuning techniques listed below. Fifth, consider the advanced tuning techniques discussed in the steps below for: Optimizer Level Settings Abstract Plans The New QPTune Tool Lastly, if all the above fails, then consider the optimizer compatibility mode discussed below.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 84 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

7. Future Testing Considerations Keep in mind that there may be behavior changes in optgoals between ESDs. Consider re-visiting these testing strategies, should you run into any issues after applying future ESDs.

STEP 4.9.2: ADVANCED TUNING TECHNIQUES: OPTIMIZER LEVEL SETTINGS 1. Optimizer Level Settings ASE 15.5 introduced optimizer level configuration settings. These are dynamic settings that enable you to fine-tune ASEs standard optimizer goals. However, optimizer levels are advanced tuning mechanisms that should only be considered when the standard optimizer goals (allrows_dss, allrows_oltp and allrows_mix) do not meet your performance requirements. The current optimizer levels include the following settings: o ase_current: Enables all optimizer changes through the current release. o ase_default: Disables all optimizer changes since version 1503 ESD #1. o ase1503esd2: Enables all optimizer changes through version 15.0.3 ESD #2. o ase1503esd3: Enables all optimizer changes through version 15.0.3 ESD #3. 2. Purpose In most situations, the cost-based query plans generated by the standard three optimizer goals will be optimal. However, there are times when the query processor chooses the wrong index for optimal performance, or chooses a suboptimal join order. In these cases, you may need to explicitly control the access methods ASE uses to execute your query. To do so, ASE provides advanced tools and techniques for query analysis and optimization settings that are designed to let you understand why the query processor makes the choices that it does and how to control them as needed. These tools include the new Optimizer Levels which include the following settings: o ase_current: Enables all optimizer changes through the current release. o ase_default: Disables all optimizer changes since version 1503 ESD #1. o ase1503esd2: Enables all optimizer changes through version 15.0.3 ESD #2. o ase1503esd3: Enables all optimizer changes through version 15.0.3 ESD #3. 3. How to Use the Optimizer Level Settings By default, ASE does not enable the optimizer level settings; you must explicitly enable them at the server level using the sp_configure command or at the session level using the set command. Some optimizer criteria levels are specified by their CR numbers, while other optimizer levels are specified with descriptive names. Use the sp_options command to view the list of available options in the current release. This enables the optimization criteria for CR 545180: set CR545180 on.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 85 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


Here are some examples from the 15.7 Performance and Tuning Series Guide: o

Sybase ASE 15

_________________________________________________________________________________________________

At the session level: Use set plan optlevel to set the optimization level for the current session. This configures the session to use the all optimization changes up through the current version of Adaptive Server. For example: set plan optlevel ase_current For individual logins: Use sp_modifylogin to set the optimization level for logins. sp_modifylogin calls a user-created stored procedure that defines the optimization level. For example, if you create this stored procedure to enable the ase1503esd2 optimization level, but disable the optimization level for cr545180. For example:
create proc login_proc as set plan optlevel ase1503esd2 set cr545180 off

You may apply these optimization settings to any login. This applies the settings from login_proc to user joe:
sp_modifylogin joe, 'login script', login_proc

During a session with the set command: Use the set command to change the optimizer criteria level for the current session. You may find better performance by applying the optimizer criteria level at a fine grain level (perhaps at the query level). For example: set cr545180 off Across the server: Use the sp_configure optimizer level parameter to set the optimization level globally. This setting enables all optimizer changes up to the current version of Adaptive Server. For example:
sp_configure 'optimizer level', 0, 'ase_current'

Within an abstract plan: Use the optlevel abstract plan to set the optimizer level. This example enables all optimizer changes up to the current version of Adaptive Server for the current plan:
select name from sysdatabases plan '(use optlevel ase_current)'

To Determine Your Current Optimization Settings: Use the @@optlevel global variable to determine the current optimization level settings: select @@optlevel While applying these advanced optimizer settings, you may also want to asses the effects of a different join order, I/O size, or cache strategy. Some of the optimization options let you specify query processing or access strategy without costly reconfiguration. For more details on these settings, see "Chapter 7, Controlling Optimization, in the Performance and Tuning Series: Query Processing and Abstract Plans at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00743.1570/html/queryprocessing /X29769.htm

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 86 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

4. Where to Find More Information on Using Optimizer Levels Using optimizer levels involve advanced tuning techniques that are outside the scope of this document. A summary of these settings is provided below. "Chapter 7, Controlling Optimization, in the Performance and Tuning Series: Query Processing and Abstract Plans at: http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00743.1570/html/query processing/X29769.htm Also see: Adaptive Server Enterprise 15.7 > Performance and Tuning Series: Query Processing and Abstract Plans > Controlling Optimization at
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00743.1570/html/queryprocessing /queryprocessing185.htm

5. Other Optimizer Settings There are other less documented optimizer settings may be useful in very specific situations. For these situations, please contact Sybase Technical Support with a specific query issue for advice on when and how to use these settings.

STEP 4.9.3: ADVANCED TUNING TECHNIQUES: THE QPTUNE TOOL In ASE 15.0.3 ESD#1, Sybase introduced the Query Processing Tuning Tool (QP Tune Tool). This query analysis tool identifies and helps you tune poorly performing queries. A brief summary of this tool is provided below. Overview to the New Query Processing Tuning Tool There are two basic functions in QPTune, capturing missing statistics and query tuning: 1. Capturing missing statistics: The first step is the statistics advisory function. This will identify and optionally create missing statistics (those the optimizer would use if they were available). Statistics are absolutely critical to the ASE 15 optimizer choosing the correct plans. 2. Tuning: Once you have created all the necessary statistics for your queries, the next step is to identify and tune any slow performing queries. Simply identifying and creating these statistics resolves many performance problems. For those queries that are still performing inadequately, the QPTune tool can be used to capture query text plus a variety of metrics (such as elapsed time, logical or physical I/O). The most important aspect of this tool is its ability to capture and compare metrics across multiple runs. Then, the tool allows you to tune your query at either the server level or the query level. This part of the process is quick and provides valuable information. At the query level, the QPTune tool can tune subqueries. That is, it can identify and set the best optimizer goal for different portions of the query in order to maximize query performance.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 87 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

If you continue to experience slow performing queries that you are unable to resolve, then it may be time to contact Technical Support. Before doing so, the entire process will be easier and faster if you generate some basic trace information for Technical Support to review. Therefore, if you have narrowed a performance problem down to a particular stored procedure or query, please generate the information listed below, prior to contacting Sybase Technical Support. This information may not be all that is needed, but it will get the diagnostic effort off to a fast start: 1. Output from select @@version. 2. Copy of ASE's .cfg file. 3. Optdiag Statistics for each table involved in the query. For example:
unix% optdiag statistics <dbname>..<tablename> -Uxx Pxx > outputfile

4. sp_help for each table (or DDL for table & indices). 5. Run the problematic query after setting the following: set statistics time, io on set showplan on set option show_missing_stats on set option show_lio_costing on set option show_search_engine on Note: The sa_role is required for some of the options above. For stored procedures, you may need to drop and recreate the procedure first in order to generate output from some of the above trace commands.

Additional Documentation For a free course that includes training on the use of the QPT Tool, please do the following: Go to the Migrate to Adaptive Server Enterprise 15 web page at:
http://www.sybase.com/products/databasemanagement/adaptiveserverenterprise/migrate?htab=Tab+Holder&v tab=Technical+Resources&hid=80555&vid=80552

Scroll to the bottom of the page and find the Education Courses section. From here, find and click on the Free Course: ASE 15 Post-Migration Performance Tuning link. Enter your email address and get the course for free.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 88 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 4.9.4: ADVANCED TUNING: QUERY PROCESSING, ABSTRACT PLANS AND MORE There are a number of advanced tuning techniques beyond the scope of this document. These include the following: 1. ASE 15.7s Performance and Tuning Series: Abstract Plans For more details on using abstract plans, see the Adaptive Server Enterprise 15.7 > Performance and Tuning Series: Query Processing and Abstract Plans > Introduction to Abstract Plans at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00743.1570/html/queryprocessing /X14674.htm

2. ASE 15.7s Performance and Tuning Series: Query Processing For a more detailed discussion of a variety of advanced query tuning techniques, please see the ASE 15.7 Performance and Tuning Series: Query Processing and Abstract Plans at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00743.1570/html/queryprocessing /title.htm

3. Online Training For a free online training course go to: o http://www.sybase.com/products/databasemanagement/adaptiveserverenterprise/migrate o Click on: Technical Resources o Then click on: Free Course: ASE 15 Post-Migration Performance Tuning 4. The Complete ASE 15.7s Performance and Tuning Series Guides For a review of our complete listing of the ASE 15.7 Performance Tuning Series, please see the listing in Configuration and Tuning within the Assumptions and Limitations section at the beginning of this document.

STEP 4.9.5: THE OPTIMIZER COMPATIBILITY MODE: THE OPTION OF LAST RESORT 1. Overview In most cases, ASE 15.0 will perform better than prior versions, especially for complex queries. However, there may be cases where a query does not perform as well as it did prior to 15. For these cases, we introduced the Compatibility Mode for Query Processing in ASE 15.0.3 ESD#1. The compatibility mode is the optimizer goal of last resort. It will not work in all cases and its use precludes the use of the latest optimizer features as well as some additional new ASE 15 features. For more details on its use and restrictions, see the references and information below.
___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 89 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

For example, if you will not be using new features in ASE 15, the Compatibility Mode provides a way to generate and execute a query similar to ASE 12.5.4. The Compatibility Mode removes the application tuning process from the upgrade process until a later date. However, this will need to be addressed in order to use all of ASE 15 features or if this optimizer goal is deprecated (although currently, there are no plans to do so). 2. Using the Compatibility Mode Purpose: The optimizer compatibility mode provides an alternative optimizer strategy for ASE 15 that simulates the behavior of the ASE 12.5.4 optimizer. Syntax: o o Usage: o o The session setting will override the server-wide setting. Compatibility Mode is only available in ASE 15.0.3 ESD #1 and later releases. There are other restrictions on whether Compatibility Mode can be used, and at what level. See Table 3.1 in the 15.0.3 Migration Guide for specifics: http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00967.1503/htm l/MigrationGuide/title.htm SQL statements will be processed in one of three modes: Full Compatibility Mode: Optimized by an ASE 12.5.4-like optimizer, code generated into ASE 12.5.4 query plans and executed by the ASE 12.5.4 query execution engine. Restricted Compatibility Mode: Optimized by an ASE 12.5.4-like optimizer to generate an abstract query plan that will be processed by the ASE 15 optimizer and query execution engine. Default Mode: Optimized by the ASE 15 optimizer and executed by the ASE 15 query execution engine. o To see which mode was used to execute the previous query:
> select @@qpmode Values:

To enable Compatibility Mode Server-wide: (not usually recommended):


> sp_configure enable compatibility mode,[1 | 0]

To enable Compatibility Mode at the Session-level: (recommended):


> set compatibility_mode [on | off]

0 Non-optimizable query (create index, set rowcount, ) 1 Full Compatibility Mode. 2 Restricted Compatibility Mode. 3 Compatibility Mode could not be applied o Available trace flags: 441 - Allow all parameterized literals in Compatibility Mode.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 90 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x


446 - Skip Restricted Compatibility Mode. 477 - Prints the following :

Sybase ASE 15

_________________________________________________________________________________________________

Prints the reason why a query was not processed using Full Compatibility Mode. Prints whether a query was chosen for Full Compatibility Mode or not. Prints the query text (if available). Use trace flag 3604/3605 to direct the output. o Enabling compatibility mode may not always have an effect. There will be no effect on plans that are already cached.

3. Additional Documentation for Compatibility Mode For more information on running the query processor in compatibility mode, refer to the following documents: Using Compatibility Mode in ASE 15 at: http://www.sybase.com/detail?id=1063556&contentOnly=true Chapter 3: Running the Query Processor in Compatibility Mode, from the ASE 15.0.3 Migration Technology Guide at:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc00967.1503/html/MigrationGuide/ CBHHFIAG.htm

STEP 4.10: TEST ANY NEW FEATURES YOU WILL BE USING


If you have decided to implement any other new features, this is a good time to test them.

STEP 4.11: VERIFY APPLICATION CONSISTENCY AND STABILITY


In this step, you can verify the consistency of your application queries. That is, verify that the postupgrade result sets and output are the same as they were before the upgrade. This step can also be used to perform stress tests to verify that you applications are stable under highvolume workloads. Note: In most cases, this step can be done in parallel with the performance and tuning tests performed above if you capture the result sets and output for the queries being executed in the performance phases.

STEP 4.12: VERIFY BACKUP AND RECOVERY PROCEDURES

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 91 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

In this step, you should verify your backup and recovery procedures. Ensure that your backup procedures (manual and automatic) are using the correct Backup Server version for the ASE 15 version you have upgraded to.

STEP 4.13: STANDARDIZE YOUR UPGRADE PROCEDURES


In this last step, you will use all the information gathered in the previous tests phases to create a standardized set of upgrade procedures. This would include detailed procedures for each step, recovery procedures and the configuration settings identified in your test environment phase.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 92 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 5: UPGRADE STEPS FOR THE PRODUCTION ENVIRONMENT


Once you have completed the post-upgrade testing and tuning steps in your test environment, you are ready for the production upgrade. Your production upgrade steps will be based on your experiences in test. These steps will be similar to those contained in part 3 of this document, plus any modifications you made as a result of your upgrade in test. The biggest difference between the test and production upgrade is in the post-upgrade process. For production, you will use the tuning and configuration settings determined in your prior testing phase.

STEP 6: POST-UPGRADE STEPS FOR THE PRODUCTION ENVIRONMENT


The post-upgrade steps for your production environment will also based on your test environment experiences. These steps will consist of implementing the configuration procedures and settings you determined in your testing phase.

STEP 6.1: PERFORM POST-UPGRADE STEPS IN RELEASE BULLETIN AND COVER LETTER
Perform the Post-Installation tasks for your upgrade. These will depend on the type of upgrade method you are using.

STEP 6.2: RECREATE TABLE PARTITIONS


Repartition your tables using the procedures you established used in your test environment. These will depend on the type of partitioning strategy you are using.

STEP 6.3: REPLACE UPDATE STATISTICS COMMAND Replace the update statistics command with the update index statistics <tablename> as determined during
your testing phase.

STEP 6.4: RECREATE OPTIMIZER STATISTICS


Recreate your optimizer statistics using the procedures you established in your test environment.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 93 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 6.5: CONFIGURE THE NEW RESOURCE REQUIREMENTS FOR ASE 15


Implement the resource settings for ASE 15s new features as determined in your testing phase. STEP 6.5.1: CONFIGURE PROCEDURE CACHE Implement the procedure cache configuration determined in your testing phase. STEP 6.5.2: RE-SIZE TEMPDB Increase the size of tempdb as determined in your test phase. STEP 6.5.3: SEMANTIC PARTITIONING AND THE NUMBER OF OPEN PARTITIONS Implement the partition strategy and open partition setting as determined in your test phase. STEP 6.5.4: STATEMENT CACHE AND LITERAL AUTO-PARAMETERIZATION If you chose to do so, enable statement cache and literal auto-parameterization as determined in your test phase.

STEP 6.6: CONFIGURE THE NEW KERNEL RESOURCES


Implement the threaded kernel resource settings as determined in your test phase.

STEP 6.7: CONFIGURE THE NEW ASE 15 OPTIMIZER SETTINGS


Implement the optimizer goals and advanced tuning strategies as determined in your previous test phase. STEP 6.7.1: IMPLEMENT YOUR NEW OPTIMIZATION GOALS Implement the optimizer goals you established during your test phase. STEP 6.7.2: IMPLEMENT YOUR NEW OPTIMIZER-LEVEL SETTINGS Implement the optimizer levels you established in your test phase. STEP 6.7.3: IMPLEMENT ADVANCED TUNING SETTINGS (AS NEEDED) Implement any advance tuning settings you established in your previous test phase.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 94 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

STEP 6.8: PERFORM OTHER SOFTWARE UPGRADES AS NEEDED


Upgrade any other software required by your applications. This would include client, application and third-party software. Upgrade your version of OpenClient to 15.7 as determined in your test phase.

STEP 6.9: VERIFY DATABASE CONSISTENCY


If time allows, this would be a good time to verify your database consistency by running dbccs.

STEP 6.10: BACKUP YOUR UPGRADED USER AND MASTER DATABASES


Now that you have completed and verified your production upgrade, it is highly recommended that you backup your master and user databases. This ensures that you have a clean post-upgrade recovery point should you encounter any subsequent issues before the next backup. Without this backup, your next recovery point is your pre-upgraded backup. In most cases, this backup is no longer compatible with your upgraded server and recovery would involve downgrading or loading the pre-upgrade backup into your pre-upgrade ASE server (if you still have it). Congratulations, you have completed the upgrade.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 95 of 97 Last Update: May, 2012

ASE 15 Upgrade Checklist for Upgrading from ASE 12.x

Sybase ASE 15

_________________________________________________________________________________________________

SYBASE, INC. WORLDWIDE HEADQUARTERS ONE SYBASE DRIVE DUBLIN, CA 94568-7902 USA Tel: 1800 8 SYBASE www.sybase.com

Copyright 2012 Sybase, Inc. All rights reserved. Unpublished rights reserved under U.S. copyright laws. Sybase, and the Sybase logo are trademarks of Sybase, Inc. or its subsidiaries. All other trademarks are the property of their respective owners. indicates registration in the United States. Specifications are subject to change without notice.

___________________________________________________________________________________________________________ ASE 15 Upgrade Checklist for ASE 12.X v3.0 Page 96 of 97 Last Update: May, 2012

You might also like