Flipkart Search Bar

Flipkart.com

Tuesday, April 10, 2007

Optimization Myths 2

1. Disable System Restore

Myth - "Disabling System Restore improves performance."

Reality - "System Restore does not cause any noticeable performance impact when monitoring your computer. The creation of a Restore point also is a very fast process and usually takes only a few seconds. Scheduled System Checkpoints (every 24 hours by default) are created only at system idle time to avoid interfering with a computer during use." - Source


2. Disk Defragmenter

Myth - "The built-in Disk Defragmenter is good enough."

Reality - "This statement would be true if the built-in defragmenter was fast, automatic, and customizable. Unfortunately, the built-in defragmenter does not have any of these features. The built-in defragmenter takes many minutes to hours to run. It requires that you keep track of fragmentation levels, you determine when performance has gotten so bad you have to do something about it, and then you manually defragment each drive using the built-in defragmentation tool." - Source - Comparison Chart (PDF)

Disk Defragmenter Limitations - "The Disk Defragmenter tool is based on the full retail version of Diskeeper by Executive Software International, Inc. The version that is included with Microsoft Windows 2000 and later provides limited functionality in maintaining disk performance by defragmenting volumes that use the FAT, the FAT32, or the NTFS file system. The XP version has the following limitations." - Source

- It can defragment only local volumes.
- It can defragment only one volume at a time.
- It cannot defragment one volume while scanning another.
- It cannot be easily scheduled without scripts or third party utilities
- It can run only one Microsoft Management Console (MMC) snap-in at a time.


3. Hiberfil.sys

Myth - "It is necessary to delete the Hiberfil.sys before defragmenting."

Reality - "The Hiberfil.sys is a file to which the system's physical memory is written during hibernation. On resuming from hibernation, the BIOS reads Hiberfil.sys to restore the state of the computer to its pre-hibernation state. Because the location of the Hibernate file is determined very early in the startup process, it cannot be moved. It can, however, be defragmented safely at startup using an enterprise-level defragmenter such as Diskeeper or the freeware utility PageDefrag." - Source


4. FAT32 vs. NTFS

Myth - "The FAT32 file system is faster/better than NTFS."

Reality - "NTFS is the better file system with many advantages over FAT32. NTFS features: Built-In Security, Recoverability, Alternate Streams, Custom File Attributes, Compression, Object Permissions, Economical Disk Space Usage using a more Efficient Cluster Size and Fault Tolerance. Windows 2000 and XP come with NTFS version 5 which includes even more advanced features such as: Encryption, Disk Quotas, Sparse Files, Reparse Points, Volume Mount Points. None of which is available with FAT32." - Comparison Chart

Performance
"NTFS is built for speed with impressive disk I/O performance on large volumes (Over 400 MB). NTFS uses a binary tree structure for all disk directories, which reduces the number of times the system has to access the disk to locate files. This system is best for large directories, and NTFS easily outperforms FAT32 in these situations. In addition, NTFS automatically sorts files in a folder on the fly. NTFS gains an edge over FAT32 by using relatively small disk allocation units (cluster sizes) for NTFS volumes. Smaller clusters prevent wasted disk space on volumes, especially those with numerous small files. Because NTFS uses small clusters better and has a more efficient design, its performance doesn't degrade with large volumes, in contrast to FAT's." - Source - Source 2

"NTFS is generally believed to be slower than FAT. However, with a correctly created NTFS volume, NTFS performance optimizations, and improved disk defragmentation, NTFS performance (including the extra "journaling") is equivalent to FAT on small disks and is faster than FAT on large disks. FAT32 performance is further reduced for volumes larger than 32 GB in two areas:

- Boot time with FAT32 is increased because of the time required to read all of the FAT structure. This must be done to calculate the amount of free space when the volume is mounted.
- Read/write performance with FAT32 is affected because the file system must determine the free space on the disk through the small views of the massive FAT structure. This leads to inefficiencies in file allocation." - Source

Gaming Performance
"The numbers show...not much difference. In fact, the only test that doesn't show near-perfect parity is PCMark04, and the difference between the results on the two file systems is less than two percent. HDTach's read and access tests, which respectively measure how fast data can be read from the drive and how quickly the drive can locate data, were nearly identical. More importantly, the gaming tests showed nary a difference in all-important frame rates between the file systems and the cluster sizes. Based on the uniformity we experienced, we highly recommend that users of Windows XP take advantage of the NTFS file system. Its gaming prowess matches that of FAT32 and it boasts a healthy line-up of advantages over its opponent." - Source

