Windows 7 - Pagefile on Wrong Drive

Asked By Menno Hershberger on 03-Jan-12 01:52 AM
I have an old HP here with a 60Gb drive, 5 Gb of which is partitioned as
the recovery partition, Drive D. Despite my attempts to move it to Drive C,
pagefile.sys keeps putting itself on D. And it is causing "Disk Full"
errors to appear randomly. The following screen shot shows how I have
everything set. It is interesting also that the recycle bin is on D,
although it is empty. One would think that the restore partition would be
left unmolested as its primary purpose is for restoring the computer at a
later date. There is PLENTY of room on Drive C for the pagefile. Why will not
it go there?

http://mewnlite.com/pagefileonwrongdrive.jpg

--
-- I am out of white ink --


VanguardLH replied to Menno Hershberger on 03-Jan-12 09:49 AM
NOTE: Not a hardware issue.  My reply was submitted only to the Windows
XP newsgroup (i.e., the alt.comp.hardware newsgroup was omitted from my
reply).



Does that mean there is a restore image on the "recovery" partition or
did you copy the install CD over there?  Looks like you copied the
install CD since your Windows Explorer on drive D: is structured like
the file/folder hierarchy of the install CD (and an image recovery
partition will not have a drive letter assigned to it, either).


You do not move pagefile parts.  They exist or they do not exist.


Are we to assume that by "moving" the pagefile (which is really to
delete it) that it was once defined to have a part on drive D:?  If so,
and after setting the D: pagefile to zero (no exist), have you rebooted
the computer?  None of the pagefile settings become active until AFTER a
reboot.

Pressing the Power button  does NOT necessarily equate to a reboot.
Some PCs are setup to go into hibernate mode when pressing the Power
button.  Check the Power Options to see if you enabled the Hibnerate
mode on pressing the Power button.  You must *restart* Windows to effect
the pagefile changes, not reload a prior image from memory.

If the pagefile.sys file remains on drive D: after the reboot, can you
delete it using Windows Explorer?  If so, delete D:\pagefile.sys and
reboot to see if it is still there.


Did you buy this computer as used?  The restore partition should NOT be
visible in Windows Explorer because no drive letter should have been
assigned to it; otherwise, any boob could start using that partition to
install software and store files while deleting the restore image or
special setup files and end up wiping out their ability to restore.  The
HP Recovery Partition should normally be hidden (by not have a drive
letter assigned to it).

http://h10025.www1.hp.com/ewfrf/wc/document?lc=en&cc=us&docname=bph07144#N875
software on a hidden recovery partition on the hard drive."

Yet I found the following article which indicates that a drive letter
may be assigned in some setups:

http://h10025.www1.hp.com/ewfrf/wc/document?docname=c01512976&cc=us&lc=en&dlc=en
the system ..."

Yet what I see shown for files listed on the D: "Recovery" partition
do not match what you show.  They have an image there, not a bunch of
files copied from an installation CD.  That's why I am wondering if you
bought this computer used and the prior owner screwed up by blowing away
the partition and the image so reconstituted a recovery partition from
installation media (CDs).

By the way, have you followed their instructions on how to burn recovery
discs?  If not, how are you going to recover the install-time image of
Windows when the hard disk crashes (and takes all partitions with it)?

Have you hit F11 during bootup to see if their Recovery Manager will
load?  Before you try this, ask another HP user to make sure you are
offered a recovery but it does not start without your permission; i.e.,
you want to see if you can load the Recovery Manager and have it find
its image in the recovery partition, not to actually do a recovery (you
want to see the Recovery Manager can load, find its image file, but then
exit without making any changes).  I do not own an HP desktop computer
so what I have noted above is what I found mentioned by HP.
Menno Hershberger replied to VanguardLH on 03-Jan-12 11:49 AM
Yeah, I know. But the guys in there are pretty lenient... :-)


Yes. Actually "no pagefile" was already selected for drive D the first time
I looked at it. But I toggled it back and forth a couple of times and
rebooted it. Actually I did this *several* times.


I know how to reboot a computer.


No. It will not allow a delete.
---------------------------
Error Deleting File or Folder
---------------------------
Cannot delete pagefile: Access is denied.

