Sybase Skills Collection FAQ

xiaoxiao2021-03-06  104

Sybase Skills Collection FAQBY Yang Ye

Q.

How do I solve one of the issues that the database is marked as "Suspect" (general solution)?

A.

Phenomenon: Error 926

Severity Level 14

Error Message Text

Database 'XX' Cannot Be Opened - It Has Been Marked Suspect by Recover Explanation

(1) When you use the transact_sql command to operate the data of this database, this is a serious error, if

You have to use the data of this database, you must correct this error.

(2) Start the Backup Server, the backup Master database

1> DUMP DATABASE MASTER TO "/usr/sybase/master_dump.19991201"

2> Go

(3) Log in to SQL Server with isql, and must use the SA account (this article as an example of PUBS2 database)

1> sp_configure "allow updates", 1

2> Go

1> Begin TRAN

2> Go

1> Update Master..sysdatabases

2> set status = -32768

3> Where name = "pubs2"

4> Go

If you get (1 row affed), then

1> Commit

2> Go

otherwise

1> Rollback

2> Go

(4.1) If condition allows, BCP OUT user data or DUMP user database

(5.1) When you restart SQL Server, there is another SA account to register to SQL Server.

1> Begin TRAN

2> Go

1> Update Master..sysdatabases

2> set status = 0

3> Where name = "pubs2"

4> Go

If you get (1 row affed), then

1> Commit

2> Go

otherwise

1> Rollback

2> Go

1> sp_configure "allow updates", 0

2> Go

(4) If your database has dboption (such as "SELECT INTO", "Trunc Log On Chkpt", you need to reset

These options ..

(5) Run the DBCC command to check the consistency of the database

Isql -usa -p -i dbcc.sql -o dbcc.out

DBCC.SQL file example:

DBCC CHECKDB ("Pubs2")

Go

DBCC Checkalloc ("Pubs2")

Go

DBCC Checkcatalog ("Pubs2")

Go

GREP MSG DBCC.out

6) Backup User Database

1> DUMP DATABASE PUBS2 On "/usr/sybase/pubs2_dump.19991201"

2> Go

Q.

How to solve the database that the database is marked as "SUSPECT" (the solution when the database device is corrupted)?

A.

Phenomenon: There are several reasons for 926 errors. This article discusses when the initialization of database devices (device file loss or file read and write permission)

Incorrect), the database recovery failed, and the 926 error occurred.

(1) Please restore database devices and read and write permissions first.

(2) Start Backup Server, Backup Master Database 1> DUMP DATABASE MASTER TO "/usr/sybase/master_dump.19991201"

2> Go

3) Log in to SQL Server with isql, you must use the SA account (this article is taken as an example of PUBS2 database)

1> sp_configure "allow updates", 1

2> Go

1> Begin TRAN

2> Go

1> Update Master..sysdatabases

2> set status = status - 256

3> Where name = "pubs2"

4> Go

If you get (1 row affed), then

1> Commit

2> Go

otherwise

1> Rollback

2> Go

(4) Restart SQL Server, run the DBCC command to check the consistency editing of the database to generate dbcc.sql files:

DBCC CHECKDB ("Pubs2")

Go

DBCC Checkalloc ("Pubs2")

Go

DBCC Checkcatalog ("Pubs2")

Go

Isql -usa -p -i dbcc.sql -o dbcc.out

GREP MSG DBCC.out

(5) Backup User Database

1> DUMP DATABASE PUBS2 On "/usr/sybase/pubs2_dump.19991201"

2> Go

Q.

How to solve an error of ASE11.5 loading or backup database 3230?

A.

After deleting logical devices with sp_dropdevice or Sybase Central, do not restart the server, do not recover the virtual device number, reuse it to establish

Equipment, new database. At this time, Dump & Load database will be 3230 errors. This is the BUG of ASE11.5, which does not restart the server in the past.

Old virtual device number cannot be used, now the server does not prompt the error. But the Dump & Load database will appear 3230 errors.

The solution is to restart the server, and the 3230 error will disappear.

Q.

How to delete a bad user database? (Take PUBS2 as an example)

A.

When using DROP DATABASE that cannot be deleted, use the method shown herein can be deleted.

(1) Using ISQL to register SQL Server with SA

(2) Set the allowable modification system table

1> sp_configure "allow updates", 1

2> Go

(3) Place the user database to be deleted as "Suspect" status

1> Use master

2> Go

1> Begin TRAN

2> Go

