Sybase Installation Issues

Sybase can be installed on Unix, Linux, Apple OS-X and Windows NT/2000/XP. Like Oracle, Sybase makes a development/evaluation version available free of charge for many platforms. Do a web search for '<OS> sybase download' to find a version suitable for your needs.

Sybase is far leaner and meaner than Oracle. It will run on Linux in 128MB of RAM and has a footprint on disk of around 250MB, although you should look to double these figures for any serious development. This makes it much easier to deploy on legacy machinery although you should always make the case for the best hardware for any production work - old machines don't break down too often but when they do they are often beyond resuscitation!

When specifying new hardware, the usual process of sizing both the production and development databases should be gone through but remember that hardware is now so cheap that, if in any doubt, you should over-estimate your sizes. It's much better to have unused storage or RAM if only because, in all but a very few environments, it won't remain unused for long.


RTFM


Before any installation, make sure you have the latest copy of the installation guide. If you're doing a download installation a link to this will generally be present on the download page. Sybase documentation is usually pretty clear and easy to follow so break the habits of a lifetime and read the manual!

The most important instruction is that, in order to install or maintain Sybase, you be logged in as the 'sybase' user and this user MUSTMUST have privileges from the root directory downwards. It go/ddes without saying that this user must have a secure password because it will have nearly as many privileges as 'root'.

The other most important instruction is that you must set your shared memory to at least 64MB. The default on most Linux systems is 32MB and if you leave it at that, you'll have real problems when you come to configure the servers (see below). The best way to do this is to add the following line to /etc/rc.d/rc.local...

       /sbin/sysctl -w kernel.shmmax=67108864

Remember to restart Linux after making this change and before starting the installation. It's probably a good idea to do '/sbin/sysctl kernel.shmmax' from a shell prompt and make sure you get the reply 'kernel.shmmax = 67108864' or whatever you set it to.


Getting started.


Taking the Linux installation as an example, once you have unzipped and untarred the download file, you'll have a file named 'setup', a buglist text file, a .pdf file, a media.inf file and various directories. Typing './setup' will boot the Java virtual machine and you're in to the GUI installation window (provided courtesy of InstallShield).


Gotcha!

The first gotcha that may catch you is when it asks where to install the product. The default is /opt/sybase and if that doesn't exist it will offer to create it. The problem is, /opt is generally owned by root and nothing else has write permissions by default. So if you accept the offer, you'll get a message telling you, correctly, that '/opt/sybase cannot be written'.

There are two options here. One is to change the permissions on /opt to allow the sybase user to write to it or, alternatively, to su root, create /opt/sybase and then change its permissions to 7775 or something like that...


Installation and Configuration


Once the directory is created, you can choose from typical, full or custom installation. I'll go out on a limb here and suggest that in most cases 'typical' is the route to go, inasmuch as it's the default. Once you've made your choice, you're shown what will be installed. If you accept that, the installation commences. If all goes well, as some disk activity you'll be told the installation has completed successfully.

With the installation completed, you're invited to configure the servers that have been created. The default is to configure all the servers (then main Adaptive Server, plus the Backup, Monitor and XP servers. You're also given the chance to customise the configuration for each of these. Ignoring this last is a good idea as the default figures are fine for most uses.


Dealing with Failures


What do you do if the configuration fails and Sybase can't start? Well, the commonest reason is that you forgot to set the shared memory to at least 64MB (see above). Without that, the server is throttled and simply fails to run in, although it takes a long time to decide it's going to die.

To fix this, set up the shared memory correctly in rc.local (typically /etc/rc.d/rc.local).

Add the following line...

        /sbin/sysctl -w kernel.shmmax=67108864

...then save the changes and restart your machine. This should clear the problem. It's worth while re-starting the installation from scratch if you get caught out this way.


Find out more by searching Google here...

Google