Make sure the disk is not full or write-protected
and that the file is not currently in use.


This computer was brought to me for repair. It was in a rebooting cycle in
both Safe and Normal Modes. I used a recovery CD to get in to the Recovery
Console. I ran chkdsk on it. It found and fixed errors. The computer booted
OK after that. No spyware or viruses detected.


This is a Pavilion 533w. F10 is the key to push and it indeed takes you
into recovery mode.


Yes, that is where I am at now.


I did not buy the computer. I am just working on it. I doubt seriously if the
owner "blew" anything away. He's not that computer savvy. He always brings
it to me when he is in trouble.


I seriously doubt if this old of a computer has those options. I cloned the
drive before I ever attempted to do any repairs on it. I always do. That
way if I screw up I still have it as it originally was.


No, but I have hit F10 (as mentioned above) and it does load the Recovery
Manager. So the partition is valid. But I do not need to recover anything.
All I want to do is get the damn pagefile on the C partition where it
belongs!


--
-- I am out of white ink --
BillW50 replied to VanguardLH on 03-Jan-12 12:00 PM
I hope you are referring to this individual case and not generally
speaking. As third party recovery software that at least Gateway was
using used drive D for the recovery partition. Although when you tried
to go in there with Explorer, PC Angel popped up a full screen warning
saying you were not allowed to modify this partition and would not allow
you to even peek in there. Although the software protection was pretty
weak and was easy to crack if you really wanted to.

--
Bill
Gateway M465e ('06 era) - OE-QuoteFix v1.19.2
Centrino Core Duo T2400 1.83GHz - 2GB - Windows XP SP3
Ken Springer replied to VanguardLH on 03-Jan-12 12:37 PM
Hi, VanguardLH


There is at least one Compaq model where the recovery drive/partition has
a drive letter, assigned, and it shows up in Windows Explorer and My
Computer.  I fixed one of these for a friend of mine about a year ago.

Like Menno's friend, the owner of the Compaq were not terribly computer
literate, so they had written a few files to the drive but not enough to
cause any problems.  The owner definitely knows more now than he did.  :-)


--
Ken

Mac OS X 10.6.8
Firefox 9.0.1
Thunderbird 9.0.1
LibreOffice 3.4.4
Paul replied to Menno Hershberger on 03-Jan-12 12:48 PM
You can boot a Linux LiveCD and you will definitely be able to "test delete"
the pagefile on the disk in question. If Windows has a fixation with it,
Windows will re-create the pagefile soon after the system starts. The beauty
of Linux is (so far) they make light of the Windows rules for things. it is
a perfect maintenance environment, from that perspective.

It could be, even though Windows is not using the file, it has a file
attribute of "system" and that is why Windows will not allow you to delete it.
You could check the properties of the file, and see what can be arranged.

*******

As far as I know, the pagefile settings are stored in the registry. You can
use regedit to verify the settings.

HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Session Manager\Memory Management

PagingFiles  REG_MULTI_SZ        <--- I think this means multiple strings
can be stored in there
C:\pagefile.sys 2046 4092        <--- My pagefile is still on C:
I have only one line stored in this
registry area.

*******

The recovery partition is probably supposed to be a "hidden" partition.
There is a trick, where they add "10" to the hex number for the partition
type, and that is supposed to tell Windows not to mount that partition.
You generally do not want any kind of fresh writes going to a partition
like that. It contains a copy of a "factory restore" for the computer.
I have even heard of cases, where people have managed to cause System Restore
to dump crap in there (restore points), if the partition is made visible.

http://www.win.tue.nl/~aeb/partitions/partition_types-1.html

0c WIN95 OSR2 FAT32, LBA-mapped
1c Hidden WIN95 OSR2 FAT32, LBA-mapped

That's not a rule you can apply blindly, it is just to illustrate the
tricks they apply to the partition type field. They really should not
do that, but that is the scheme applied in some cases, to hint to
the OS that it should not mount a partition. For example, it might not
prevent a Linux OS doing a scan to populate /etc/fstab, from looking in
there. Partition types can be determined by reading a partition, as
well as honoring the value stored in the type field.