1> Update sysdatabases set status = 256

2> where name = "pubs2"

3> Go

If you get (1 row affed), then

1> Commit

2> Go

otherwise

1> Rollback

2> Go

(4) Restart the Server and register with SA with ISQL.

(5) Delete the database

1> DBCC DBREPAIR (Pubs2, Dropdb)

2> Go

(6) Recovery allows modification system table

1> sp_configure "allow updates", 0

2> Go

(7) End

Q.

How to modify the IP address changed the interfaces file?

A.

After installing the Machine IP address of Sybase Adapive Server changes, you should modify the Interfaces file and related settings.

If you use the machine name instead of the interface, it is not necessary to change. However, if the client connection server is used by the server's IP address instead of the machine name, then the client needs to modify the IP address of the junction server ..

If you use an IP address in the interfaces file, you need to modify the part of the Interfaces file and address.

You can modify using DSCP or DSEDIT. If the client connection server is using the address of the server instead of the machine name, then

The household needs to be modified.

Q.

How do I check the consistency of data in the database?

A.

The database consistency check (DBCC) provides some commands to check the logic and physical consistency of the database. DBCC has two main functions:

Use checkStorage or CheckTable and checkdb to check the page chain and data pointers at the top of the page.

Use CheckStorage, Checkalloc, or Checkverify, TableAlloc, and Indexalloc check page assignment.

In the following cases, DBCC commands are required:

As part of the daily maintenance of the database, the integrity of the internal structure of the database determines that SA or DBO periodically runs DBCC check.

After the system error is wrong, it is determined whether the database is damaged.

Make sure the backup integrity is backed up before the database is backed up.

If you suspect that the database is damaged, for example, using a table, you can use DBCC to determine other databases.

Whether the table is also damaged.

Below is a simple usage of DBCC:

DBCC CheckTable (Table_name)

Check the specified table, check if the index and the data page are correct, the index is properly sorted, all pointers are consistent, data per page

Whether the information is reasonable, whether the page offset is reasonable.

DBCC CHECKDB (Database_name)

Do all the tables of the specified database and check the same case as CheckTable.

DBCC Checkalloc (Database_name, FIX | NOFIX)

Check the specified database, all pages are properly assigned, whether the page assigned is not used. When using the "fix" option,

The problematic page is automatically fixed while checking the database. (If the amount of database data is large, the process will last for a long time.)

DBCC TableAlloc (Table_name, FIX | NOFIX)

Check the specified table, all pages are properly assigned, whether the page assigned is not used. It is the narrowed version of Checkalloc.

Make an integrity check for the specified table. When using the "Fix" option, you will automatically fix the page in the data table while checking the data table.

surface.

Other options for the above commands and detailed use of Checkstorage, Checkverify, Indexalloc

Forward, please refer to the command manual.

Example 1: Unix platform Check the consistency of the PUBS2 database

Single user mode launches Server:

$ Sybase / Install StartServer -f Run_Server_name -m

Vi dbcc_db.sql

Use master

Go

Sp_dboption Pubs2, "Single User", True

Go

USE PUBS2

Go

Checkpoint

Go

DBCC CHECKDB (PUBS2)

Go

DBCC Checkalloc (Pubs2, FIX)

Go

DBCC Checkcatalog (PUBS2)

Go

Use master

Go

SP_DBOPTION PUBS2, "Single User", False

Go

USE PUBS2

Go

Checkpoint

Go

quit

Go

ISQL -USA -PXXXXXX -SSYBASE DBCC_DB.out

GREP MSG DBCC_DB.out

Example 2: UNIX platform Check the consistency of the Titles table in the Pubs2 database VI DBCC_TABLE.SQL

USE PUBS2

Go

DBCC CheckTable (Titles)

Go

DBCC TableAlloc (titles)

Go

Isql -usa -pxxxxxx -ssybase dbcc_table.out

GREP MSG DBCC_TABLE.OUT

Q.

How to uninstall Sybase Server in Windows NT?

A.

Close Adaptive Server.

Change Adaptive Server in Windows NT Services to manually

Restart Windows NT Server

Run Sybedt32 Modify the Registry, delete the following:

// HKEY_LOCAL_MACHINE / SOFTWARE / SYBASE / SERVER /

// HKEY_LOCAL_MACHINE / SOFTWARE / SYBASE / Server / _BS

// HKEY_LOCAL_MACHINE / SOFTWARE / SYBASE / Server /_HS

