Temporary file
Temporary files (in computer slang often Tempfiles from English. Temporary files , called) are files that the operating system or other programs are used and for temporary storage of data intended to be processed by the same or another program . The data is outsourced in order to relieve the working memory of the computer or to organize the transfer of data to another program. With the introduction of virtual memory , the need for such a relief is partially weakened, but in the past the volume of data to be processed has also increased in some applications, for example in image processing . Most of the time, the creating program itself deletes temporary files.
Windows, MS-DOS
In Windows, temporary files are often identified by their filename extensions .tmp
. In addition, they are often saved specifically for the logged in user, that is, there is a separate directory (“folder”) for each user in which these files are stored. By default, a subdirectory of the user directory is used that can be determined using the environment variable USERPROFILE
. (This directory may not be visible in Windows Explorer , as it may be a "hidden folder" that must be made visible by adjusting the corresponding option.) In principle, it is possible to adjust the storage location of these files ( Configuration via the registry ).
As a relic of the previous operating systems (for example MS-DOS and Windows 98 ) there are also the environment variables TEMP
and TMP
, which can be used to configure the directory for temporary files. Some application programs still refer to these definitions.
Temporary files are also stored by some programs in special application-related directories or even in the current directory, so that it is not easy to get an overview in order to completely clean up files that are no longer required.
Linux, UNIX
The Filesystem Hierarchy Standard for temporary files distinguishes two types in Linux :
- can be deleted on restart
- In the directory
/tmp
those files are stored which are no longer needed after a restart of the system and which can be emptied during the system start - Lasting restart
- in the directory
/var/tmp
those files that should be usable after a system restart.
Careless handling of temporary files can lead to a security hole , especially on multi-user systems that support symbolic links : If the name of a temporary file can be predicted, a symbolic link can be stored under this name. If a program is then run that creates a temporary file under the same name, data may be lost or user rights may be extended. Therefore, temporary file names usually contain a randomly generated combination of characters.
Individual evidence
- ↑ Temporary files in Computerlexikon.de
- ↑ Temporary files in Microsoft MSDN
- ↑ temporary files on Bullhost.de
- ↑ temporary files on Bullhost.de
- ↑ Technet Microsoft - Recognized Environment Variables
- ↑ Technet Microsoft - Moving TEMP and TMP directories
- ↑ Filesystem Hierarchy Standard 2.3, / tmp
- ↑ Filesystem Hierarchy Standard 2.3, / var / tmp