Reliability
In addition to its extensive memory and application protection features, NTFS is a reliable file system. When storing data to disk, NTFS records file I/O events to a special transaction log. If the system crashes or encounters an interruption, NTFS can use this log to restore the volume and prevent corruption from an abnormal program termination or system shutdown. NTFS doesn't commit an action to disk until it verifies the successful completion of the action. This precaution helps prevent corruption of an NTFS volume. NTFS also supports hot-fixing disk sectors, where the OS automatically blocks out bad disk sectors and relocates data from these sectors. This housecleaning happens in the background. An application attempting to read or write data on a hot-fixed area will never know the disk had a problem. I only recommend and use NTFS with Windows 2000 and XP." - Source


5. Converting FAT32 to NTFS

Myth - "Converting FAT32 volumes to NTFS instead of formatting them will reduce performance by forcing a 512 byte cluster size."

Reality - "Windows XP CONVERT creates the best possible cluster size according to the existing FAT format. On NTFS volumes, clusters start at sector zero; therefore, every cluster is aligned on the cluster boundary. For example, if the cluster size was 4K and the sector size was 512 bytes, clusters will always start at a sector number that is a multiple of 4096/512 for example, 8. However, FAT file system data clusters are located after the BIOS Parameter Blocks (BPB), reserved sectors, and two FAT structures. FAT formatting cannot guarantee that data clusters are aligned on a cluster boundary. In Windows 2000, CONVERT handled this problem by forcing an NTFS cluster size of 512 bytes, which resulted in reduced performance and increased disk fragmentation. In Windows XP, CONVERT chooses the best cluster size (4K is the ideal)." - Source

Notes - The FAT32 file system does not use a default cluster size smaller than 4 KB. The maximum NTFS default cluster size under Windows XP is 4 KB because NTFS file compression is not possible on drives with a larger allocation size. - Source


6. IO Page Lock Limit

[HKLM\SYSTEM\CurrentControlSet\Control\SessionManager\MemoryManagement] "IoPageLockLimit"

Myth - "Increasing the IO Page Lock Limit will lock more memory for exclusive access by the kernel, improving performance."

Reality - "Indeed, it does do this but only in an RTM Windows 2000 machine. It does absolutely nothing in Windows 2000 Service Pack 1 and up, and absolutely nothing in Windows XP. This makes it effectively useless, since no one in their right minds would be running RTM Windows 2000. The RTM kernel references IoPageLockLimit. The SP1 kernel does not. Neither do any subsequent editions of the kernel; neither does the XP kernel in any of its incarnations." - Source


7. IRQ Priority

[HKLM\SYSTEM\CurrentControlSet\Control\PriorityControl] "IRQ8Priority"

Myth - "Adjusting the Priority of IRQs especially IRQ 8 improves system performance."

Reality - "IRQs don't even HAVE a concept of "priority" in the NT family; they do have something called "IRQL" (interrupt request level) associated with them. But the interval timer interrupt is already assigned a higher IRQL than any I/O devices, second only to the inter-processor interrupt used in an MP machine. The NT family of OSes don't even use the real-time clock (IRQ 8) for time keeping in the first place! They use programmable interval timer (8254, on IRQ 0) for driving system time keeping, CPU time accounting, and so on. IRQ 8 is used for profiling, but profiling is almost never turned on except in very rare development environments. Even if it was possible it doesn't even make sense why adjusting the real-time clock priority would boost performance? The real-time clock is associated with time keeping not CPU frequency. I would not be surprised if this originated in an overclocking forum somewhere. This "tweak" can be found in most XP all-in-one tweaking applications. This is a perfect example of why they are not recommended." - Source


8. Launch folder windows in a separate process

Myth - "Enabling Launch folder windows in a separate process improves performance."

Reality - "Use this setting if your computer frequently crashes, and you are trying to minimize problems or troubleshoot. Be aware, however, this process uses more memory and that doing this could slow down the performance of your computer." - Source

Notes - Windows XP is a very stable operating system and should never Lock-up (freeze), display Blue Screen Stop Errors or Randomly Reboot. These are all warning signs something is wrong or misconfigured with your system. Use the Diagnose XP Guide to help troubleshoot the most common causes of system problems.


9. Large System Cache

[HKLM\SYSTEM\CurrentControlSet\Control\SessionManager\MemoryManagement] "LargeSystemCache"

Myth - "Enabling LargeSystemCache improves desktop/workstation performance."

Reality - "LargeSystemCache determines whether the system maintains a standard size or a large size file system cache, and influences how often the system writes changed pages to disk. Increasing the size of the file system cache generally improves file server performance, but it reduces the physical memory space available to applications and services. Similarly, writing system data less frequently minimizes use of the disk subsystem, but the changed pages occupy memory that might otherwise be used by applications. On workstations this increases paging and causes longer delays whenever you start a new app. Simply put enable this on a file server and disable it on everything else." - Source