// HKEY_LOCAL_MACHINE / SOFTWARE / SYBASE / Server /_MS

Under the following structure of the registry:

// HKEY_LOCAL_MACHINE / SYSTEM / CURRENTCONTROLSET / CONTROL / Session Manager / Environment

Delete DSListen, DSQuery, Sybase, and modify lib, incrude, Path to remove Sybase related directories

Delete the following registration key value:

// HKEY_LOCAL_MACHINE / SYSTEM / CURRENTCONTROLSET / SERVICES

Sybsql_

SYBXPS__XP

Sybbck__bs

Sybmon__ms

Sybhis__hs

Restart Windows NT Server

Use Start | Control Panel | Settings | Services to confirm Sybase already uninstalled

Delete database device files used by Sybase Server and Sybase system files

Q.

How do I change the SQL Server name (on the UNIX, OpenVMS platform)?

A.

There is no specific function or stored procedure in the Sybase product to change the name of SQL Server / ASE Server, so only

The work modifies some parameters or configurations to complete this task.

You need to modify the interfaces file; change the run_server_name file name, and modify its content, for example: -s (unix), / server

(OpenVMS) The parameter (SERVER name); change the configuration file name; change the ERRORLOG file name (if needed);

If the Server name is added in the table sysservers, you need to change 'srvname', 'srvnetName' columns, and sp_dropserver can be used.

The sp_addserver stored procedure is implemented.

In the OpenVMS system, you have to modify the logical name of DSListen in the run_server_name file, and in the use of StartServer

Parameters followed by / servers. Then, restart SQL / ASE Server. Confirm that DSQuery, DSListen environment variables have been changed to

Need content.

Also, if SQL / ASE Server is set to a remote server, you have to modify the system table related to this Server Sysservers.

Fields and Interfaces files.

In theory, for example, a configuration file, a run script, an ERRORLOG file does not need to specify a Server name (but usually specifying the Server name). In the Run Startup script, you want to specify the Server name.

You can complete this task according to the following outline:

If the Server name is added to the table sysservers, use sp_dropserver to delete.

Shut Down Server

Edit Interfaces file

Change the RUN_SERVER_NAME file name and modify the parameters followed by the content, -s (UNIX), / Server (OpenVMS) (Server

name)

Change ERRORLOG file name (if needed)

Modify DSQuery, DSListen environment variable (if needed)

Change the configuration file name (server_name.cfg, server_name.bak, server_name.name), starting START in the Sybase installation path

Server

Re-add Server using sp_addserver (if needed)

If Server is used as a remote server, you also need to delete and re-add.

Q.

How to configure SQL Server to do remote backup?

A.

On the local machine:

(1). Local SQL Server and Backup Server can run.

(2). In the local Interfaces file, add the backup server name on the remote machine, just "QUARY" line, not allowed

Use aliases.

Please note: Each Backup Server on the network must have a unique name, this name must be in the interfaces file, use

Households can check it by viewing the server, its options are -s (unix) or / server (VMS).

(3). Execute the stored procedure SP-Helpserver Syb_backup confirms that the local backup Server has the correct network name. Remote Backup

Server does not necessarily have a record in the system table SYSERVERS, but it is easy to test.

Note: Do not modify SYB_BACKUP to point to the remote backup Server name.

On the remote machine:

(1) Confirm that the remote Backup Server is running.

(2) Confirm that the remote backup Server has different network names with local backup Server.

Please note: In the interfaces file on the remote machine, you must include a definition record of remote Backup Server, but it does not need other

BACKUP Server definition.

Q.

How to configure SQL Server 11 so that the fast BCP has better performance?

A.

There are several ways to improve the performance of BCP:

(1) Increase the extent allocation. By default, 2 to 31 extensions are prepared. In a BCP batch, unused

The pre-distribution extension is released. To get the best BCP performance, set BCP batch size and "Number of Preallocated Extens"

Pre-allocate the number of extensions to eliminate spatial re-release. Use sp_config number of pre-allocated extences, NN

Union 10: buildmaster -ycpreallocext = nn

(2) Sub-governing table

(3) Configure the buffer policy for the OAM page to reduce the physical read of the OAM (Object Allocation Map) page.

(4) Configure a buffer pool of large I / O, such as 16K: SP-Poolconfig Default, "16K" (5) use the -A mark, increase the network package size:

BCP -A 16384

Q.

How to transplant SQL / ASE Server to the same platform (same operating system)?

A.

