Re: Informix backup and temporary space
Posted in 1998
Helmut Leininger <Helmut.Leininger@bull.net> offerred: +I've had the same problem at a customer site. I found out, that about 200 MB +of free space was needed during the backup (it's freed afterwards). +I do not know, why taking a backup needs so much space and I did not find a +hint in the documentation (I would be interested in some additional +information). Nor do I know if the needed temporary space depends on the size +of the DB. For a backup of the database while in on-line mode to work, the server needs to have a way of reliably obtaining a copy of any page in it's state no later than the time the archive started. Let's say you bring a page into the shared memory buffer pool, update it, then it gets flushed back to disk during an LRU write. If an archive was started before that update occurred, and has not yet copied that particular page to the backup, then the copy of the page now on disk is later than the archive start time, and thus, if included in the archive, would result in a system restored to an inconsistent state. To get around this, the server can use the pages in the physical log. Any page modified in shared memory is guaranteed to have a before image containing the original version of the page in the physial log. In earlier versions, whenever a checkpoint was going to occur, it would alert the backup process which would then pull any needed pages from the physical log. This had two drawbacks: one, it slowed the checkpoint down, requiring it to coordinate with the backup so as not to lose any needed pages; two, it slowed the archive down, as it constatntly got interrupted by the checkpoints. The current behavior addresses those problems. When you start an archive, a temporary file is created for every dbspace in your system. As checkpoints occur, pages for dbspaces that have not yet been completely archived are copied from the physical log to the appropriate temp file. This allows the checkpoint to finish more quickly than when it had to coordinate with the archive. As each dbspace finishes being archived, the temp file for that dbspace is read and the pages contained therein is added to the archive. At that point the temp file should be released. When the archive is complete, all the temp files should be gone. Offhand, I don't know why it would require a specific amount of temp space at archive start time, other than based on the number of dbspaces being archived times the initial size it makes each temp file (I don't know what size that is). I would take a look in the temp file system to see how many temp file are there and how big they are. Dave -- Dave Kosenko davek@summitdata.com Director of Training Services (732) 469-4070 Summit Data Group (an Informix Authorized Education Center)