"System cache mode is designed for use with Windows server products that act as servers. System cache mode is also designed for limited use with Windows XP, when you use Windows XP as a file server. This mode is not designed for everyday desktop use. When you enable System cache mode on a computer that uses Unified Memory Architecture (UMA)-based video hardware or an Accelerated Graphics Port (AGP), you may experience a severe and random decrease in performance. For example, this decrease in performance can include very slow system performance, stop errors, an inability to start the computer, devices or applications that do not load, and system instability. The drivers for these components consume a large part of the remaining application memory when they are initialized during startup. Also, in this scenario, the system may have insufficient RAM when the following conditions occur:

- Other drivers and desktop user services request additional resources.
- Desktop users transfer large files.

By default LargeSystemCache is disabled in Microsoft Windows XP." - Source


10. L2 Cache (SecondLevelDataCache)

[HKLM\SYSTEM\CurrentControlSet\Control\SessionManager\MemoryManagement] "SecondLevelDataCache"

Myth - "Adjusting the SecondLevelDataCache Registry value to match your CPU's L2 Cache size improves performance."

Reality - "SecondLevelDataCache records the size of the processor cache, also known as the secondary or L2 cache. If the value of this entry is 0, the system attempts to retrieve the L2 cache size from the Hardware Abstraction Layer (HAL) for the platform. If it fails, it uses a default L2 cache size of 256 KB. If the value of this entry is not 0, it uses this value as the L2 cache size. This entry is designed as a secondary source of cache size information for computers on which the HAL cannot detect the L2 cache. This is not related to the hardware; it is only useful for computers with direct-mapped L2 caches. Pentium II and later processors do not have direct- mapped L2 caches. SecondLevelDataCache can increase performance by approximately 2 percent in certain cases for older computers with ample memory (more than 64 MB) by scattering physical pages better in the address space so there are not so many L2 cache collisions. Setting SecondLevelDataCache to 256 KB rather than 2 MB (when the computer has a 2 MB L2 cache) would probably have about a 0.4% performance penalty." - Source - Source 2


11. NTFS is Fragmentation Free

Myth - "The NTFS File system does not get fragmented and Defragmenters are unnecessary."

Reality - "Even though NTFS is more resistant to fragmentation than FAT, it can and does still fragment. The reason NTFS is less prone to fragmentation is that it makes intelligent choices about where to store file data on the disk. NTFS reserves space for the expansion of the Master File Table, reducing fragmentation of its structures. In contrast to FAT's first-come, first-served method, NTFS's method of writing files minimizes, but does not eliminate, the problem of file fragmentation on NTFS volumes." - Source


12. QoS

Myth - "Disabling QoS will free up the 20% bandwidth reserved by QoS."

Reality - "As in Windows 2000, programs can take advantage of QoS through the QoS APIs in Windows XP. 100% of the network bandwidth is available to be shared by all programs unless a program specifically requests priority bandwidth. This "reserved" bandwidth is still available to other programs unless the requesting program is sending data. By default, programs can reserve up to an aggregate bandwidth of 20% of the underlying link speed on each interface on an end computer. If the program that reserved the bandwidth is not sending sufficient data to use it, the unused part of the reserved bandwidth is available for other data flows on the same host." - Source


13. RAM Optimizers/Defragmenters

Myth - "Increasing the amount of available RAM using RAM Optimizers/Defragmenters improves performance."

Reality - "RAM Optimizers have no effect, and at worst, they seriously degrade performance. Although gaining more available memory might seem beneficial, it isn't. As RAM Optimizers force the available-memory counter up, they force other processes' data and code out of memory. Say that you're running Word, for example. As the optimizer forces the available-memory counter up, the text of open documents and the program code that was part of Word's working set before the optimization (and was therefore present in physical memory) must be reread from disk as you continue to edit your document. The act of allocating, then freeing a large amount of virtual memory might, as a conceivable side effect, lead to blocks of contiguous available memory. However, because virtual memory masks the layout of physical memory from processes, processes can't directly benefit from having virtual memory backed by contiguous physical memory. As processes execute and undergo working-set trimming and growth, their virtual-memory-to-physical-memory mappings will become fragmented despite the availability of contiguous memory." - Source


14. Clearmem

Myth - "Running Clearmem improves performance by freeing up memory."

Reality - "Microsoft's Clearmem, the memory-consuming test tool, is a simulation tool that lets developers measure the minimum working set for a process and to help system administrators isolate cache bottlenecks on servers. Clearmem was originally found on the Windows NT Resource Kit 4.0 CD and can now be found on the Windows Server 2003 Resource Kit. It allocates and references all available memory, consuming any inactive pages in the working sets of all processes (including the cache) and effectively clears the cache of all file data. As Clearmem increases its working set the working sets of all other processes are trimmed until they contain only pages currently being used and those most recently accessed. This reduces the performance of all running applications every time you run this by reducing their amount of available memory, forcing them to needlessly page and causing any cached file data to have to be reread from disk." - Source - Source 2