Virtually the only way to stop software from meddling with SATA or IDE
disks, is to unplug them. I have tried all the other tricks (even disable in
BIOS does not work). If you must stop software from writing to one of
those disk types, unplugging the drive, always works... (With SCSI,
there used to be a write protect jumper, and that was absolute.)

To check the partition type field, you can use PTEDIT32, available free.

ftp://ftp.symantec.com/public/english_us_canada/tools/pq/utilities/PTEDIT32.zip

This is what the tool output looks like. The partition types are on the left.
The four primary partitions are shown in this example, and only three
entries are defined (the fourth is empty). The boot flag is set on the
second partition (typically important to Windows, but not to all OSes, as
this is a "hint" checked by the MBR bootstrap code).

http://www.vistax64.com/attachments/vista-installation-setup/7308d1224108918-hidden-partiton-recovery-dell-xps-420-dell-tbl.gif

Have fun,
Paul
Char Jackson replied to Menno Hershberger on 03-Jan-12 02:41 PM
Silly question, perhaps, but are you remembering to click "Set" after
you make a change?

I remember that screwing me up back in the Win98 days.
Char Jackson replied to Ken Springer on 03-Jan-12 09:07 PM
I bought a mid- to higher-end HP laptop just before Christmas and it
came with a small D:\ volume called "Recovery". In addition to a set
of large image files in that volume, there are also hundreds of
smaller files making up a set of tools for resolving various issues.
I'd prefer that volume to be unlettered, but so far I have just left it
alone.
VanguardLH replied to Menno Hershberger on 04-Jan-12 01:34 AM
And I would know you are a techie how?  Nothing in your starting post
indicates you are repairing this computer for someone else and instead
presents it as YOUR computer.  And, yes, there are LOTS of users that
think hitting the Power button on the case will power down the computer
(and do not have a clue what is hibernation).

So now we have some more details.  Don't expect anyone to know your
level of expertise other than what is stated in your posts.


But if the recovery partition is not hidden then just the user seeing the
drive D: and using it means they can "blow away" anything that is there.
I have seen users edit .exe files with Word and wonder why the program
will not run anymore.  They do not have to be savvy to be corruptive.
Non-savvy users do most damage because they do not know they cannot do
something.  If the user is not supposed to have access to a partition
then that partition really should not be visible to the user.


HP's file download for the manual on the Pavilion 533 will not respond
(http://h10032.www1.hp.com/ctg/Manual/bph07919.pdf) so I cannot see if it
mentions how to create the recovery CDs.  However, every HP, Compaq, and
Dell that used a recovery partition that I have worked on before had
instructions on how to create the recovery CDs so you could use those
when the hard disk crashed and wiped availability for both the OS and
recovery partitions.

Since the recovery partition seems to be just a copy of the install CD,
maybe you can just burn it onto a CD.  While the user might have a legit
license, it does not do the install.  Hard disks die eventually.


Will Disk Management (diskmgmt.msc) let you NOT assign a drive letter to
that partition (the one now marked as D:)?  That is, can you remove the
drive letter assignment from the recovery partition?  If so, remove the
drive letter, reboot, and check if the pagefile is still listing D: to
include a part of it.  It should not because now there is no D: drive.

If diskmgmt.msc will not let you remove the drive letter assigned to the
recovery partition (D:) because it is in use by the system, see if you
can boot into Recovery Console mode and use diskpart to remove the drive
letter assignment.

diskpart
help
list volume
select volume <n>
detail volume
remove letter=D
exit

You want to set focus on the recovery partition (disk n, partition m) by
selecting the volume for that partition (I am assuming there is no
spanning or dynamic disks involved).

Read: http://technet.microsoft.com/en-us/library/cc766465(WS.10).aspx

Once you get rid of the drive letter assigment, reboot into normal
Windows and look at the pagefile setup.  Since D: no longer exists, it
will not be listed as having an extent of the pagefile.

At this point, you could leave the recovery partition hidden by not
having a drive letter assigned to it.  If you want to check if the
pagefile setup might use D: again, use diskmgmt.msc to assign D: to the
recovery partition, make sure pagefile still shows just the C: drive has
a pagefile extent defined, and reboot to check the pagefile did not
magically add an extent on the D: drive.  If not, you are done (other
than perhaps deleting the old pagefile.sys file still on the D: drive).