Delete (Not clear) Pagefile at Shutdown.
#1
Posted 05 June 2012 - 02:35 AM
But this takes time as the system writes zeros to the pagefile.
Is it possible to completely DELETE the pagefile, in less than one second, so that it can be re-created when the system re-starts?
Batch file maybe?
DEL C:\pagefile.sys ???
But how would you activate it?
#2
Posted 05 June 2012 - 08:08 AM
#3
Posted 05 June 2012 - 12:23 PM
http://www.techrepub...p-pagefile/2216
Pagefileconfig.vbs seems like a more suitable choice.
jaclaz
#4
Posted 05 June 2012 - 01:04 PM
Clearing it will take just as much time as rebuilding it at startup.
Not swearing to it, because I DON'T want to reboot to my XP right now (have deleted PageFile on it's partition).
You would still be "writing" to it (Shutdown or Startup, whichever).
As jaclaz stated, this will probably work. However, note this in the VBS -
"ERROR: The paging file from volume '%1' cannot be deleted."
" At least one paging file must be present."
SO... it implies that you will have to do a "resize" at the least (to ANOTHER volume) and probably boot twice to "reset" it back to the original.
If your intent is to "defrag" it (force it to be contiguous), the best way (IMHO) would be to redefine it on another partition, reboot, defrag the Volume where it USED to be, then, "redefine" it back (it will be "recreated" on reboot). Note the MFT will still cause potential "contig" probs for the PageFile (MFT will not be affected and could "break" Pagefile into minimum two).
Open to massive corrections by others...
#5
Posted 05 June 2012 - 01:19 PM
submix8c, on 05 June 2012 - 01:04 PM, said:
Clearing it will take just as much time as rebuilding it at startup.
Not swearing to it, because I DON'T want to reboot to my XP right now (have deleted PageFile on it's partition).
AFAICR
jaclaz
#6
Posted 05 June 2012 - 03:03 PM
LiveXP, WinPE, LiveLinux, Dual-Boot ANY other OS that can delete from FAT32 (and/or NTFS) that is NOT "using" the one to be deleted in order to delete it. (???).
1 - Boot to Something Else
2 - Delete PageFile-Of-OS-In-Question
3 - Reboot to What-I-Wanted-To-Delete's-OS
4 - "Rebuilt"
Which methods would be faster? Dunno... Still appears to be a "reboot to something" issue...
This post has been edited by submix8c: 05 June 2012 - 03:03 PM
#7
Posted 06 June 2012 - 12:21 AM
#8
Posted 06 June 2012 - 08:30 AM
Copied it from this machine after reading your reply just in case it is not present on mine.
If I set up a second pagefile on a partition, then I can delete one or the other.
#9
Posted 06 June 2012 - 08:32 AM
Ponch, on 06 June 2012 - 12:21 AM, said:
I suppose you could initiate a "chkdsk", then "offline" find the Reg Entry(?), then use that as a sample for a "CMD" to execute?
I'm not really into trying this out. I see no other alternatives. It MUST be deleted SOMEWHERE while the OS has NOT been loaded to the point of CREATING the Pagefile! True or not??? ("Offline" no matter how you want to slice-and-dice the "terminology".)
edit - I have no need for such a function, hence the "trying" comment.
This post has been edited by submix8c: 06 June 2012 - 08:33 AM
#10
Posted 06 June 2012 - 09:11 AM
#11
Posted 06 June 2012 - 09:59 AM
Tripredacus, on 06 June 2012 - 09:11 AM, said:
Are you sure you can't delete it?
One should be able to at-least resize it to something like 70÷120 Mb:
http://www.msfn.org/...o-set-pagefile/
and then clear this latter.
How long will it take?
How long will re-creating/expanding it at next boot?
Somehow I feel that another possibility could be to move it's physical location in the Registry
http://www.annoyance...nxp/t1040090780
or add a new pagefile on another volume.
Quick test (just made).
Starting from a 500-500 pagefile.sys on C: (%Systemdrive%), created through the normal GUI a new 100-100 pagefile.sys on D; and removed the one on C:
You must reboot for these changes to take effect, bla, bla, bla....
Instead of rebooting, ran Unlocker on the C:\pagefile.sys and Unlocked it (at it went "poof"
jaclaz
#12
Posted 06 June 2012 - 10:13 AM
jaclaz, on 06 June 2012 - 09:59 AM, said:
...
Instead of rebooting, ran Unlocker on the C:\pagefile.sys and Unlocked it (at it went "poof").
That "other MSFN topic" you were looking at seems a potentially more viable option... (been watching...)
#13
Posted 06 June 2012 - 12:14 PM
submix8c, on 06 June 2012 - 10:13 AM, said:
Sure but it is 1/5 of the original and it will take roughly 1/5 of the time to be cleared.
Since on this machine I have more than 2 gb of RAM and currently the pagefile is not in use (I am "peeking at around 700 Mb of used memory), I can allright delete the pagefile (on whichever drive it is), this is actually what I have done while I am typing this post.
The "vanishing" is "immediate".
I cannot for a number of reasons reboot right now, so I have no idea what will happen then (if a pagefile will be created at all, if it will be created with the "windows managed settings, whatever).
Please let us not transform this otherwise peaceful thread in the usual "Windows can run without a pagefile vs. No, you d@mn id*** it cannot", or of the "You better leave pagefile managed by windows vs. "NO, it should be 1.5 to 2.0 x your RAM size", "Godzilla vs. King Kong" (and YES, the dinosaur can kick that grown up chimpanzee's @ss all the way to the moon and back with BOTH hands tied behind it's back
jaclaz
#14
Posted 06 June 2012 - 01:07 PM
#15
Posted 06 June 2012 - 01:11 PM
#16
Posted 07 June 2012 - 01:26 AM
Annoyances is on the verge of quitting, btw.
Unlocker it is.
"How to configure paging files for optimization and recovery in Windows XP"
For those who don't know about this article.
http://support.microsoft.com/kb/314482
Ian.
This post has been edited by NATO: 07 June 2012 - 01:35 AM
#17
#18
Posted 07 June 2012 - 09:12 AM
#19
Posted 19 June 2012 - 06:19 AM
So I used pagefile.vbs to delete the Primary drive pagefile (there is one on the 1st logical as well) and it said success! whatever.
So I ran analyse in Defrag and it was still there only it had changed from green to blue.
Unlocker deleted it.
Wonder if there is any way to pin the pagefile to the back of the partition so as to keep it away from the OS files when defragmenting without using Perfect Disk or some other third party defragmenter.
The standard defrag plus the addition of Sysinternals Config does a good enough job.
Diskeeper is to heavy for a 1.0GHz PIII
#20
Posted 19 June 2012 - 07:44 AM
NATO, on 19 June 2012 - 06:19 AM, said:
JFYI, the "old school" method was to create a dedicated partition (possibly on another disk) to ONLY hold the pagefile.
If on another disk, when "hit", it will be way faster than on System partition (or than other partition on same disk).
In any case it will be hit seldom (please read as "never"
jaclaz



Help
Back to top