15. RegClean

Myth - "It is safe to use Microsoft's RegClean."

Reality - "The RegClean utility is no longer supported by Microsoft and has been removed from all Microsoft download sites. This was done for legitimate compatibility reasons with certain applications and Operating Systems. The RegClean utility was originally supplied with Microsoft Visual Basic version 4.0 for Windows. The last version of RegClean was 4.1a (build 7364.1) released on March 13, 1998 (RegClean.exe is dated December 30, 1997). During this time the latest Operating Systems were Windows 95 OSR2.1 and Windows NT 4.0. Windows 98 was not released until June 25, 1998. Compatibility with any Operating System besides Windows 95 and NT 4.0 was never substantiated, especially Windows XP. It is very dangerous to run a Registry Cleaner that was never certified to run on your Operating System since removing the wrong Registry Keys can break Applications and the Operating System. RegClean breaks functionality in the following Applications:

- Microsoft Office XP (Setup)
- Microsoft Office Standard Edition 2003
- Microsoft Office Small Business Edition 2003
- Microsoft Office Access 2003
- Microsoft Office FrontPage 2003
- Microsoft Office PowerPoint 2003
- Microsoft Office Word 2003
- Microsoft Office Professional Edition 2003
- Microsoft Office Student and Teacher Edition 2003
- Microsoft Office Basic Edition 2003
- Microsoft Office Excel 2003
- Microsoft Office Outlook 2003
- Microsoft Office Publisher 2003
- Microsoft Office 2000 Premium Edition
- Microsoft Office 2000 Professional Edition
- Microsoft Office 2000 Standard Edition
- Microsoft Office 2000 Small Business Edition
- Microsoft Office 2000 Developer Edition
- Microsoft Access 2002 Standard Edition
- Microsoft Excel 2000 Standard Edition
- Microsoft FrontPage 2000 Standard Edition
- Microsoft Outlook 2000 Standard Edition
- Microsoft PowerPoint 2000 Standard Edition
- Microsoft Word 2000 Standard Edition

This occurs for any Microsoft Windows Installer product on which the program's installation state is set to Installed on First Use. - Source


16. Registry Cleaners

Myth - "Registry Cleaners improve performance."

Reality - "A few hundred kilobytes of unused keys and values causes no noticeable performance impact on system operation. Even if the registry was massively bloated there would be little impact on the performance of anything other than exhaustive searches." - Source

Notes - "Registry Cleaners can fix problems associated with traces of applications left behind due to incomplete uninstalls. So it seems that Registry junk is a Windows fact of life and that Registry cleaners will continue to have a place in the anal-sysadmin's tool chest, at least until we're all running .NET applications that store their per-user settings in XML files - and then of course we'll need XML cleaners."


17. Set CPU Priority

[HKLM\SYSTEM\CurrentControlSet\Control\PriorityControl] "Win32PrioritySeparation"

Myth - "Setting this value to 26 gives a boost to the priority of foreground applications."

Reality - "This is one of the most useless tweaks since this is already the default and optimal setting in Windows XP. Thus you are changing nothing. The GUI control for this is built-in to Windows. Go to the Control Panel, System Icon, Advanced Tab, Performance - click Settings, Advanced Tab, Processor Scheduling - Programs is the default setting. Choosing the Programs option (26 Hexadecimal) will result in a smoother, faster response time for your foreground program (default and optimal). If you want a background task, such as a Backup utility, to run faster, choose the Background services option (18 Hexadecimal)." - Source

Myth - "Setting this value to 38 gives a boost to the priority of foreground applications."

Reality - "People are confusing the Hexadecimal and Decimal value settings of this Registry Key. By Default Windows XP already sets this value optimally to 26 Hexadecimal = 0x00000026 which is automatically translated to 38 Decimal = (38). This is shown as 0x00000026 (38) in this registry key. The Windows XP Registry Editor defaults to changing the Hexadecimal Value when you go to modify a Registry Key. The problems is it is commonly recommended to change this value to "38" with no mention of this being the Decimal value and instead the Hexadecimal Value is changed because it is the default. This makes the key show 0x00000038 (56). This is not one of this key's functional values and setting a bit field in Win32PrioritySeparation to values other than those shown in the table will result in the default option being selected (26 Hexadecimal). Thus this does absolutely nothing." - Source

Functional Values:
0x28 (0x29, 0x2A)
0x18 (0x19, 0x1A)
0x24 (0x14)
0x25
0x26 (Default and Optimal)
0x15
0x16

No comments :

 

Blogger news

Blogroll

About