Azure Managed Instance Migration Checklist for Oracle DBAs
Two weeks before our planned Azure migration cutover, the project manager asked me, "We've tested the migration three times in dev. What could possibly go wrong in production?"
I showed him my checklist. Sixty-three items. He thought I was being overcautious. Until we hit production and discovered our application connection strings were hardcoded with Oracle-specific syntax that Azure SQL Managed Instance didn't support. The migration succeeded, but the application couldn't connect.
That's when he understood: migration isn't just moving data. It's validating every assumption about how your application interacts with the database.
This checklist represents lessons from five Azure Managed Instance migrations, including two that required emergency rollbacks. If you're an Oracle DBA planning an Azure migration, this is the checklist I wish I had on my first project.
- Pre-Migration Assessment: What You Must Know Before Starting
- Azure Managed Instance Sizing and Configuration
- Database Schema Compatibility Analysis
- Application Connection String Validation
- Migration Execution Checklist
- Post-Migration Validation Steps
- Rollback Planning and Testing
- Performance Baseline Comparison
- FAQ
- Related Reading from Real Production Systems
1. Pre-Migration Assessment: What You Must Know Before Starting
The biggest migration failures happen before the migration even starts. They happen when teams skip proper assessment and discover fundamental incompatibilities after they've already committed to the migration timeline.
Current Oracle Database Inventory
Before touching Azure, document what you currently have:
| Assessment Item | What to Check | Why It Matters |
|---|---|---|
| Oracle Version | SELECT * FROM v$version | Determines compatibility path to Azure SQL |
| Database Size | SUM of data files + temp + logs | Affects migration method and Azure instance sizing |
| Active Connections | Peak concurrent sessions | Azure Managed Instance has connection limits per tier |
| Transaction Volume | Transactions per second | Determines required Azure compute tier |
Critical Oracle Features Check
Azure SQL Managed Instance does NOT support these Oracle features. If you use them, you need migration strategies:
- ❌ Oracle packages - No direct equivalent, must rewrite as stored procedures
- ❌ Database links (DBLink) - Use linked servers or elastic queries instead
- ❌ Materialized views - Convert to indexed views or scheduled refresh
- ❌ Oracle-specific datatypes - RAW, LONG, BFILE need conversion
- ❌ Autonomous transactions - No direct support in Azure SQL
What you do with this output: Each non-zero count represents a migration challenge. Zero packages? Easy. 200 packages? Plan significant refactoring work.
2. Azure Managed Instance Sizing and Configuration
The most common sizing mistake is choosing Azure instance tiers based on Oracle database size. That's wrong. Size based on workload characteristics, not data volume.
Azure Managed Instance Tiers
| Tier | Best For | vCores | Storage |
|---|---|---|---|
| General Purpose | Most Oracle workloads | 4-80 vCores | Up to 16TB |
| Business Critical | High IOPS, low latency | 4-80 vCores | Up to 4TB |
Sizing Decision Tree
Choose General Purpose if:
- ✅ IOPS requirements under 5,000
- ✅ Acceptable latency is 5-10ms
- ✅ Cost optimization is priority
- ✅ Read replicas not required immediately
Choose Business Critical if:
- ✅ IOPS requirements exceed 10,000
- ✅ Latency must be under 2ms
- ✅ Built-in read replicas needed
- ✅ HA/DR is critical
Configuration Checklist
License considerations: If you have Oracle licenses with Software Assurance, use LicenseType "BasePrice" for Azure Hybrid Benefit savings (up to 55% cost reduction).
3. Database Schema Compatibility Analysis
Schema conversion is where most migrations hit unexpected delays. Oracle and Azure SQL use fundamentally different approaches to identical concepts.
Datatype Mapping
| Oracle Type | Azure SQL Type | Notes |
|---|---|---|
| VARCHAR2 | VARCHAR / NVARCHAR | Max 4000 → 8000 chars |
| NUMBER | DECIMAL / NUMERIC | Precision mapping required |
| DATE | DATETIME2 | Different precision |
| CLOB | VARCHAR(MAX) | No LOB locators |
| BLOB | VARBINARY(MAX) | Storage differences |
Schema Conversion Script
What this does: Converts Oracle DDL to Azure SQL compatible syntax. Review manually before execution - automated conversion catches 80% of issues, the other 20% require human judgment.
4. Application Connection String Validation
This is the step that catches teams off guard. Your application connects to Oracle using TNS or JDBC. Azure SQL Managed Instance uses completely different connection syntax.
Connection String Changes
Oracle TNS (Old):
Azure SQL Managed Instance (New):
Application Code Changes Required
Beyond connection strings, these code patterns break when moving from Oracle to Azure SQL:
- ❌ Oracle sequences - Replace with IDENTITY columns or SEQUENCE objects
- ❌ Dual table queries - Remove "FROM DUAL", not needed in Azure SQL
- ❌ ROWNUM - Replace with OFFSET/FETCH or ROW_NUMBER()
- ❌ (+) outer join syntax - Rewrite using ANSI JOIN syntax
- ❌ NVL function - Replace with ISNULL or COALESCE
5. Migration Execution Checklist
This is the actual migration day checklist. Print it. Check off each item as you complete it. Skipping steps causes production failures.
Pre-Migration (T-4 Hours)
- ✅ Notify all stakeholders of migration window start time
- ✅ Disable all automated jobs in Oracle database
- ✅ Take final full backup of Oracle database
- ✅ Verify backup completes successfully
- ✅ Document current connection count (baseline for validation)
- ✅ Capture Oracle AWR report for last 24 hours
Migration Execution (T-0)
- ✅ Put Oracle database in read-only mode
- ✅ Verify no active transactions remain
- ✅ Start Azure Database Migration Service (DMS)
- ✅ Monitor DMS progress (log into Azure Portal)
- ✅ Document any migration warnings or errors
Initial Data Validation (T+1 Hour)
- ✅ Verify row counts match between Oracle and Azure
- ✅ Check for failed object migrations
- ✅ Validate primary keys and indexes exist
- ✅ Test database connectivity from application server
- ✅ Run data validation queries (checksums, min/max values)
6. Post-Migration Validation Steps
Migration success is not "data moved." Migration success is "application functions identically to before with acceptable performance."
Functional Validation
| Test Category | What to Test | Pass Criteria |
|---|---|---|
| Data Integrity | Row counts, checksums, key values | 100% match with Oracle |
| Application Login | Users can authenticate | All test users successful |
| CRUD Operations | Create, Read, Update, Delete | All functions work |
| Reporting | Reports generate correctly | Output matches Oracle baseline |
| Batch Jobs | Scheduled processes run | Complete within SLA |
Performance Validation
Performance in Azure will NOT match Oracle exactly. Azure SQL Managed Instance uses different execution plans, different caching, different I/O patterns. Expect variance, but within acceptable bounds.
- ✅ Compare key transaction response times (should be within 20% of Oracle baseline)
- ✅ Verify no query timeout errors
- ✅ Check for blocking or deadlocks
- ✅ Monitor Azure SQL DTU/vCore utilization
- ✅ Review slow query log for optimization candidates
7. Rollback Planning and Testing
Every migration plan must include rollback procedures. The question is not "will we need to roll back?" but "how quickly can we roll back if we need to?"
Rollback Decision Criteria
Immediate rollback if:
- ❌ Application cannot connect to Azure SQL Managed Instance
- ❌ Critical business function is broken
- ❌ Data integrity issues discovered (row counts don't match)
- ❌ Performance degradation exceeds 50% of baseline
Rollback procedure:
- Announce rollback to all stakeholders
- Put Azure SQL in read-only mode (prevent new data)
- Restore Oracle database from backup
- Revert application connection strings to Oracle
- Verify Oracle database is accepting connections
- Document what went wrong for post-mortem
8. Performance Baseline Comparison
You cannot optimize what you don't measure. Before migration, establish Oracle performance baselines. After migration, compare Azure performance to these baselines.
Key Metrics to Baseline
| Metric | Oracle Baseline | Azure Target |
|---|---|---|
| Average Query Time | Document from AWR | Within 20% of Oracle |
| Transactions/Second | Peak and average | Match or exceed Oracle |
| CPU Utilization | Average and peak | Under 80% sustained |
| IO Latency | Read and write ms | Under 10ms (General Purpose) |
No comments:
Post a Comment