Boot time defragmentation

Hi All

I tried and succeeded in defragmenting a file using the FSCTL_* control
code.
Now I would like to try the same at boot-time.
Effectively I want to defragment the page file during boot time.

Could you please point me in the right direction as to from where I should
start learning.
Links and pointers to the docs and samples would help,

Thanks in advance for the help,

Cheers
Ramananda

http://www.microsoft.com/technet/sysinternals/information/NativeApplications.mspx

Ramananda Ramachandra wrote:

Hi All

I tried and succeeded in defragmenting a file using the FSCTL_* control
code.
Now I would like to try the same at boot-time.
Effectively I want to defragment the page file during boot time.

Could you please point me in the right direction as to from where I should
start learning.
Links and pointers to the docs and samples would help,

Thanks in advance for the help,

Cheers
Ramananda


Questions? First check the IFS FAQ at https://www.osronline.com/article.cfm?id=17

You are currently subscribed to ntfsd as: xxxxx@comcast.net
To unsubscribe send a blank email to xxxxx@lists.osr.com

Thanks Matt. Your help is highly appreciated.
Its a great link and it helps.

Is there a link or location where I can find information about the
undocumented native APIs that the article is talking about.

Cheers
Ramananda

“MM” wrote in message news:xxxxx@ntfsd…
> http://www.microsoft.com/technet/sysinternals/information/NativeApplications.mspx
>
> Ramananda Ramachandra wrote:
>
>>Hi All
>>
>>I tried and succeeded in defragmenting a file using the FSCTL_* control
>>code.
>>Now I would like to try the same at boot-time.
>>Effectively I want to defragment the page file during boot time.
>>
>>Could you please point me in the right direction as to from where I should
>>start learning.
>>Links and pointers to the docs and samples would help,
>>
>>Thanks in advance for the help,
>>
>>Cheers
>>Ramananda
>>
>>
>>—
>>Questions? First check the IFS FAQ at
>>https://www.osronline.com/article.cfm?id=17
>>
>>You are currently subscribed to ntfsd as: xxxxx@comcast.net
>>To unsubscribe send a blank email to xxxxx@lists.osr.com
>>
>>
>

In that link, I didn’t see a link too the sample project, but if you
search archive.org with sysinternals, the source is there.
That is just a simple shell program though, but it’s structure is
correct and helps a little…

I assume the defrag api’s should work at this phase in the boot process.
The only native api I figure you would need
would be NtCreateFile, NtCloseFile, and NtDeviceIoControl - all of which
can easily be found with a quick google
search.

Ramananda Ramachandra wrote:

Thanks Matt. Your help is highly appreciated.
Its a great link and it helps.

Is there a link or location where I can find information about the
undocumented native APIs that the article is talking about.

Cheers
Ramananda

“MM” wrote in message news:xxxxx@ntfsd…
>
>
>>http://www.microsoft.com/technet/sysinternals/information/NativeApplications.mspx
>>
>>Ramananda Ramachandra wrote:
>>
>>
>>
>>>Hi All
>>>
>>>I tried and succeeded in defragmenting a file using the FSCTL_* control
>>>code.
>>>Now I would like to try the same at boot-time.
>>>Effectively I want to defragment the page file during boot time.
>>>
>>>Could you please point me in the right direction as to from where I should
>>>start learning.
>>>Links and pointers to the docs and samples would help,
>>>
>>>Thanks in advance for the help,
>>>
>>>Cheers
>>>Ramananda
>>>
>>>
>>>—
>>>Questions? First check the IFS FAQ at
>>>https://www.osronline.com/article.cfm?id=17
>>>
>>>You are currently subscribed to ntfsd as: xxxxx@comcast.net
>>>To unsubscribe send a blank email to xxxxx@lists.osr.com
>>>
>>>
>>>
>>>
>
>
>
>—
>Questions? First check the IFS FAQ at https://www.osronline.com/article.cfm?id=17
>
>You are currently subscribed to ntfsd as: xxxxx@comcast.net
>To unsubscribe send a blank email to xxxxx@lists.osr.com
>
>
>

hello mr ramachandra…!!!

did u get that program with the code…??

seems it removed from the archive tooo…

if u get that …will u plz send me tooo…!!

thank u…

:slight_smile: