Intro Download and install Frequently Asked Questions Tips and tricks

Homepage







© J.C. Kessels 2009
MyDefrag Forum
May 22, 2013, 09:27:04 am *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Overriding the zones  (Read 3553 times)
fbg
Newbie
*
Posts: 2


View Profile
« on: June 08, 2008, 11:22:41 pm »

Hello,

I am working on a new command line option, which allows the user to override the zones, i.e., specify the start cluster for the 3 zones. This can be used to keep manually selected directories together without having to reorganize the whole (big) HDD every time.

Status

I have an option "-z ZONE1:ZONE2:ZONE3" which overrides the start clusters of the 3 zones.

This works fine with the sorting mode (-a 7 etc.) to keep a selected bunch of files close together. The other modes have not been looked at and will probably not work in a useful way right now.

The code is in an unclean state (debug messages, missing error handling); I may clean it up and publish it here if someone voices interest.

Plans

- Either: improve the other, non-sorting modes so they work in a useful way (for example "move every file that was not selected for the zone out of it").

- Or: create a text config file which allows to specify an unlimited amount of zones. For each zone, the boundary can be specified, as well as the behaviour (-a) and a selection of files. Then, a minimum run would consist of simply moving each file into the zone it belongs to, and then run the selected algorithm for each zone, making sure files do not get vacated out of the zone in some way.

Example config file approaching the current behaviour:

Code:
[0]                   # Zone 0
start=1               # Starts at Lcn 1
size=auto             # Number of clusters is calculated
+ C:\ [d]             # Add all directories

[1]                   # Zone 1
start=auto            # Starts at the next cluster after the previous zone
size=auto             # Number of clusters is calculated
+ C:\ [f]             # Add all files

[2]                   # Zone 2
start=auto            # Starts at the next cluster after the previous zone
size=auto             # Number of clusters is calculated
+ C:\ [h]             # Add all spacehogs

Another example file which would be useful to me:

Code:
[0]                   # Zone 0
start=1               # Starts at Lcn 1
size=2M               # Number of clusters is calculated from the megabyte spec
+ C:\ [d]             # Add everything of type "directory"

[1]                   # Zone 1
# start=auto          # (Default) Starts at the next cluster after the previous zone
size=10G              # 10 Gigs of space
+ C:\x                # Add some subtree (directories+files)

[2]                   # Zone 2
# start=auto          # (Default) Starts at the next cluster after the previous zone
size=15G              # 15 Gigs of space
+ C:\y                # Add some subtree

[3]                   # Zone 3
# start=auto          # (Default) Starts at the next cluster after the previous zone
size=100G             # 100 Gigs of space
+ C:\ [f unclass]     # Add all files that are not yet in some other zone

[4]                   # Zone 0
# start=auto          # (Default) Starts at the next cluster after the previous zone
# size=auto           # As it's the last zone, it goes to the end of the disk
+ C:\ [s zone=3]      # Add all spacehogs from zone 3

The second plan sounds very appealing to me, though I do not know if I will have enough time for it.

Opinions are welcome.


« Last Edit: June 10, 2008, 10:21:09 am by fbg » Logged
jeroen
Administrator
JkDefrag Hero
*****
Posts: 7155



View Profile WWW
« Reply #1 on: June 11, 2008, 06:01:27 am »

Are you aware that I am currently working on v4 of JkDefrag, which will already have something like this?
Logged
Pages: [1]
  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!