N1 All the steps listed here do not need to be performed in order, just indicate the order in which this task is successfully completed in the experiment.

N2 Sybase prompts you to keep it until today's ISQL script, including establishing login, create database, disk init, and more. use

These scripts will make you complete this task easier. These scripts can also be regenerated by the content of the system table in Master, possibly

Will be cumbersome.

The key to the success of N3 is the same as the field of the system table in the target system. The field of the corresponding system table in the source system. Especially: syslogins

The 'SUID and' DBID 'in sysdatabases; SegMap, Lstart, and Size of all rows in sysusages.

Do the following on the data source system:

Data consistency check (DBCC) for all databases, and reserve all user databases.

Keep the contents of the data table in the Master database, use the select * from table_name command:

Sysdevices, Sysusages, Sysdatabases

Syslogins, Sysservers, SyssVRROLES, SYSLOGINROLES, SYSREMOTELOGINS

For the sysusages table, use the following command:

Select * from sysusages Order by DBID, LSTART

For the sysdatabase table, use the following command:

Select * from sysdatabases Order by dbid

Use the system table content listed in (2) using the BCP command.

UNIX: BCP MASTER..TABLE_NAME OUT FILE_NAME -USA -PSA_Password -C

VMS: BCP MASTER..TABLE_NAME OUT FILE_NAME / UserName = "sa" / sa_password / char

Keep the results of the sp_configure command

Do the following on the target system:

Install and configure new SQL Server and Backup Server.

Confirm that the specified Master, Tempdb, SybsystemProcs size is at least equal to the size of the corresponding database on the data source system, and confirm

The same language module as the data source system and the character set.

Start SQL Server so that it is working properly. Refer to the configuration of the data source system (the execution result reserved in 4) Modify the target system

The same is the same, and confirm that the 'Device' parameter value is at least equal to the source system.

In the model, the SybsystemProcs database is arbitrarily executed to determine the database work is normal. Please do not add users, roles, repair

Change the system table.

Restart SQL Server is valid for testing new configuration.

Do the following:

1> Use master

2> Go

1> sp_configure "allow updates", 1

2> Go

Restart SQL Server.

Use the system table content listed in (2) using the BCP command.

UNIX: BCP MASTER..TABLE_NAME IN FILE_NAME-ISA -PSA_PASSWORD -B 1-CVMS: BCP MASTER..TABLE_NAME IN File_NAME / User = "sa" / sa_password / char / batCH = 1

Building a database device, at least equal to the size of the corresponding database in the source system.

Run the script for Create Database and ALTER DATABASE (or use the command line). Note CREATE, Alter order to be with the source system

CREATE, Alter order, and the same parameters as they are used. After completing, please contact SysDatabases in the target system after completion.

Sysusages, make it exactly the same, otherwise you have to do 12 steps. (Please refer to N3 prompts) Note:

The segmap field in 10.0 and later will be modified after doing the database LOAD.

When determining the same DBID, you should use the same order as Create, ALTER in the source system, and create Create in the target system.

Alter, and use the same parameter value. And this requirement is merely when some Objects in the database is referred to in different databases.

Objects will only adopt. In addition, this requirement is only used in each database, and the result of the completion will make the sysusages table

Segment, lastart, size field, or Fragment is the same as the value in the source system. Run the following command to lose with the original system

Comparison:

Select * from sysusages Order by LStart

LOAD user database and perform DBCC detection.

Do the following:

1> sp_configure "allow updates", 0

2> Go

Restart SQL Server.

Backup Master library and user database.

Q.

How to do Rebuild Master (without a backup master library, use the command disk reinit, disk refit)?

A.

Tip 1:

If possible, before performing this task, please do the backup of the operating system level Sybase Devices. Unix operating system can be used

Let "DD". Because if Disk Reinit uses an error message, then, it will not make up after the Disk Refit is executed.

error. If there is a backup file with Sybase Devices, we will give us a chance to make up. For example: when Disk Reinit

Used too little size value, we can also recover the Sybase Devices file, re-do Disk Reint, Disk Refit.

Tip 2:

When using the disk reinit command, the Sybase Device will be overwritten (see the following syntax), and the security method is that the size value uses nude

The largest size of the area or system file. If you are using a UNIX naked partition, even if you can't confirm that the Sybase Device initial size is not

It is the maximum value to use the maximum value of the naked partition size.

step:

Get information about Sybase Device that will be restored.

This information is used to rebuild sysdevices, sysusages, and sysdatabases.

