You can use Sybase Central or the Log Translation utility (dbtran) to retrieve audit information from the transaction log. Before attempting to retrieve audit information, ensure that you are connected to your database as a user with DBA, Remote, or Backup authority.
Select the database.
Click the Auditing tab.
Click Retrieve Audit Messages.
A window appears displaying the dbtran messages. Ignore the warning about chronological ordered output.
Click Close.
The auditing information appears on the Auditing tab in the right pane.
Use the filter options to control which audit information you want to display.
You can choose to display all audit information, or to show only errors, or only audit messages containing the text you specify.
Select an entry in the audit entries table to display details about the entry.
To retrieve up-to-date auditing information, press F5, and repeat this procedure.
For more information, see Auditing example.
You can access the dbtran utility from Sybase Central or from a command prompt. The dbtran utility uses the specified transaction log to produce a SQL script that contains all the transactions, and some information about what user executed each command. By using the -g option, dbtran includes more comments containing the auditing information. The -g option is equivalent to specifying the following options:
-d Display output in chronological order.
-t Include trigger-generated operations in the output.
-a Include rolled back transactions in the output.
For more information about these options, see Log Translation utility (dbtran).
You can run the dbtran utility against a running database server or against a database log file.
With the database server running, run the following command:
dbtran -g -c connection-string -n SQL-file |
For example:
dbtran -g -c "UID=DBA;PWD=sql" -n demo.sql |
A readable version of the transaction log is saved to your current directory. In the example, the auditing information is saved to the demo.sql file, and the file contains information about the sample database.
For more information about connection strings, see Connection parameters.
Shut down the database server to ensure the transaction log file is available.
Run the following command:
dbtran -g transaction-log SQL-file |
For example:
dbtran -g demo.log demo.sql |
In the example, the auditing information from the transaction log file demo.log is placed into the file demo.sql.
For more information, see Log Translation utility (dbtran).
Discuss this page in DocCommentXchange. Send feedback about this page using email. |
Copyright © 2009, iAnywhere Solutions, Inc. - SQL Anywhere 11.0.1 |