Subject: file type "a"?
To: None <netbsd-users@NetBSD.org>
From: Anne Bennett <anne@porcupine.montreal.qc.ca>
List: netbsd-users
Date: 06/02/2006 12:41:57
What on earth is file type "a"?  Example (NetBSD 3.0 on amd64):

  # /bin/ls -aloiT /disks/REM/smedia

  total 98
  1     dr-xr-xr-x  1 root  wheel  -  8192 Dec 31 23:00:00 1979 .
  79465 dr-xr-xr-x  8 root  wheel  -   512 Jan  2 15:03:31 2006 ..
  401   ar-xr-xr-x  1 root  wheel  - 16064 Mar 31 23:00:00 2000 back_tmp.j5g
  400   ar-xr-xr-x  1 root  wheel  - 16064 Mar 31 23:00:00 2000 backing.j5g


(This is a listing of files on a mounted filesystem on a SmartMedia
card; the card was written, I think, with a BOSS J5 Jamstation, a
couple of weeks ago, despite the reported times.  The filesystem type
is "msdos".)

/usr/bin/file says that the files are "data"; the contents are
binary but appear to be Jamstation song files of some sort.

"man ls" doesn't tell me what type "a" is, and "man 2 stat" lists,
for field st_mode, no types that I don't recognize.  Aha,
"/usr/include/sys/stat.h" gives me a partial answer:

  #define _S_ARCH1  0200000   /* Archive state 1, ls -l shows 'a' */
  #define _S_ARCH2  0400000   /* Archive state 2, ls -l shows 'A' */

(I've put in a bug report to update the "stat" and "ls" manpages with
these new types; my message is currently greylisted but should, I
trust, get through eventually.)

Anyway, can someone explain to me (or point me at information about)
these "archive states", and what this means for a file in NetBSD?


Anne.
-- 
Ms. Anne Bennett, as a private citizen:  anne@porcupine.montreal.qc.ca
Also reachable more officially at work:  anne@encs.concordia.ca