Search This Blog

Showing posts with label sybase. Show all posts
Showing posts with label sybase. Show all posts

Friday, February 21, 2020

sybase shutdown commands and usage

This article shows us the various shutdown methods of ASE database from isql prompt

1. Normal Shutdown of ASE DB:  Adaptive Server will be shut down from which the shutdown command is issued
Usage
>shutdown
>go

2. Shutdown with no wait:  Adaptive Server will be shut down immediately
Usage
>shutdown with nowait
>go

3. shutdown SYB_BACKUP: Shutdown local backup server
usage
>shutdown SYB_BACKUP
>go

4. shutdown REM_BACKUP: Shutdown remote server backup
usage
>shutdown REM_BACKUP
>go

5. shutdown cluster: Shuts down the current cluster
usage
>shutdown cluster
>go

6. shutdown ase1: Instance “ase1” will be shut down leaving the cluster running
usage
>shutdown ase1
>go

Restore and recover ASE databse



This article helps us with the procedure of Restore and Recovery of Sybase ASE database

Before Loading (restore) and recover, ensure that no-one is connected to DB using below command

 isql -Usa -STST -w300 -P -X

> (Provide password)

>sp_who

>go


Once you confirm that anyone is not connected to DB, then start loading the database
Load database from "


example

>Load database TST from "/Dumpdir/TST_bkp1.dmp"
>stripe on "/Dumpdir/TST_bkp2.dmp"
>stripe on "/Dumpdir/TST_bkp3.dmp"
>go


once database is loaded, we've two options here


1. Bring the database online

2. Recover the database.

As i might wish to means the recover option also, we'll accompany second option

recover the database using below command


>load transaction TST from "/Dumpdir/TST.trn
>with until time= 'January 16, 2019 10:32 am
>go


Up on the recovery of database, bring the database online using below command


>online database TST
>go


your database in now online.