IBM Hidden Files
I have an IBM PC/XT with one floppy disk and a 10-megabyte hard disk. When I ran CHKDSK on both drives, the computer said I had two hidden files taking up about 22K. What are hidden files, and are they accessible?
When you power up an IBM personal computer, it performs a complex series of housekeeping operations before turning the system over to you. This process usually involves loading two hidden, read-only system files named IBMBIO.COM and IBMDOS.COM from disk. These are machine language programs which the system needs to operate correctly.
IBMBIO.COM is an extension of the PC's operating system—called BIOS for Basic Input/Output System—most of which is permanently stored in ROM (Read-Only Memory). The IBMBIO.COM program loads and executes when the system boots up, to initialize input/output devices and perform other system tasks. This is done to correct errors (and there are some) permanently "wired into" the ROMBIOS, and to allow for new devices such as the PCjr's cartridges. IBMBIO.COM is about 3.5K in length.
The PC's DOS (Disk Operating System) is a separate program, roughly 19K long, for manipulating disk data. Since none of DOS is stored in ROM, it's also necessary to load the IBMDOS.COM program from disk and install it in memory when the system boots up. After initializing the system for BIOS, IBMBIO.COM moves IBMDOS.COM into the correct memory area and transfers control to DOS, which in turn does its own initialization before turning the system over to the user.
Files ending in .COM are system files (distinguished from user files which you can alter at will). Since IBMBIO.COM and IBMDOS.COM are critical to normal operation, they're made invisible to user commands such as DIR (disk DIRectory). Out of sight, out of mind—if you don't know a file exists, you'll be less likely to erase it. Both files are further protected by making them read-only: If you can't write to a file, you're less likely to corrupt it by accident.
It is possible to access system files. After each filename in the disk directory is a file attribute byte which defines the file type. Using the DEBUG program described in your DOS manual, you can read the disk directory, change a file's attribute byte to remove its protective attributes, and write the modified sector back to the disk. However, few users would have any reason to rewrite a system file, and the risk of inadvertent error is enormous. At best, the error might crash the system; at worst, you might lose an entire disk of data. If you want to try modifying a system file, practice on a disk that doesn't contain any important data. You can find a detailed discussion of system files and the boot process in Chapter 1 of COMPUTE!'s Mapping the IBM PC and PCjr by Russ Davies.