Skip to content

The Eclectic Light Company

Macs & painting – 🦉 No AI content
Main navigation
  • Downloads
  • Freeware
  • M-series Macs
  • Mac Problems
  • Mac articles
  • Macs
  • Art
hoakley October 28, 2023 Macs, Technology

Where is my file’s metadata?

Most of us have little difficulty in understanding where a file’s data is: each file’s records identify where that’s stored. But where is the information about that data, its metadata, stored? The best answer is that it all depends, and this article explains what it depends on.

When the Mac was being developed in the early 1980s, the majority of file systems were crude and simple: each file consisted of the information about that file in attributes such as its name and date of creation, and the data stored for that file. If you wanted to supplement the file’s basic attributes with metadata, then they had to be stored within the file’s data, which isn’t good practice, but worked.

From its outset, the Mac was intended to be different. Instead of its files having just a data fork, they also had a structured database of resources, the resource fork. That was particularly useful for apps, as they could keep different localisations of their menus in the resource fork, for example. Resource forks were allowed for any file, so an app could store a document’s window settings in that document’s resource fork, and many did.

When Mac OS X was being developed, there were some who wanted to remove those resource forks, and others who fought to retain them. In the end the ideal compromise was reached, whereby files could have as many forks as they wanted, as extended attributes. In Mac OS X 10.4, those traditional resource forks became extended attributes of type com.apple.ResourceFork.

Against all odds, extended attributes, xattrs in short, began to flourish. In the Mac Extended File System HFS+ they were stored separately from file data, as they are in APFS today. This makes them ideal for storing metadata: rather than having to edit and store metadata embedded within the file’s data, it could be kept apart as xattrs. The snag here, though, was that other file systems weren’t as flexible as HFS+ (or APFS later). Windows file systems in particular knew nothing of forks or xattrs.

As the major apps added more metadata to their standard file types, they had to cater for the limitations of Windows, and all found ways of storing metadata in their file data. Two good examples are images and PDFs.

Several different systems of image metadata have been defined, of which the best known is EXIF, first published in 1995. Although they’re stored in designated segments of the file data, those metadata can be spread almost anywhere within the file. As a result, EXIF metadata have commonly been corrupted or even removed by apps when they save image files, but when handled properly, they are independent of platform and file system.

PDF is another common file format with ancient origins, and was first released in 1993. Every PDF file consists of a series of objects, most of which are normally stored as ASCII text. Towards the end of every file is an index table to all the objects within it. Objects include both the content of the file, such as images and drawn text, and its metadata. The latter includes a basic set of information such as the document title and authors, and more extensive streams using XMP. Comments and markup are normally added as metadata objects, again stored within the file data.

So for most metadata that has to work across platforms, it has to conform to the lowest common denominator, a file consisting of its attributes and the data alone. For those intended for use on Macs, though, and a few other more enlightened file systems, metadata can be stored where they should be, in xattrs. This is standard for Finder tags, quarantine information for downloads, and can be used for many other purposes such as assigning keywords, and attaching hashes to verify the integrity of files.

The Finder and Spotlight integrate metadata embedded within file data with those stored in xattrs. Although this is very helpful to users, for example when searching by keyword, it confuses where those metadata are stored. That’s important for those of us who want to preserve important files without changing their data. For example, I have a great many PDF files covering all sorts of topics, but to add keywords to their standard metadata would result in all their data being changed, something I’m not prepared to do.

This isn’t helped by the opaqueness of xattrs either. There are remarkably few GUI apps that provide any access to xattrs, either in terms of specialist or general editors, and configuring the display of metadata in the Finder isn’t simple. Apple has long considered that xattrs are the preserve of its own engineers, developers and a few advanced users, and provided little support or documentation. It hasn’t provided anything equivalent to its famous resource fork editor, ResEdit.

So if you want to discover where any file’s metadata are, you’ll need to arm yourself with a xattr editor like my free xattred, an app specialising in the editing of that type of file, and sometimes a format-specific metadata editor too. No wonder that metadata are woefully underused and frequently misunderstood.

Share this:

  • Click to share on X (Opens in new window) X
  • Click to share on Facebook (Opens in new window) Facebook
  • Click to share on Reddit (Opens in new window) Reddit
  • Click to share on Pinterest (Opens in new window) Pinterest
  • Click to share on Threads (Opens in new window) Threads
  • Click to share on Mastodon (Opens in new window) Mastodon
  • Click to share on Bluesky (Opens in new window) Bluesky
  • Click to email a link to a friend (Opens in new window) Email
  • Click to print (Opens in new window) Print
