24

In Windows Server 2003, in the "Attributes" column of windows explorer, some files have "A" or "C" or "AC" or others. What do these mean?

GavinR
  • 315
  • 1
  • 3
  • 10
  • 3
    Another question is "What the hell does the Archive flag do" - I've seen it since the early days of MS-DOS, it's applied to almost every single file, and I've never had a need/reason to change it, but at the same time never had any idea what it does. Is it still functional? – Mark Henderson Jul 02 '09 at 00:33
  • 1
    @Mark: to my knowledge, the Archive flag was used by backup utilities. It was reset after the backup was done. If you modify the file, it is set again, to mark it must be back up again. Primitive, so no more used, I guess. – PhiLho May 12 '11 at 11:07
  • 2
    The archive bit is still used. I wrote a program to reset permissions on all of our users' home directories if they were found to be out of whack. Changing permissions trips the archive bit. Really pissed off the operations people when the backups ran. – Patrick Seymour Nov 22 '11 at 00:43

9 Answers9

41

Prior to windows 8/10 the attributes were:

R = READONLY
H = HIDDEN
S = SYSTEM
A = ARCHIVE 
C = COMPRESSED
N = NOT INDEXED
L = Reparse Points
O = OFFLINE
P = Sparse File
I = Not content indexed
T = TEMPORARY
E = ENCRYPTED

You should pay special attention to the offline attribute because it may affect the behavior of your backup software. Files with the O attribute may be skipped entirely because the software may assume they are stored elsewhere.


Consider these answers on SO and SF for additional information:

https://superuser.com/questions/1214542/what-do-new-windows-8-10-attributes-mean-no-scrub-file-x-integrity-v-pinn/1215034

https://superuser.com/questions/44812/windows-explorers-file-attribute-column-values

Scott Lundberg
  • 2,364
  • 2
  • 14
  • 22
Kevin Kuphal
  • 9,064
  • 1
  • 34
  • 41
  • I have seen the O attribute on the files I got after unzipping the Yii PHP framework archive (yii-1.1.7.r3135 to be precise). Not sure how it went there. Nor how to act on it... Noticed that because it has a specific icon overlay. – PhiLho May 12 '11 at 11:02
  • Where did you find this list? – mlhDev Feb 21 '17 at 15:47
  • Voting down. The attrib command on my win10 system disagrees with this. The answer should point to a reference and or explain what the attributes mean and how they are intended to be used. – Ярослав Рахматуллин Sep 21 '17 at 14:16
4

A = archive bit is set
C = compressed

squillman
  • 37,618
  • 10
  • 90
  • 145
4

Another attribute is E for Encrypted.

Knox
  • 2,453
  • 2
  • 26
  • 33
2

When Windows 7 "Backup and Restore" creates a "system image," it puts it in a root-level folder named WindowsImageBackup, which has the "I" attribute. Windows 7's "help attrib" command says:

C:\>help attrib
Displays or changes file attributes.

ATTRIB [+R | -R] [+A | -A ] [+S | -S] [+H | -H] [+I | -I]
       [drive:][path][filename] [/S [/D] [/L]]

  +   Sets an attribute.
  -   Clears an attribute.
  R   Read-only file attribute.
  A   Archive file attribute.
  S   System file attribute.
  H   Hidden file attribute.
  I   Not content indexed file attribute.
  [drive:][path][filename]
      Specifies a file or files for attrib to process.
  /S  Processes matching files in the current folder
      and all subfolders.
  /D  Processes folders as well.
  /L  Work on the attributes of the Symbolic Link versus
      the target of the Symbolic Link
Dave Burton
  • 181
  • 1
  • 8
1

You can manipulate attributes (set/unset) with the attrib command.

Open a cmd.exe prompt with win+r and then type;

hide a folder:

> attrib +h +s C:\Test\Testing

unhide:

> attrib -h -s C:\Test\Testing
1

D is missing from the above list so in case you're wondering like I was, D stands for "Directory." It's probably not included because the question focused on files, not directories, but I found this question in a search and had to continue my search to find out what D was, so, as a convenience to future readers, I added this answer.

Here's the link to the answer that included D:

Windows Explorers file attribute column values

jamesc1101
  • 11
  • 1
0

Others are as follows;

H = Hidden

S = System File

R = Read Only

AHS and R can be set by the user or system, as user you can use the 'attrib' command to add/remove attributes. C is a system only attribute.

To find out more about the attrib command goto a command window and type 'attrib /?'

drgncabe
  • 395
  • 1
  • 6
0

Backup software can clear the archive bit which is set when a file is modified. That way, it can be used to do incremental backups in order to skip over files that have already been backed up.

Since it can be set and unset at will, it's not necessarily the most reliable method and I think most backup software uses more sophisticated criteria for determining what to include in an incremental backup.

Dennis Williamson
  • 60,515
  • 14
  • 113
  • 148
  • I can tell you that the current version of BackupExec can use either the archive bit or the last modified timestamp for determining whether or not to back up a file. – joeqwerty Oct 23 '09 at 19:25
0

The A bit only shows up when you have backup software that sets it to indicate that file has been archived. When a user makes changes to a file, the operating system clears the archive bit, to indicate to the backup software that if it's doing an incremental or differential backup, it needs to backup that changed file and reset the A bit. Incremental backups reset the archive bit, so that the next incremental will only backup newly changed files. Differential backups do NOT reset the archive bit, so every differential backup grabs all the files that have changed since the previous full backup. So, to restore a system on Friday, an administrator would need the weekly backup from sunday and either the latest differential, or ALL the daily incrementals.

  • 3
    You have this exactly backwards. The OS sets the archive bit when a file is created or modified. Backup software clears the archive bit when the file is backed up. – ThatGraemeGuy Mar 01 '11 at 07:16
  • 2
    Graeme is correct, the archive bit is set to indicate that the file **needs** to be archived, not that it has been archived. – John Gardeniers Mar 01 '11 at 10:46