In-depth exploration of INF in the Windows system
Everyone knows that there is a few unclear INF files in "My Computer", but few people know what is used. At its quantity, just stay in the INF file to unclear the sensibility of the locked registry, then what is the INF file, what can I do? Today, let us walk into the mysterious world of INF files. The mystery of the INF file INF is the English abbreviation of Device Information File, which is a file format that Microsoft releases its driver for hardware device manufacturers. The INF file contains information or scripts of the hardware device to control the hardware operation. In the INF file, how to install the hardware driver to the system, where is the source file, which folder is installed, how to add itself in the registry, and so on. The drivers required to install the monitor, modem, and printer are all through the INF file, which is the credit of INF, which makes Windows to find the driver of these hardware devices and installed correctly. When we add system components through "Start → Control Panel → Add Delete Programs", the Windows Setup "is added, the INF file will be called automatically. And in other occasions, you need to click the right mouse button on the INF file and then select "Install", you can install the application smoothly. A large amount of INF file is stored in the C: / Windows / INF folder. This folder is typically in an implicit state. If you want to view this folder, select "View → Folder Items → View", then select "Show all files" under the File and Folder option. The structural INF file of anatomical INF file is actually a plain text file that can be edited with any text editing software, such as: Notepad, Word board, etc. The INF file has a set of written rules, and each INF file is written in strict accordance with these rules. * Rules 1: Inf file is the segment, each INF file has a lot of section, and the section is enclosed in square brackets. Some of these quotes are well defined, and some are user-defined. Each section is up to 255 characters (Windows 2000 / XP / 2003 operating system) or 28 characters (in the Windows 98 operating system). There is no distinction between the sections and the sections, in addition, if two same number names in the same INF file, the system will automatically merge the entry below the two quarters. * Rule 2: In the content between the section and the section, the contents of the section are entries, each section is composed of many entries, each entry consists of "signature =" $ chicago $ "". If there is a number of values after each entry is equal, each value is separated from ",". * Rules 3: INF file is not sensitive to case. * Rules 4: ";" The following content is comment. * Rules 5: If you have too much content, you can't write it completely, use "/" to write a line of content as many rows. After understanding the rules of the INF file, let us have the structure of the INF file. 1. Each INF file contains a section in this section that is primarily a device type and an applicable operating system that describes the device supported by this INF file. In this section, if "signature =" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" " The INF file is suitable for Windows 2000 / XP / 2003 operating system, and it will be one.
In addition, the "Class" entry in this section is important, which indicates the type of equipment, common types: Display (display device, such as graphics card), Media (multimedia device, such as sound card), NET (network device, usually NIC ), MODEM (modem), Printer (printing device), Image (image capture device, such as a camera). 2. Manufacturer Section This section is primarily described in describing all hardware devices that INF files that can be identified, including devices manufacturers so that the device is properly installed. Such as "% ati% = ATI" indicates that the manufacturer of the device is "ATI", this everyone will not be strange, it is the producer of the graphics card. 3. SourceDisksNames section This section mainly indicates the media where the installation file is located. Such as: "1 =" ATI Drivers Release CD "" indicates that all drivers are on the retail version of the CD disk. 4. The SourceDiskfiles section driver file list and the installed location, this section must be combined with the [SourceDisksNames] section to know the specific location. For example, "atinbtxx.sys = 1", you must go to [DestinationDirs] to see "1" specifically represent the location. 5. The DestinationDirs section INF file indicates that the installer is copied to the hard disk during the installation, or some files on the hard disk are deleted, rename them. This section is specified to achieve the purpose path where the file is implemented. 6. The DEFAULTINSTALL section and INSTALL section describes the actual properties of the device driver and the hardware device in this section. By default, the [DefaultInstall] section is first executed. This section specifies the information to copy or delete, the registry update, the INF file update, etc., but also the pointer to other sections. 7. String section defines a string variable in this section. When some strings frequently appear in the INF file, in order to simplify input, a string variable can be defined in this section, which appears in the INF file in the section. Read the INF file Let us explain the specific meaning of the INF file as an instance of the WDM driver for Windows XP for Windows XP. Since INF file is often very long, we delete most of the information, Only the structure of an INF file is retained, as shown in Figure 1. Figure 1 INF file is a wonderful example of light, not practicing, let us look at a typical application of several INF files. 1. Open the "Lock" registry first step: Open Notepad Programs, enter the following: [Version] signature = "$ chicago $" [defaultinstall] DELREG = deleteme [deleteme] HKCU, "Software / Microsoft / Windows / Currentversion / Policies / system "," DisableregstryTools "HKLM," Software / Microsoft / Windows / CurrentVersion / Policies / System "," DisableRegStryTools "input, saved as unlock.inf, name, extension, must be INF.
Step 2: Right-click on the "unlock.inf" file, click "Install" in the pop-up right-click menu, as shown in Figure 2, the locked registry will be opened. figure 2
2. Carefully use INF file automatic backup important file everyone knows that the registry is the life of the Windows operating system, so the system starts automatically run the registry checker, automatically updates the backup registry file. There is a "scanreg.ini" in the Windows directory of the system disk, and scanregw.exe executing the default operation performed daily is running under its control, we can use this principle to implement backups of our important files. Step 1: Open the resource manager, find the file, open it with Notepad. We can clearly see a total of five parameters, as shown. (1) The parameter value of BACKUP can be 0 or 1, default is 1. A value is 1 indicates that the scanning registry is scanned at the time of initiation every day, and the value is 0 indicates that no registry operation is performed. (2) Optimize The value value can be 0 or 1, default is 1. The value is 1 means that excess data in the registry is deleted each time the registry, thereby optimizing the registry data, the value is 0 means not being deleted. (3) ScanRegVersion = 0.0001 Program Release Notes. (4) MaxBackupCoPies This parameter is used to set the number of established backup files, the value of the value of 5 to 99, the default value is 5, that is, the maximum five backup files, for a better protection system, general It is advisable to set up about 10 or so. (5) BackupDirectory This parameter is used to set the directory where the backup file is stored. The default storage directory is Windows / Sysbckup, note that the full path must be the full path. (6) Files in "ScanReg.ini" finally has the following comments "; files = [dir code,] file1, file2, file3", put it the comment symbol ";", you can register your own DIY Table Check the important file for the program backup. By default, when the Registry Checkler creates a registry backup file, save "System.dat", "System.ini", "User.dat" and "Win.ini" four files in "CAB" compressed files. In that, if you need to add other important system profiles to this compressed file, you can enter "[directory code], file name 1, file name 2, file name 3" after "files =". Separate with a comma, the directory code meanings as follows: 10 Represents C: / Windows directory 11 Represents C: / windows / system directory 30 Representative C: The root directory 31 represents the root directory of the Windows system where you want to put autoexec.bat and config.sys Two files are placed in the backup file, and the parameters can be set to "file = 30, config.sys, autoexec.bat".
3. Hard disk (U disk) also needs personalization first: Give a hard disk (U disk) DIY a cute icon we first replace the hard icon of the hard disk for the icon we like, give the hard drive on a beautiful color clothing. First prepare an icon file, you can use the icon making program to make your own icon file, or you can use the ready-made icon file, it is best to save to the root directory of a partition of a hard disk. Then open the notebook, enter the following: [Autorun] icon = ******. ICO is "******" is the path and icon file name of the icon file, please modify it to the specific icon file. Path and icon file name. After entering, save it as "autorun.inf", and cut it to a root directory of your partition you want to play. Second: Let the hard disk can sing, don't want to double-click the hard disk partition or right-click Select "Auto Play" in the right mole menu, as shown in Figure 3, automatically open the music player, start playing music files, Let the beautiful music around you around you. Heart, actually very simple, come on. image 3
The following is then entered in the "autorun.inf" file: open = d: / program files / foobar2000 / foobar2000.exe d: /qs.fpl sold in "D: / program files / foobar2000 / foobar2000.exe" is the author The specific location of the player FOOBAR2000, if you use WinAmp or other player, replace the location where the specific player is located, "D: /Qs.fpl" is the playlist file of the Foobar2000 player, you can also Replace the path where a specific music file is located. If you use Winamp, the playlist file should be "* .m3u". This method can also be set to automatically play the film and television file when double-click the hard disk partition.
4. Unattended installation Windows 98 There is a Batch tool in the Windows 98 installation CD, which can make an INF file that is used for unattended installed installed scripts, which generates a variety of information containing the WINDOWS 98 to interact with various information - -Msbatch.inf. First find the "setup" program icon in the Windows 98 installation CD "/ Tools / Reskit / Batch" directory to install the BATCH98 tool. Next, run the BATCH tool, follow the wizard prompt to generate the "msbatch.inf" file, and save the file to the floppy disk. Please refer to the relevant information here. When you need to reinstall Windows 98, use the boot disk to the DOS prompt, the floppy disk with the "msbatch.inf" file is saved, insert the Windows 98 installation CD into the CD-ROM drive, type the following command after the DOS prompt: " x: / win98 / setup a: msbatch.inf ", can be used to return. Where "X" is the optical drive and drive. 5. Put the screensaver, please go to the right menu. When we have something to leave for a while, use the screen saver with a password to protect our current operations to be peeable by others. However, in the default settings, the screen saver is the fastest to start after 1 minute, so how can you quickly activate the screen saver? The most common method is to create a shortcut to start the screen on the desktop, and you can start when you need it. In addition, we can also put the screensaver to go right-click menu! Step 1: Open Notepad Programs, Enter the following: [Version] signature = "$ chicago $" [defaultinstall] addreg = addme [addme] HKCR, "CLSID / {20D04FE0-3AEA-1069-A2D8-08002B30309D} / shell / pingbao "," screen protection "HKCR," CLSID / {20D04FE0-3AEA-1069-A2D8-08002B30309D} / shell / pingbao / command "," SSSTARS.SCR / S / "% 1 /" "entry After the check is correct, save as "pingbao.inf", the file name can be obtained, the extension must be INF. Step 2: Right-click on the "pingbao.inf" file and click "Install" in the right-click menu pop-up. Step 3: When you need to run the screen protected, return to the desktop, click Right click on the "My Computer" icon to select the "Screen Protection" option, as shown in Figure 4. Try it with a click, is it immediately starting the screen saver. Figure 4
Note: "SSSTARS.SCR" For the file name of the screen saver to start, please replace the screen saver file you like; if you select the "Screen Protection" option in the right-click menu, there is no response If you do not start the screen saver, "/ S /"% 1 / "" "" / "% 1 /" / s "can be modified to" / "% 1 /" / s ".
6. Right to correct the disk manager to regularly organize the disk is a job we often do. Every time, you will click "Start → Programs → Accessories → System Tools → Disk Defragmatings", then pop up. Select the partition you want to organize in the Select the drive window, then click the "Debris Squiring" button to start finishing. This is more troublesome, we can try to add a disk management program to the right mump. Step 1: Open the Notepad program, enter the following: [Version] signature = "$ chicago $" [defaultinstall] addreg = addme [addme] HKCR, "/ Drive / shell / disk finishing / command", "defrag .exe% 1 "The input is complete, saved as adddefrag.inf, name is all, the extension must be INF. Step 2: Right-click on the "AddDefrag.inf" file, click "Install" in the right-click menu that pops up. Step 3: In the future, you need to make a disk finishing, just open the resource manager, right-click on the corresponding disk, select "Disk Sollation" in the pop-ups (Figure 5). Figure 5
7. Solving an ATI graphics unable to install a public version of the driver, some third-party ATI graphics can't install the public version of the driver, resulting in many ways, if some third-party manufacturers have changed in hardware, using non-public The version of PCB design and BIOS, etc., this may result in the case where the public version driver cannot be installed. What should I do when your graphics card encounters this problem? First, extract the ATI graphics driver you downloaded to the hard disk, found all INF files in the "Atidrive" subdirectory, atiixpxx.inf - suitable for Windows XP, atii9xxx.inf - applicable At Windows 9x, Atii2kxx.inf is suitable for Windows 2000. Then open the INF file corresponding to the operating system, find the "Ati.mfg" string through the menu bar - lookup "ati.mfg" string, then see "Radeon 7000, Radeon 7200, Radeon 7500, Radeon 8500", etc. It deletes it. Then look for your video card matches the string, as the author of the RADEON 7500 graphics card, you find "RADEON 7500", find the following information: "RADEON 7500 = ati2mtag_RV200, PCI / VEN_1002 &&&& DEV_5157 &&&& SUBSYS_013A1002", the "&&&& SUBSYS_013A1002" delete, save the file. Try now, see the problem is not solved. 8. Installing the INF file in the command line Normally, we are installing the INF file in a Windows environment, but if one day, what do you need to run the INF file in the command line? After the command line prompt, enter "Rundll32 Syssetup, the path and file name .inf" in which the default allinstall 128 INF file is located, you can install the corresponding INF file after entering!