Path: utzoo!censor!geac!jtsv16!uunet!ncrlnk!ncr-sd!hp-sdd!megatek!zeta!hollen From: hollen@zeta.megatek.uucp (Dion Hollenbeck) Newsgroups: comp.sys.ibm.pc Subject: Re: What files MUST be in the root directory? Message-ID: <671@megatek.UUCP> Date: 8 Aug 89 15:00:53 GMT References: <189@nisca.ircc.ohio-state.edu> Distribution: usa Lines: 61 From article <189@nisca.ircc.ohio-state.edu>, by pjd@hpuxa.ircc.ohio-state.edu (Peter J. Dotzauer): > There seems to be some confusion about what files MUST be in the root > directory. For instance, the specifications for many drivers state that > one must put a line 'device=xyz.sys' into config.sys, and place > the file 'xyz.sys' into the root directory. > > Of course, you can say 'device=c:\sys\xyz.sys' and put your file in the > directory c:\sys, thereby keeping your root directory uncluttered. > > Obviously, the two hidden files and config.sys MUST absolutely be in > the root directory, but what about command.com, if you have a comspec > line in config.sys? I haven't dared to remove command.com from the root, > for fear of screwing something up. Peter has it real close with his suppositions. The only files which MUST be in the root directory are IO.SYS, IBMBIO.SYS (hidden and incidentally, MUST be the first contiguous areas on the disk since the boot code is only smart enough to read in the first n tracks, not smart enough to access the file system) and CONFIG.SYS. Command.com need not be in the root directory (or present at all if you prefer a replacement command line process such as I do (4DOS by the way)), but you must make the entry "SHELL=c:\4dos\4dos.exe" appropriate for your command processor. By making this entry, COMSPEC should be automatically set for you, but I set it again. Also, AUTOEXEC.BAT must be in the root directory for it to be executed and the "/p" switch on the "SHELL=" line must be present for AUTOEXEC to be run at boot. The lack of the "/p" switch tells command.com (and other command line processors mimic'ing it) that this instance of the shell is the resident one and cannot be "exit'ed" out of like a secondary shell can be. Secondary shells, by default, will not run AUTOEXEC. Some programs (like TIMESLIPS which I love dearly) give you no choice about where they put some of their necessary files. TIMESLIPS creates SYS001.COM and SYS002.COM in the root directory. If the program has a loadable device driver, however, Peter is correct, you can merely specify the path on the "device=" line in CONFIG.SYS. A suggestion for setting up a newly formatted hard disk. After formatting and transferring your operating system (format /s) delete COMMAND.COM from the root directory. Use "mkdir" to create EVERY directory and sub-directory entry you plan to use. I take a directory tree image of my hard disk before formatting by using the command : XCOPY C:\noexist.foo A:\ /s /e /v This will copy the directory tree structure of my hard disk and all files named "noexist.foo" onto a floppy. Since "noexist.foo" does not exist, only the directory tree structure is copied. After formatting and removing COMMAND.COM, I use the reverse of the command to re-create the directory tree structure on the target hard disk. The intent of the switches is to copy all subdirectories even if they will beempty, verify copy after done, and copy all subdirectories under the source directory. When your hard disk has been set up with all the directory entries first, if you ever get the disk trashed, it will be much easier for anyone who knows how to re-construct directories and FAT entries by hand to recover your disk. Dion Hollenbeck (619) 455-5590 x2814 Megatek Corporation, 9645 Scranton Road, San Diego, CA 92121 uunet!megatek!hollen or hollen@megatek.uucp