Like Loading...

Related

Posted in Macs, Technology and tagged APFS, EXIF, extended attributes, metadata, PDF, resource, xattr, xattred. Bookmark the permalink.

7Comments

Add yours
  1. 1
    Enzo Vincenzo's avatar
    Enzo Vincenzo on October 28, 2023 at 11:22 am

    Thanks Howard! I’m a geek, I used ResEdit, but despite having downloaded all your amazing utilities I’ve never explored them all.
    Now I will also start using xattred, putting it in the nice folder named after your brand and customized with your logo in /Applications/Utilities, together with your utilities that I use most.
    Thanks again

    LikeLiked by 1 person

    • 2
      hoakley's avatar
      hoakley on October 28, 2023 at 6:30 pm

      Thank you – enjoy!
      Howard.

      LikeLiked by 1 person

  2. 3
    Ilian's avatar
    Ilian on October 28, 2023 at 7:57 pm

    Thanks for the great summary!
    Interesting approach is offered by the TagSpaces app. It saves the tags, which for me is the most important metadata, in the name of the files. This approach makes the tag stick to all kind of files, ensuring the portability across different operating systems and cloud sync services.

    LikeLiked by 1 person

    • 4
      hoakley's avatar
      hoakley on October 28, 2023 at 8:19 pm

      Thank you.
      Although it may be practical if you have to work with primitive file systems, the file’s name isn’t metadata, it’s one of the primary attributes of that file. To change that to add metadata is not a wise move at all. But I do understand that sometimes compromise is necessary.
      Howard.

      LikeLike

  3. 5
    Unknown's avatar
    Week 44 – 2023 – This Week In 4n6 on October 29, 2023 at 10:46 am

    […] Howard Oakley at ‘The Eclectic Light Company’Where is my file’s metadata? […]

    LikeLike

  4. 6
    Maurizio's avatar
    Maurizio on October 29, 2023 at 1:19 pm

    Ntfs is fully able to manage macos datadtream with alternate data stream , but data are preserved only on local ntfs copy as apfs , so both world will never talk eachoter

    LikeLiked by 1 person

    • 7
      hoakley's avatar
      hoakley on October 29, 2023 at 10:36 pm

      Thank you.
      Howard.

      LikeLike

·Comments are closed.

Quick Links

  • Free Software Menu
  • System Updates
  • M-series Macs
  • Mac Troubleshooting Summary
  • Mac problem-solving
  • Painting topics
  • Painting
  • Long Reads

Search

Monthly archives

  • December 2025 (67)
  • November 2025 (74)
  • October 2025 (75)
  • September 2025 (78)
  • August 2025 (76)
  • July 2025 (77)
  • June 2025 (74)
  • May 2025 (76)
  • April 2025 (73)
  • March 2025 (78)
  • February 2025 (67)
  • January 2025 (75)
  • December 2024 (74)
  • November 2024 (73)
  • October 2024 (78)
  • September 2024 (77)
  • August 2024 (75)
  • July 2024 (77)
  • June 2024 (71)
  • May 2024 (79)
  • April 2024 (75)
  • March 2024 (81)
  • February 2024 (72)
  • January 2024 (78)
  • December 2023 (79)
  • November 2023 (74)
  • October 2023 (77)
  • September 2023 (77)
  • August 2023 (72)
  • July 2023 (79)
  • June 2023 (73)
  • May 2023 (79)
  • April 2023 (73)
  • March 2023 (76)
  • February 2023 (68)
  • January 2023 (74)
  • December 2022 (74)
  • November 2022 (72)
  • October 2022 (76)
  • September 2022 (72)
  • August 2022 (75)
  • July 2022 (76)
  • June 2022 (73)
  • May 2022 (76)
  • April 2022 (71)
  • March 2022 (77)
  • February 2022 (68)
  • January 2022 (77)
  • December 2021 (75)
  • November 2021 (72)
  • October 2021 (75)
  • September 2021 (76)
  • August 2021 (75)
  • July 2021 (75)
  • June 2021 (71)
  • May 2021 (80)
  • April 2021 (79)
  • March 2021 (77)
  • February 2021 (75)
  • January 2021 (75)
  • December 2020 (77)
  • November 2020 (84)
  • October 2020 (81)
  • September 2020 (79)
  • August 2020 (103)
  • July 2020 (81)
  • June 2020 (78)
  • May 2020 (78)
  • April 2020 (81)
  • March 2020 (86)
  • February 2020 (77)
  • January 2020 (86)
  • December 2019 (82)
  • November 2019 (74)
  • October 2019 (89)
  • September 2019 (80)
  • August 2019 (91)
  • July 2019 (95)
  • June 2019 (88)
  • May 2019 (91)
  • April 2019 (79)
  • March 2019 (78)
  • February 2019 (71)
  • January 2019 (69)
  • December 2018 (79)
  • November 2018 (71)
  • October 2018 (78)
  • September 2018 (76)
  • August 2018 (78)
  • July 2018 (76)
  • June 2018 (77)
  • May 2018 (71)
  • April 2018 (67)
  • March 2018 (73)
  • February 2018 (67)
  • January 2018 (83)
  • December 2017 (94)
  • November 2017 (73)
  • October 2017 (86)
  • September 2017 (92)
  • August 2017 (69)
  • July 2017 (81)
  • June 2017 (76)
  • May 2017 (90)
  • April 2017 (76)
  • March 2017 (79)
  • February 2017 (65)
  • January 2017 (76)
  • December 2016 (75)
  • November 2016 (68)
  • October 2016 (76)
  • September 2016 (78)
  • August 2016 (70)
  • July 2016 (74)
  • June 2016 (66)
  • May 2016 (71)
  • April 2016 (67)
  • March 2016 (71)
  • February 2016 (68)
  • January 2016 (90)
  • December 2015 (96)
  • November 2015 (103)
  • October 2015 (119)
  • September 2015 (115)
  • August 2015 (117)
  • July 2015 (117)
  • June 2015 (105)
  • May 2015 (111)
  • April 2015 (119)
  • March 2015 (69)
  • February 2015 (54)
  • January 2015 (39)

