Necessary to take a cold backup of a temporary tablespace?
Is it necessary to take a cold backup of a temporary tablespace? According to me it is, but when we shut down the database the SMON process then cleans up the temporary tablespace also?
No, it is not necessary to take a cold backup of temporary tablespaces. Data in a temporary tablespace is temporary,...
Continue Reading This Article
Enjoy this article as well as all of our content, including E-Guides, news, tips and more.
just like the name says. Data only lives in the temporary tablespace for the duration of the transaction. If you shut down the database, all transactions are ended (normally or abnormally). In either case, there are no transactions that require the contents of the temporary tablespace. When you start the database, SMON will clean up any data in the temporary tablespace as it is no longer needed.
If you restore from a cold backup and do not restore a TEMPORARY TABLESPACE (one that was created with the "CREATE TEMPORARY TABLESPACE ... TEMPFILE ...;" command) and the temporary tablespace is missing, then Oracle will re-create this for you automatically. If you created your Temp tablespace with the "CREATE TABLESPACE .... DATAFILE ... TEMP;" command, then Oracle will not recreate the tablespace for you on startup. In this case (which should no longer be used), you definitely should back up your temporary tablespace.