I am new to SQL Anywhere having worked with SQL Server only.
What is the best practice for upgrading versions "in place" ie, upgrade an existing production server?
I've had a read of the Sybase documentation on upgrading version 10 databases and i'm a bit confused. It mentions that you need to use "SQL Anywhere 11 >> Sybase Central". Does this mean that you need to install Anywhere 11 first and then run the upgrade wizard? Will installing Anywhere 11 on a server with anywhere 10 overwrite it?
asked 23 Apr '10, 05:35
Yes, you need to install SQL Anywhere 11 on whatever machine you intend to use to upgrade a database to version 11 and run it.
No, it won't interfere with SQL Anywhere 10... UNLESS you are relying on the system PATH to find Version 10 utilities like dbvalid.exe. If you use command line scripts and you want multiple versions to coexist, it helps to be explicit about paths using %SQLANY10% and %SQLANY11% (see example below).
You can use the Sybase Central wizard to do an upgrade, or you can use command line execution (see example below).
You can get some experience upgrading by experimenting with the Version 10 demo database (see example below), but before doing it in production you must read all of the relevant "Behavior Changes" sections in the Version 11 help http://dcx.sybase.com/1101en/sachanges_en11/sachanges_en11.html
If you are using 10.0.0, start with the "Behavior Changes" sections in What's new in version 10.0.1.
Here's an example of command-line upgrading from Version 10 to 11:
REM If you're a command-line kinda guy, here is my template Windows REM batch file run_dbunload_upgrade_v10_to_v11.bat. It does the REM unload-reload-all-in-one-dbunload-step, then starts dbeng11 REM and dbisql so you can make sure the new database is up and running. REM Be sure to stop *all* database engines on the computer you're using, REM before starting the upgrade. REM dbunload... REM -an ... where to put new database REM -ap ... new database page size REM -c ... old database startup connection string REM -o ... where to put unload console display text file REM -v verbose mode for console display PAUSE MAKE SURE YOU DO NOT HAVE ANY ENGINES RUNNING. "%SQLANY11%\bin32\dbunload.exe"^ -an "C:\temp\demo11.db"^ -ap 4096^ -c "DBF=C:\Documents and Settings\All Users\Documents\SQL Anywhere 10\Samples\demo.db;UID=dba;PWD=sql"^ -o "C:\temp\dbunload_log_demo.txt"^ -v PAUSE dbunload/reload done... REM dbeng11... REM -c ... initial RAM cache size REM -o ... where to put server console display text file REM -os ... when to rename and restart server console display text file REM demo11.db new database to start "%SQLANY11%\bin32\dbspawn.exe"^ -f "%SQLANY11%\bin32\dbeng11.exe"^ -o "C:\temp\dbeng11_log_demo11.txt"^ "C:\temp\demo11.db" PAUSE dbeng11 started... REM dbisql... REM -c ... new database connection string "%SQLANY11%\bin32\dbisql.com"^ -c "ENG=demo11;DBN=demo11;UID=dba;PWD=sql" PAUSE All done...
answered 23 Apr '10, 09:31