Subject | Re: AW: [firebird-support] VACUUM |
---|---|
Author | Helen Borrie |
Post date | 2004-10-15T13:06:31Z |
At 07:52 PM 15/10/2004 +0800, you wrote:
gstat -h Yourdatabase -u sysdba -pass ftsecvgg
(Yourdatabase can be path or alias)
Sweep interval is at the bottom of this report. Default is 20000. If it
is 0, auto-sweeping is disabled.
than zero. When well-written applications are used, auto-sweeping never
occurs. Basically, write good applications and run manual sweeps
periodically to get the database into shape. Just leave the sweep interval
as-is. If you are writing bad apps (those that are careless about
committing work or which keep transactions open for long periods) you're
going to need the extra sweeps.
now" thingie. Switch order matters - consult the IB6 Ops Guide if you
don't have a firebird book.
Note that garbage collection and sweeping are not the same thing. GC goes
on all the time (if it can) but careless transaction management will
inhibit it.
You also get GC performed when you run a backup unless you switch it off,
as you would do if you intend to create a fresh database for immediate use
from the backup. GC never releases space left by deletes.
./heLen
>Thanks for your responses.Yes
>
> >From this site ( http://www.destructor.de/firebird/gfix.htm ), I find
>the following command to turn *off* automatic sweeping.:
>gfix -user SYSDBA -password masterkey dbserver:/db/mydb.fdb -h 0
>Is automatic sweeping configured by default?
>How can I see the configuration?from the bin dir of your Firebird setup:
gstat -h Yourdatabase -u sysdba -pass ftsecvgg
(Yourdatabase can be path or alias)
Sweep interval is at the bottom of this report. Default is 20000. If it
is 0, auto-sweeping is disabled.
>If I run the following command (I believe its to 'sweep databaseNo. It will sweep the database now. :-)
>now'), will it turn *on* automatic sweeping?
> I can't seem to find howAuto sweeping is enabled by setting the sweep interval to something more
>to turn automatic sweeping on (considering if this command doesn't).
than zero. When well-written applications are used, auto-sweeping never
occurs. Basically, write good applications and run manual sweeps
periodically to get the database into shape. Just leave the sweep interval
as-is. If you are writing bad apps (those that are careless about
committing work or which keep transactions open for long periods) you're
going to need the extra sweeps.
>gfix -user SYSDBA -password masterkey dbserver:/db/mydb.fdb -sSomething along those lines does the same thing as your "sweep database
now" thingie. Switch order matters - consult the IB6 Ops Guide if you
don't have a firebird book.
Note that garbage collection and sweeping are not the same thing. GC goes
on all the time (if it can) but careless transaction management will
inhibit it.
You also get GC performed when you run a backup unless you switch it off,
as you would do if you intend to create a fresh database for immediate use
from the backup. GC never releases space left by deletes.
./heLen