Get the device name of the Sybase Device from the ERROR log Server startup information.

The maximum size of the naked partition or system file is used as Sybase Device

size.

The above information can also be obtained by the content of the nearest Sysdevices system table. in case

There is a question about this information, or the above method is relatively secure. Make the operating system level Sybase Device Reserve. UNIX operating system, implements the "DD" command.

Configure a new ASE Server. This new master will be used in later steps.

If necessary, configure a Backup Server.

Start Server using a single user mode.

Run Disk Reinit to rebuild the Sysdevices system table without reinitializing Sybase Device.

The syntax is as follows:

Disk reinit

Name = "device_name",

PhysName = "Physical_name",

VDEVNO = Virtual_Device_number,

Size = Number_of_blocks

After completing, please see Error Log.

Confirm that the information reconstructed Sysdevices system table is correct:

--Select * from sysdevices

The information in the comparison table is the same as the information in the ERROR log or the remaining sysdevices.

Run the Disk Refit to rebuild sysdevices and sysdatabases.

Usage is as follows:

Use master

Go

Disk Refit

Go

Check if there is an error message in ERROR log.

When Disk Refit is completed, Shut Down ASE Server will be automatically.

Confirm that the information reconstructed is correct:

- Single user mode launches ASE Server

--Select * from sysusages, select * from sysdatabases

SYSUSAGES table looks correct? Compared with the previously reserved information. If there is no such possible, then it should

Ensure that there is no obvious error. For example: Is there a lack of DBID; whether it is deficed; whether it is only segmap = 4 for a database

Log line), etc.

--Sdatabases system table looks correct? Is there any obvious mistake?

11. Start the ASE Server to see if all databases have been restored.

Do DBCC inspection on all libraries.

Be a backup for all libraries.

Q.

How to transplant MASTER equipment?

A.

The following steps explain how to port the Master device to different disks. Please note that stop SQL is stopped before executing Buildmaster

SERVER application.

The key to success is that each line of content in the new Sysusages system table is consistent with the old sysusages system table content.

DBCC check on the Master library and the backup Master library.

. Execute the Select * from table_name command and retain its output content. Among them, Table_Name includes: sysdevices,

Sysusages, sysdatabases. Similarly, you can use the BCP command to be implemented.

The sp_configure command is executed and the output content is retained.

Copy $ Sybase / Server_name.cfg file to do reservations.

. SHUT Down SQL / ASE Server.

. Execute the following command to create a new Master device:

Unix: buildmaster -d -ssize

VMS: buildmaster / disk = / size = size (size in pages, 1 page = 2K)

Edit the Run_Server_name file, the -d (unix) or / device (vms) parameter points to the new device name. Single user mode launches SQL / ASE Server:

Unix: startserver -f run_sever_name -m

VMS: StartServer / Server = Server_Name / MASTERRECOER

. Execute the Select * from sysdevices command and retain its output content.

Confirm that each line of content in the new Sysusages system table matches the old Sysusages system table content, and after configuring Server,

Didn't do Alter Database, then the contents of system table sysusages are correct. If you have done Alter Database, you have to press it.

The order is performed in order, if there is no script, you have to find Alter Database in the information saved Sysusages system table.

Parameters.

.SHUTDOWN SQL / ASE Server, starting Server with single user mode, check if the Sysusages system table is correct.

If the configured Backup Server name is not SYB_BACKUP, then execute:

1> sp_configure "allow updates", 1

2> Go

1> Update sysservers set srvnetName = "name in interface" "

Where srvname = "SYB_BACKUP"

2> Go

Load the Master library. If the size of the new Master device is different from the old device size, Server will shut down. Please pay attention to new system tables

Will be overridden, and you need to adjust the size of the Master device in the sysdevices system table. Please do the following steps:

Start Server using a single user mode.

If the new device size is different from the old device size, please do:

1> sp_configure "allow updates", 1

2> Go

1> Update sysdevices set high = nnnn where name = "master"

2> Go

Where nnnn is the size of the MASTER device in pages (2k), this value can be found from the information of the reserved Sysdevices system table.

If the device built is larger than the old device, please perform:

1) Create a database that is similar to the Master device, the purpose of doing this is to reinitialize the distribution page, so that the entire Master device

Available.

2) Delete this database.

Restart the Server.

Backup Master database.

note:

To determine the character set and language module at this time when loading the Master library is the same as the character set and the language module when the backup Master library is.

Use the sp_helpsort to view the character set with the language module before and after performing this task.