Tags

APFS Apple Apple silicon backup Big Sur Blake Bonnard bug Catalina Consolation Console Corinth Delacroix Disk Utility Doré El Capitan extended attributes Finder firmware Gatekeeper Gérôme High Sierra history of painting iCloud Impressionism landscape LockRattler log M1 Mac Mac history macOS macOS 10.12 macOS 10.13 macOS 10.14 macOS 10.15 macOS 11 macOS 12 macOS 13 macOS 14 macOS 15 malware Metamorphoses Mojave Monet Monterey Moreau myth narrative OS X Ovid painting performance Pissarro Poussin privacy Renoir riddle Rubens Sargent security Sierra SilentKnight Sonoma SSD Swift Time Machine Tintoretto Turner update upgrade Ventura xattr Xcode XProtect

Statistics

  • 21,054,010 hits
Blog at WordPress.com.
Footer navigation
  • Free Software Menu
  • About & Contact
  • Macs
  • Painting
  • Downloads
  • Mac problem-solving
  • Extended attributes (xattrs)
  • Painting topics
  • SilentKnight, Skint, SystHist, silnite, LockRattler & Scrub
  • DelightEd & Podofyllin
  • xattred, SpotTest, Spotcord, Metamer & xattr tools
  • 32-bitCheck & ArchiChect
  • XProCheck, T2M2, LogUI, Ulbow, blowhole and log utilities
  • Cirrus & Bailiff
  • Precize, Alifix, UTIutility, Sparsity, alisma, Taccy, Signet
  • Versatility & Revisionist
  • Text Utilities: Textovert, Nalaprop, Dystextia and others
  • PDF
  • Keychains & Permissions
  • Updates
  • Spundle, Cormorant, Stibium, DropSum, Dintch, Fintch and cintch
  • Long Reads
  • Mac Troubleshooting Summary
  • M-series Macs
  • Mints: a multifunction utility
  • VisualLookUpTest
  • Virtualisation on Apple silicon
  • System Updates
  • Saturday Mac Riddles
  • Last Week on My Mac
  • sysctl information
Secondary navigation
  • Search

Post navigation

Painting on the edge: Vermeer reinvented
Saturday Mac riddles 227

Begin typing your search above and press return to search. Press Esc to cancel.

  • Reblog
  • Subscribe Subscribed
    • The Eclectic Light Company
    • Join 8,887 other subscribers
    • Already have a WordPress.com account? Log in now.
    • The Eclectic Light Company
    • Subscribe Subscribed
    • Sign up
    • Log in
    • Copy shortlink
    • Report this content
    • View post in Reader
    • Manage subscriptions
    • Collapse this bar
%d