Intro Download and install Frequently Asked Questions Tips and tricks

Homepage







© J.C. Kessels 2009
MyDefrag Forum
May 23, 2013, 06:22:35 pm *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1] 2 3 4
  Print  
Author Topic: MyDefrag "battling" W7 system optimizations  (Read 4578 times)
Kasuha
JkDefrag Hero
*****
Posts: 595


View Profile
« on: May 26, 2010, 11:46:22 am »

Every time I run MyDefrag (using my custom script) to optimize my system disk, the system starts doing some heavy file moves as soon as it ends. The next time I run MyDefrag I find there is a whole lot of files moved to previously empty places, MyDefrag moves them away and it all repeats. The problem is, I am not even sure what property do these moved files share and why did the system move them.

This was not happening before on my Windows XP, it only started with W7.

I know that the most obvious answer I can get here would be "disable bootOptimize" or whatever other system service aimed at optimizing the disk performance. Well, I'm not an expert at this. I am not even sure what services regarding disk access optimizazion were introduced to W7 compared to XP. But I can imagine that while most MyDefrag fans would say "stop windows, it screws it up", generally any Microsoft developer would tell me exactly the opposite.

What I'm trying to achieve is to make them to stop battling and rather start cooperating, if it is possible. And as long as I am using a custom script (originated quite a few MyDefrag versions back) I'd like to know what I should change to achieve that. In general, what files and where they should be placed (during MyDefrag optimization) to make system not unhappy with their position?
Logged
Darlis
JkDefrag Hero
*****
Posts: 1707


View Profile WWW
« Reply #1 on: May 26, 2010, 01:26:47 pm »

Disable the Defragmentation service (Start > services.msc). This will prevent Windows to move files around. (if you want to repartition you disk with the Windows diskmanager you have to start the service again).

What kind of files are moved back to the empty spaces? Files indexed by prefetch?
Logged

Need help creating a script? Try MyDefrag Script Creator.
Kasuha
JkDefrag Hero
*****
Posts: 595


View Profile
« Reply #2 on: May 26, 2010, 01:46:54 pm »

Disable the Defragmentation service (Start > services.msc). This will prevent Windows to move files around. (if you want to repartition you disk with the Windows diskmanager you have to start the service again).
From the name I'd guess that the service you're asking me to switch off is defragmenting fragmented files on my disk. That's not what I have problems with, why should I shut it off then?

What kind of files are moved back to the empty spaces? Files indexed by prefetch?
How can I find out?
Logged
Darlis
JkDefrag Hero
*****
Posts: 1707


View Profile WWW
« Reply #3 on: May 26, 2010, 02:51:58 pm »

From the name I'd guess that the service you're asking me to switch off is defragmenting fragmented files on my disk. That's not what I have problems with, why should I shut it off then?
Yes, but that is only a part what this service does. It also rearranges files that are indexed by prefetch (automatically done every 3 days), plus there is a weekly defrag (which you can disable separately). Since you're using MyDefrag to optimize, you don't need this service.

How can I find out?
The following scripts highlights Layout.ini files in light blue, additional files indexed in the *.pf files are in dark blue.
Code:
Title('Highlight')
Description('Highlights Layout.ini files in light blue')
SetFileColor(All,153,153,153)
VolumeSelect
  CommandlineVolumes()
VolumeActions
  SetFileColor(ImportListFromProgramHints("*.pf"),All,0,51,204)
  SetFileColor(ImportListFromBootOptimize(),All,0,204,204)
  Pause()
VolumeEnd
Logged

Need help creating a script? Try MyDefrag Script Creator.
BloodySword
JkDefrag Hero
*****
Posts: 1113



View Profile
« Reply #4 on: May 26, 2010, 02:57:05 pm »

Try this tutorial: http://www.mydefrag.com/forum/index.php?topic=3740.0
Logged

Greetings from Germany!
quanthero
JkDefrag Hero
*****
Posts: 234



View Profile
« Reply #5 on: May 26, 2010, 03:04:59 pm »

Please don't kill me but I think Windows 7 built-in function does better prefetch optimization than MyDefrag, unless one uses SortByImportSequence(Ascending) all the time in MyDefrag.
Logged
BloodySword
JkDefrag Hero
*****
Posts: 1113



View Profile
« Reply #6 on: May 26, 2010, 03:37:57 pm »

But you have to decide: Use Windows Defrag or MyDefrag for the system partition.

The new SkipBlock function will skip a block with already sorted files. This saves not only time, also disk movements while defragmenting and optimizing.
« Last Edit: May 26, 2010, 03:47:30 pm by BloodySword » Logged

Greetings from Germany!
Kasuha
JkDefrag Hero
*****
Posts: 595


View Profile
« Reply #7 on: May 26, 2010, 04:19:21 pm »

But you have to decide: Use Windows Defrag or MyDefrag for the system partition.

Okay it seems you didn't read what I wrote in my original post.
This is exactly what I am trying to solve - I DO NOT WANT to turn my W7 optimization services off. I want to modify my MyDefrag script to stop battling them.