Q.

How to rebuild the SybsystemProcs system database?

A.

In accordance with the following steps, you can implement the task of moving the SybsystemProcs system database and the device. At the same time, this process can also be used to expand

SybsystemProcs system database.

The grammatical structure mentioned in the following procedure can be found in Sybase related information.

Sybase reminds you that when modifying the system table, SQL Server is running in a single user mode while logging in with the "SA" user.

Keep the stored procedure script residing in the SybsystemProcs system database.

Single user mode Start SQL Server, execute: 1> sp_configure "allow updates", 1

2> Go

1> Reconfigure with override (above 10.0, omission this step)

2> Go

Delete the SybsystemProcs system database:

1> Use master

2> Go

1> DROP DATABASE SYBSYSTEMPROCS

2> Go

Do not create any other database before rebuilding the SybsystemProcs system database.

Delete information about the SybsystemProcs system database in the Sysdevices system table:

1> Begin TRAN

2> Delete from sysdevices where name = "sysprocsdev"

We assume that sysprocsdev is the default SybsystemProcs system database device name.

3> Select * from sysdevices

Determine if the delete is correct, if it is correct, execute:

4> Commit TRAN

Otherwise, execute:

4> Rollback

Restart SQL Server.

Create a SybsystemProcs system database device:

1> Disk init name = "sysprocsdev", physname = "physical_path", vdevno = 4, size = 25600

2> Go

Where SIZE is in a page (512 pages = 1m).

The VDEVNO of the SybsystemProcs system database device should be 4. SQL Server 4 cannot be reused in single user mode, so

If there is a problem when the above statement is executed, restart SQL Server.

.sybsystemprocs system database:

1> CREATE DATABASE SYBSYSTEMPROCS ON SYSOROCSDEV = 50

2> Go

In the sysdatabases system table, the SybsystemProcs system database DBID = 4, if it is rebuilt

No other database is created before the SybsystemProcs system database.

Start SQL Server in a multi-user mode, and execute:

1> sp_configure "allow updates", 0

2> Go

3> Reconfigure with override (above 10.0, omission this step)

4> Go

Run the installmaster script:

% isql -usa -psa_password -sserver_name -n -iinstallmaster -o -s

(New_Master_Device_size in 2k)

6, edit RUN_SERVERNAME

Specify the specified master device as a newly created Master device and delete the parameters added in step 1.

7. Delete the contents of Master, Tempdb, Model in /Directory.spec/us ,/directory.spec/usages file.

Q.

How to do Rebuild Log?

A.

Note: This process may cause the data of the data.

(1) Give the role of SA user Sybase_ts_role

ISQL -USA -P

1> sp_role "grant", "Sybase_ts_role", SA

2> Go

1> quit

(2) Place the database "Bypass Recovery" status

ISQL -USA -P

1> sp_configure "allow updates", 1

2> Go

1> Use master

2> Go

1> Update sysdatabases set status = -32768

2> Where name = "database_name"

3> Go

1> Shutdown with NOWAIT

2> Go

(3) REBUILD database log

ISQL -USA -P

1> Use master

2> Go

1> DBCC Rebuild_Log (Database_name, 1, 1)

2> Go

1> Shutdown with NOWAIT

2> Go

(4) Restart SQL Server

1> Use master

2> Go

1> Update sysdatabases set status = 0 Where name = "database_name"

2> Go

1> sp_configure "allow updates", 0

2> Go

1> Shutdown with NOWAIT

2> Go

(5) After restarting SQL Server, if the database is restored to normal, the Rebuild Log will be completed successfully, otherwise restore the database backup

Series, use the Dump Database or BCP command.

8, single user mode launch ASE

$ cd install

$ startserver -f run_servername -m

9, BCP IN system table

$ bcp master..sysdevices in /directory.spec/devs -usa -p -b 1 -C

$ bcp master..sysdatabases in /directory.spec/dbs -usa -p -b 1 -C

$ bcp master..sysusages in /directory.spec/usages -usa -p -b 1 -C

$ bcp master..syslogins in /directory.spec/logins -usa -p -b 1 -C

$ bcp master..sysconfigures in /directory.spec/configures -usa -p -b 1 -c

$ bcp master..syscharsets in /directory.spec/charsets -usa -p -b 1 -c

10, SHUDOWN ASE

11. Execute the InstallMaster script

$ isql -usa -p

转载请注明原文地址:https://www.9cbs.com/read-124435.html

New Post(0)