Hi,

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?

Thanks,

Warren.

asked 23 Apr '10, 05:35

warren's gravatar image

warren
146455
accept rate: 0%


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...
permanent link

answered 23 Apr '10, 09:31

Breck%20Carter's gravatar image

Breck Carter
32.5k5417261050
accept rate: 20%

Just to add to Breck's verbose response: It's very common to have several SQL Anywhere main versions installed on the same box. This is really easy as each version is installed in its own folder by default. So you might have "C:Program FilesSQL Anywhere 10" and "C:Program FilesSQL Anywhere 11" and so on. The database engine has a different name in each version, i.e. dbeng10.exe (or dbsrv10.exe), dbeng11.exe etc. - The one caveat Breck hints at are the command line tools as they are named identical in each release. Therefore it's important to make sure the appropriate path is used here.

(23 Apr '10, 21:36) Volker Barth

Great, thanks for the advice guys!

(27 Apr '10, 00:44) warren
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×143
×119
×62

question asked: 23 Apr '10, 05:35

question was seen: 3,470 times

last updated: 23 Apr '10, 09:31