5.5. /var/cache : Application cache data (2024)

5.5.1.Purpose

/var/cache is intended for cached data fromapplications. Such data is locally generated as a result oftime-consuming I/O or calculation. The application must be able toregenerate or restore the data. Unlike/var/spool, the cached files can be deletedwithout data loss. The data must remain valid between invocations ofthe application and rebooting the system.

Files located under /var/cache may beexpired in an application specific manner, by the systemadministrator, or both. The application must always be able torecover from manual deletion of these files (generally because of adisk space shortage). No other requirements are made on the dataformat of the cache directories.

Rationale

The existence of a separate directory for cached data allowssystem administrators to set different disk and backup policies fromother directories in /var.

DirectoryDescription
fontsLocally-generated fonts (optional)
manLocally-formatted manual pages (optional)
wwwWWW proxy or cache data (optional)
<package>Package specific cache data (optional)

5.5.3./var/cache/fonts : Locally-generated fonts (optional)

5.5.3.1.Purpose

The directory /var/cache/fonts should be used to store anydynamically-created fonts. In particular, all of the fonts which areautomatically generated by mktexpk must be located inappropriately-named subdirectories of /var/cache/fonts.[38]

5.5.3.2.Specific Options

Other dynamically created fonts may also be placed in this tree,under appropriately-named subdirectories of/var/cache/fonts.

5.5.4./var/cache/man : Locally-formatted manual pages (optional)

5.5.4.1.Purpose

This directory provides a standard location for sites that provide aread-only /usr partition, but wish to allow caching oflocally-formatted man pages. Sites that mount /usr as writable(e.g., single-user installations) may choose not to use/var/cache/man and may write formatted man pages into thecat<section> directories in /usr/share/man directly. Werecommend that most sites use one of the following options instead:

  • Preformat all manual pages alongside the unformatted versions.

  • Allow no caching of formatted man pages, and require formatting to bedone each time a man page is brought up.

  • Allow local caching of formatted man pages in /var/cache/man.

The structure of /var/cache/man needs toreflect both the fact of multiple man page hierarchies and thepossibility of multiple language support.

Given an unformatted manual page that normally appears in<path>/man/<locale>/man<section>,the directory to place formatted man pages in is/var/cache/man/<catpath>/<locale>/cat<section>,where <catpath> is derived from<path> by removing any leadingusr and/or trailing sharepathname components. (Note that the<locale> component may be missing.)[39]

Man pages written to /var/cache/man mayeventually be transferred to the appropriate preformatted directoriesin the source man hierarchy or expired; likewiseformatted man pages in the source man hierarchymay be expired if they are not accessed for a period of time.

If preformatted manual pages come with a system on read-onlymedia (a CD-ROM, for instance), they must be installed in the sourceman hierarchy(e.g. /usr/share/man/cat<section>)./var/cache/man is reserved as a writable cachefor formatted manual pages.

Rationale

Release 1.2 of this standard specified/var/catman for this hierarchy. The path hasbeen moved under /var/cache to better reflect thedynamic nature of the formatted man pages. The directory name hasbeen changed to man to allow for enhancing thehierarchy to include post-processed formats other than "cat", such asPostScript, HTML, or DVI.


[38] This standard does not currently incorporate the TeX DirectoryStructure (a document that describes the layout TeX files anddirectories), but it may be useful reading. It is located atftp://ctan.tug.org/tex/

[39] For example, /usr/share/man/man1/ls.1 isformatted into /var/cache/man/cat1/ls.1, and/usr/X11R6/man/<locale>/man3/XtClass.3x into/var/cache/man/X11R6/<locale>/cat3/XtClass.3x.

5.5. /var/cache : Application cache data (2024)

FAQs

Is it safe to delete files from var cache? ›

/var/cache is intended for cached data from applications. Such data is locally generated as a result of time-consuming I/O or calculation. The application must be able to regenerate or restore the data. Unlike /var/spool , the cached files can be deleted without data loss.

Is it safe to delete var cache yum? ›

Yes, safe to delete, as long as you arent running another yum process (or another user is), or perhaps another tool might be (like puppet for example).

Can I delete var cache in Ubuntu? ›

/var/cache is used to store files and other data that can safely be deleted. But don't delete cache, change any ownerships, or delete directories there. Many sysadmins have a crontab entry to clean files in /var/cache and /tmp once a week.

Can I delete var cache in DNF? ›

By default, DNF caches files in the /var/cache/dnf directory. You do not want to manually delete files or directories below /var/cache/dnf. Instead, the dnf clean command can be used to remove files below /var/cache/dnf.

What happens if I delete application caches? ›

Clearing your cache deletes unnecessary data and frees up disk space. It also removes personal data stored by sites or apps, refreshes browser content so what you see is the most updated version, and helps troubleshoot app issues so they run more smoothly.

Is it OK to delete all cache files? ›

It's not bad to clear your cached data now and then. Some refer to this data as “junk files,” meaning it just sits and piles up on your device. Clearing the cache helps keep things clean, but don't rely on it as a solid method for making new space.

Is it safe to remove var cache in apt? ›

