In-depth exploration of the secret of INF

xiaoxiao2021-03-06  45

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.

Uncover the mystery of INF file

INF is the English abbreviation of Device Information File. 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.

Anatomical INF file structure

The 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 come together

The structure of anatomical INF file.

1. Version section

Each INF file contains such a section that entries in this section primarily describe the device types and applicable operating systems 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 Festival

The entry in this section is mainly to describe all hardware devices that INF files can identify, which include manufacturers of devices 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 Festival

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. SourceDiskFiles Festival

The driver file list and the installed location, the 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. DestinationDIRS Festival

The INF file will indicate that the installer is copied to the hard disk during the installation process, or some files on the hard disk, rename, and so on. This section is specified to achieve the purpose path where the file is implemented.

6. DEFAULTINSTALL Festival and INSTALL

The actual properties of the device driver and the hardware device are described 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 Festival

The string variable is defined in this section, and when some strings are frequently appearing in the INF file, in order to simplify the input, a string variable can be defined in this section, which appears in the INF file.

Read INF file

Let us explain the specific meaning of the INF file with the WDM driver of the ATI graphics, the WDM driver for Windows XP. Since INF file is often very long, we delete some of the information, only to keep an infer The structure of the file, as shown.

INF file exciting instance

Light does not practice, let us look at a typical application of several INF files.

1. Open "Lock" registry

Step 1: Open the Notepad program, 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"

After the input is completed, the unlock.inf, the name is all, the extension must be INF.

Step 2: Right-click on the "unlock.inf" file, click "Install" in the pop-up right-click menu, as shown, the locked registration table will be opened.

2. Deliver automatic backup of important files with INF files

Everyone knows that the registry is the life of the Windows operating system. Therefore, the system starts automatically run the registry checker and 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 is as follows:

10 generation C: / windows directory

11 Representative C: / Windows / System Directory

30 Representative C Pangen Catalog 31 Replica of the Windows System Home

For example, put autoexec.bat and config.sys in two files in the backup file, and set the parameters "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 notepad program, enter the following:

[autorun]

Icon = ******. ICO

"******" is the path of the icon file and the icon file name, please modify the path of the specific icon file and the 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 good dance

I don't want to double-click the hard disk partition or right-click "Automatic Play" in the right-click menu, as shown, automatically open the music player, start playing music files, let the beautiful music are rounded around you. . Heart, actually very simple, come on.

Then enter the following in the "Autorun.inf" file:

Open = d: / program files / foobar2000 /

Foobar2000.exe d: /qs.fpl

"D: / program files / foobar2000 /

FOOBAR2000.EXE "is the specific location of the author's favorite player FOOBAR2000. If you use WinAmp or other player, replace the location where the specific player is located," D: /Qs.fpl "is a FOOBAR2000 player Playl file, you can also replace the path where a specific music file is. If you use WinAmp, the playlist file should be "* .m3u". Use this method You can also set it to automatically double-click the hard disk partition Play the film and television file.

4. Unattended to install Windows 98

There is a Batch tool in the Windows 98 installation CD that can make an INF file that is used for unmanned installed installed scripts, which generates a variety of information that contains various information that needs to interact with the Wizard when installing Windows 98 - 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. Right click on the screen

When we have something to leave for a while, use the screen saver with a password to protect our current operations that are not 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 the Notepad program, 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 / ""

After the entry is completed, 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. Try it with a click, is it immediately starting the screen saver.

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 click on the disk manager

Regular finishing of the disk is a job we often do. Each time you click "Start → Programs → Accessories → System Tools → Disk Defragmatings" in the class, then select to organize you want to organize in the selected drive window in the pop-up. The partition, 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"

After the input is completed, save it 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: After you want to make a disk finish, just open the resource manager, right-click on the corresponding disk, select "Disk Squire" in the pop-up menu (Figure).

7. Solve an ATI graphics card unable to install a public emission problem

Some third-party ATI graphics can't install public emission drivers, resulting in many ways, if some third-party manufacturers have changed on hardware, using non-public version of PCB design and BIOS, this It may cause 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. Install the INF file in the command line

Normally, we are all installed in the Windows environment, but if one day, what should 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!

转载请注明原文地址:https://www.9cbs.com/read-63457.html

New Post(0)