How to disable the transaction log file

Discussion forum about all things SqlBase or SqlTalk
dis_sg

How to disable the transaction log file

Post by dis_sg » 11 Apr 2011, 07:46

Hi,
is there any way to disable the transaction log file??
can direct insert/update/delete/select to the dbs file instead of log file??

Please advice

Mike Vandine

Re: How to disable the transaction log file

Post by Mike Vandine » 11 Apr 2011, 07:58

If you are doing this in SQLTalk, you can do a 'set recovery off;' as the FIRST statement after connecting. This will connect without creating log files. However, please make sure that you make a backup of the database before you connect with norecovery, because if *anything* happens while the database is open with recovery off (i.e. a power failure, server crash, etc.) the database will be *unreadable*!

So, please use this with great caution. :)

dis_sg

Re: How to disable the transaction log file

Post by dis_sg » 11 Apr 2011, 08:02

can we using "rollforward end" to resolve it??

dis_sg

Re: How to disable the transaction log file

Post by dis_sg » 11 Apr 2011, 08:05

Hi,
we are not using SQLTalk. we are using a program to connect to the dbs file.
is there any way to turn off the log such as sql.ini setting ??

Mike Vandine

Re: How to disable the transaction log file

Post by Mike Vandine » 11 Apr 2011, 08:26

If you are using TD, you can do a:

Set SqlNoRecovery = TRUE

The rollforward end is a 'trick' that works *sometimes*. It is only to be used as a very last resort and is *definitely* not guaranteed to work.

I personally would *never* turn recovery off unless you've backed up the database prior to the run or you are doing a load after an unload. This should never be used as a normal production running practice.

dis_sg

Re: How to disable the transaction log file

Post by dis_sg » 11 Apr 2011, 08:30

but we do not have the source code of the program to reset the settting.

Set SqlNoRecovery = TRUE


can set it via SQL.ini??

Mike Vandine

Re: How to disable the transaction log file

Post by Mike Vandine » 11 Apr 2011, 08:34

Nope. No setting in SQL.INI to do this.

I would shoot any Unify Developer that even considered something so dangerous. :)

RainerE
Germany
Posts: 2223
Joined: 27 Apr 2021, 12:40
Location: Germany

Re: How to disable the transaction log file

Post by RainerE » 11 Apr 2011, 09:18

Hi Mike,

thank you for shooting me!

We use "Set recovery off" in the following conditions to increase performance where otherwise the given timeframe would not be be long enought:
- Migration Tools (which updates the database from version x to y)
- Corrections Tools
We make a backup before and know, that the database is damaged if an error occures. But recovery multiplies the performance in these conditions by >= 100. If you have only 48 hours to migrate/correct a database and if a tool runs about 28 hours with recovery off, you do not have the chance of not using this feature.

Regards,
Rainer

Mike Vandine

Re: How to disable the transaction log file

Post by Mike Vandine » 11 Apr 2011, 09:32

Hi Rainer,

I wasn't saying that there weren't cases to do this. There certainly are, especially for your instances. However, you take proper precautions (backing up the database, etc.). If this option was allowed as a setting in the sql.ini file for anyone to just turn on or off, some people would NOT take the proper precautions and this would end in disaster. Sorry, but I feel that would be irresponsible of us to allow that.

RainerE
Germany
Posts: 2223
Joined: 27 Apr 2021, 12:40
Location: Germany

Re: How to disable the transaction log file

Post by RainerE » 11 Apr 2011, 11:34

Hi Mike,

I agree with the sql.ini setting. It should not be there.

I agree, that I'm not a developer at Unify.

But I'm developping with Unify TD and Gupta SB. ;-)

Regards,
Rainer

dis_sg

Re: How to disable the transaction log file

Post by dis_sg » 12 Apr 2011, 04:53

Hi,

after i set the recovery to off using sqltalk,
i cannot execute simple insert statement:

the sqlbase engine was closed itself.

the error is "session is closed"

from :FAIL.sql

00703 Fatal SQLBase System Failure (VIO IPN)
Reason: This is a Fatal Error.
Remedy: Stop all database operations and run a CHECK DATABASE operation.
If a FAIL.SQL file is available, then save it.

Attempt to
reproduce the problem via a SQL script, scenario, or using the
NETLOG utility (see the DBA Guide for how to produce a NETLOG).
Contact your local Centura certified technical support center.

Mike Vandine

Re: How to disable the transaction log file

Post by Mike Vandine » 12 Apr 2011, 06:34

Try to do an unload of the database. Hopefully that will work, which means that the 703 is not a 'hard' corruption on the database.

Please post your sql.ini file and the version of SQLBase you are using.

dis_sg

Re: How to disable the transaction log file

Post by dis_sg » 13 Apr 2011, 04:11

Hi ALL,
after set the recovery to off, the transaction log is still there.
what else we have to perform??

Please advice.

Mike Vandine

Re: How to disable the transaction log file

Post by Mike Vandine » 13 Apr 2011, 04:41

Hmmmm. Possibly old .log files?

OK, let's start from scratch.

Deinstall the database. This should leave just a .DBS file and no .LOG files. If there are still .log files there, rename them to something else (like 20.lug) so they will still be there in case something goes wrong.

Install the database. Connect to the database and do a 'set recovery off;'. If you are the only person connected to the database, this will be allowed. If others are already connected, this will NOT be allowed. If you are doing this programmatically, please check to see if the set recovery actually worked.

There should be no .log files in the database log directory.

dis_sg

Re: How to disable the transaction log file

Post by dis_sg » 13 Apr 2011, 04:54

Hi,
the transaction log file was new created after conversion program was executed,

what we did

1, login to SQLtalk
2, connect to the database,

show recovery;
set recovery off;
disconnect all;

3, login sqltalk again and connect same database;
run "show recovery" to confirm the setting again.

it was set to disable;

4, run the comversion program and the log file was created( same folder as the dbs file)

any steps i did wrong??

Return to “SqlBase General Discussion”

Who is online

Users browsing this forum: [Ccbot], [Facebookexternalhit] and 0 guests