I don't use MyDefrag daily. On XP I was using something similar to the 'daily optimization' once a week and I was completely happy with the result. Now on W7 I feel it might be ok to run it maybe once a month and something slightly more thorough maybe once a year. Still, MyDefrag does WAY more file moves than W7 built-in services and I don't see a reason to do large-scale rearranging of files on my disk too often.

----

Thanks for the script, I'll check my disk as soon as I get to my computer again.
« Last Edit: May 26, 2010, 04:30:07 pm by Kasuha » Logged
Darlis
JkDefrag Hero
*****
Posts: 1707


View Profile WWW
« Reply #8 on: May 26, 2010, 04:53:55 pm »

With disabling the Defragmentation service you don't disable prefetch. You just disable the automatic layout (and the weekly task). And since there is no documentation on how exactly the layout is done, you can't say that the Windows build-in optimizer is better.
And since you don't know how Windows likes to lay out the files, you can't create a MyDefrag script that supports this layout (except for the Defragment only script). Hence, there is more file movement than necessary.
Logged

Need help creating a script? Try MyDefrag Script Creator.
BloodySword
JkDefrag Hero
*****
Posts: 1113



View Profile
« Reply #9 on: May 26, 2010, 05:22:35 pm »

But you have to decide: Use Windows Defrag or MyDefrag for the system partition.

Okay it seems you didn't read what I wrote in my original post.
This is exactly what I am trying to solve - I DO NOT WANT to turn my W7 optimization services off. I want to modify my MyDefrag script to stop battling them.

I remember a regsitry key where you can set the location of the optimize area of the windows defragmenter. But I don't know wich numbers are used. Clusters, KB, or Bye?! Who knows. I think your wishes are impossible, sorry.

I don't use MyDefrag daily. On XP I was using something similar to the 'daily optimization' once a week and I was completely happy with the result. Now on W7 I feel it might be ok to run it maybe once a month and something slightly more thorough maybe once a year. Still, MyDefrag does WAY more file moves than W7 built-in services and I don't see a reason to do large-scale rearranging of files on my disk too often.

You are dealing with Drive Livespan improvements of 2 or 4 weeks... It is not a good idea to prefer the windows defrag then...
Logged

Greetings from Germany!
Darlis
JkDefrag Hero
*****
Posts: 1707


View Profile WWW
« Reply #10 on: May 26, 2010, 05:38:59 pm »

I remember a regsitry key where you can set the location of the optimize area of the windows defragmenter. But I don't know wich numbers are used. Clusters, KB, or Bye?! Who knows. I think your wishes are impossible, sorry.
If you mean the values LcnStartLocation and LcnEndLocation under the key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Dfrg\BootOptimizeFunction: 1. these are just for information and 2. not present under Win7.

You are dealing with Drive Livespan improvements of 2 or 4 weeks...
I wonder where you got these numbers from?
Logged

Need help creating a script? Try MyDefrag Script Creator.
BloodySword
JkDefrag Hero
*****
Posts: 1113



View Profile
« Reply #11 on: May 26, 2010, 05:46:46 pm »

Quote
If you mean the values LcnStartLocation and LcnEndLocation under the key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Dfrg\BootOptimizeFunction: 1. these are just for information and 2. not present under Win7.

Gut zu wissen xD (Good to know.)

The critical aspect for the lifespan of a drive is the temperature over a long time (more than 3 hours). The max. temperature should not be exceeded. Movements does not have such a big lifespan degration than the temperature. You only have to look after the temperature. I recommend to not have 50 degrees Celsius over a timespan of 2 hours.
Logged

Greetings from Germany!
Darlis
JkDefrag Hero
*****
Posts: 1707


View Profile WWW
« Reply #12 on: May 26, 2010, 06:47:33 pm »

Well, these are just tips for a longer HD lifespan but do not explain the exact numbers you came up with. What's the formula?

When it comes to HD lifespan guessing, I always say: I could die tomorrow.  Tongue
If I knew the lifespan of my HD I wouldn't have to do backups.
Logged

Need help creating a script? Try MyDefrag Script Creator.
BloodySword
JkDefrag Hero
*****
Posts: 1113



View Profile
« Reply #13 on: May 26, 2010, 08:30:23 pm »

I simply wanted to say: Such effort to mix more than one defragmenter is needless, sinse it would not give longer lifespan or not siginificant.
Backups are a must have for important data, as well as your heart in your chest is a must have for your life!
Logged

Greetings from Germany!
Kasuha
JkDefrag Hero
*****
Posts: 595


View Profile
« Reply #14 on: May 26, 2010, 09:41:19 pm »

Windows built-in defragmenter (and I mean defragmenter only, not that part which optimizes file access) is no worse than MyDefrag's defragmentation (again, just the Defragment() command) - it finds area large enough for the fragmented file to fit in and moves it there. It does nothing with files which are not fragmented. I see no reason to stop using it unless MyDefrag comes with something significantly better, such as option to defragment large files in place.

Edit: okay I've run the script and the light blue files seem to be all concentrated in the beginning while the dark blue ones are kinda all around the disk. That shouldn't be too hard to adapt the script to obey that, thanks for the help.
« Last Edit: May 26, 2010, 10:03:58 pm by Kasuha » Logged
Pages: [1] 2 3 4
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.5 | SMF © 2006-2008, Simple Machines LLC Valid XHTML 1.0! Valid CSS!