Provided you are cautious, any future inconvenience is likely to be minor. Figure 2: The /var directory includes expired files that can be deleted to free up space, such as logs or spools. However, to be completely safe, you can just delete the files in /var/cache/apt/archives.

Can I empty var cache apt archives? ›

Clear the APT cache:

The clean command clears out the local repository of downloaded package files. It removes everything except the partials folder and lock file from /var/cache/apt/archives/ . Use apt-get clean to free up disk space when necessary, or as part of regularly scheduled maintenance.

Is it safe to delete all files in var log? ›

1 Answer. It is safe to delete a log file. However, it is not safe to delete a log directory. Example of deleting /var/log/mail/ cause a File not found exception when trying to write /var/log/mail/info.

How to clean up var in Linux? ›

Clean your /var directory in RHEL Linux (CentOS/Fedora/Redhat)
  1. $ du -sch /* 2> /dev/null # image-1.
  2. $ du -sch /var/* 2> /dev/null # image-2.
  3. $ du -sch /var/crash/* 2> /dev/null # image-3.
  4. You can also truncate huge log files, sometimes log files are huge to help in restoration. ...
  5. $ tail -5000 filename > filename.new.
Sep 17, 2020

How to clean up dnf? ›

Cleanup
  1. Remove all cache files generated from the repository metadata, specify the keyword dbcache . sudo dnf clean dbcache.
  2. Empty the cache directory for the enabled repositories of all cached packages, specify the keyword packages . ...
  3. Specify the keyword ' all ' to clear all cached files from all enabled repositories.

How to delete var in Linux? ›

Using the unset Command

If you want to remove the variable completely, you need to run unset -f EXPORTED_VARIABLE. Let's use this command and see if we get any results. We're verifying that the variable has been removed from our shell environment by running the env command.

Is it safe to delete var folders? ›

This usually saves, depending on the files on the disk, a good amount of disk space. But you should not delete /var or /usr as this will break your system.

Can I delete files in a var folder? ›

if you don't need them any more, you can delete them, you can also move them to another storage for later usage – don't forget that you must reset all deamons that write logs that you deleted/moved or simply reboot the machine if you can.

Top Articles
What is AWS: An Ultimate Guide to Amazon Web Services
15 Autumn Home Decor Ideas | Guinness Homes
Artem The Gambler
Matgyn
My E Chart Elliot
Myexperience Login Northwell
Identifont Upload
Bin Stores in Wisconsin
Blanchard St Denis Funeral Home Obituaries
East Cocalico Police Department
Senior Tax Analyst Vs Master Tax Advisor
2022 Apple Trade P36
Max 80 Orl
Vardis Olive Garden (Georgioupolis, Kreta) ✈️ inkl. Flug buchen
Slushy Beer Strain
Enderal:Ausrüstung – Sureai
Diablo 3 Metascore
Busty Bruce Lee
Cinebarre Drink Menu
979-200-6466
Weather Rotterdam - Detailed bulletin - Free 15-day Marine forecasts - METEO CONSULT MARINE
Recap: Noah Syndergaard earns his first L.A. win as Dodgers sweep Cardinals
If you bought Canned or Pouched Tuna between June 1, 2011 and July 1, 2015, you may qualify to get cash from class action settlements totaling $152.2 million
FDA Approves Arcutis’ ZORYVE® (roflumilast) Topical Foam, 0.3% for the Treatment of Seborrheic Dermatitis in Individuals Aged 9 Years and Older - Arcutis Biotherapeutics
Nz Herald Obituary Notices
Rs3 Eldritch Crossbow
How many days until 12 December - Calendarr
Craigslist Northfield Vt
Governor Brown Signs Legislation Supporting California Legislative Women's Caucus Priorities
Bennington County Criminal Court Calendar
[PDF] PDF - Education Update - Free Download PDF
Roane County Arrests Today
Project Reeducation Gamcore
Southland Goldendoodles
Temu Seat Covers
Scott Surratt Salary
Bfsfcu Truecar
Max 80 Orl
Teenbeautyfitness
Rocketpult Infinite Fuel
Dreammarriage.com Login
Ny Post Front Page Cover Today
Vivek Flowers Chantilly
Delaware judge sets Twitter, Elon Musk trial for October
At Home Hourly Pay
Bridgeport Police Blotter Today
Electric Toothbrush Feature Crossword
Billings City Landfill Hours
Read Love in Orbit - Chapter 2 - Page 974 | MangaBuddy
Worlds Hardest Game Tyrone
Bellin Employee Portal
Latest Posts
Article information

Author: Patricia Veum II

Last Updated:

Views: 6261

Rating: 4.3 / 5 (44 voted)

Reviews: 91% of readers found this page helpful

Author information

Name: Patricia Veum II

Birthday: 1994-12-16

Address: 2064 Little Summit, Goldieton, MS 97651-0862

Phone: +6873952696715

Job: Principal Officer

Hobby: Rafting, Cabaret, Candle making, Jigsaw puzzles, Inline skating, Magic, Graffiti

Introduction: My name is Patricia Veum II, I am a vast, combative, smiling, famous, inexpensive, zealous, sparkling person who loves writing and wants to share my knowledge and understanding with you.