Partition holding temporary folder failed on Windows XP, how do I deal with it?

3

I have a Windows XP box and on boot it first complained that there was no bootable disk. After checking the power connections to the drives and they all checked out, I tried booting again and it did so, but very slowly. Eventually Windows started but it was extremely slow, like minute-per-click slow.

After doing a lot of tests and diagnostics, I figured out that the problem was that something was wrong with the partition that holds the temporary files. I have my main drive (the one with the OS on it) in several partitions. One has the OS itself, another has application files, and a third has a single folder which is for temporary files. In Windows XP, the location of the temporary folder is indicated by two environment variables (TEMP and TMP).

So, I made a new "temp" folder on a completely different drive and pointed those two variables to that new folder and rebooted. The machine then started and behaved normally.

I have no doubt that the failure of the old temp partition was because my browser writes and rewrites zillions of files to that folder constantly.

So, now my problem is that I have essentially a dead/toxic partition. For example, if I try to open the Temp drive using Multicommander, then the whole application freezes up. Since this partition is on the same drive as the main OS, it makes me nervous. The question is how to deal with this toxic partition.

My first inclination is to add a whole new drive to the machine, boot the machine using Knoppix, then copy the Windows System partition to the new drive using dd, then delete the old temp partition. Basically this will ghost my existing OS (and all its registry settings to the new drive, so I can hopefully boot the machine from the new drive. One issue might be a drive letter assignment could screw things up.

Anyway, exactly what the best procedure here is not clear to me. How can I deal with this toxic partition and set things up, so a similar problem will not occur in the future?

Tyler Durden

Posted 2018-08-12T20:25:11.087

Reputation: 4 710

2Before you do anything else: Make a backup. – confetti – 2018-08-12T21:09:16.573

@confetti Yes, I am doing that. It is currently 18% complete on one drive and due to complete in 6 hours. So, it will take another day or two to make all the backups. I need a plan though for my steps as soon as the backups are done. – Tyler Durden – 2018-08-12T21:28:41.043

1Your suggested plan to clone the drive is the best course of action IMHO. This enables you to save as much data as possible without losing your settings or customizations. – I say Reinstate Monica – 2018-08-13T00:42:51.383

If you have another drive of the same size or larger than the drive with the partition with the issue, then use Clonezilla and do a device to device/disk to disk clone and it will basically mirror the new drive with all partitions, MBR, etc. from the old drive, and then once it completes, just power off the machine, plug in the new drive where the old drive was before, and then boot it up. Hopefully your backups completed finally and you have that stored somewhere accessible if needed. You might consider running chkdsk against the trouble partition on the trouble drive too if you haven't. – Pimp Juice IT – 2018-08-16T13:18:42.393

A drive that had a hard failure should not be trusted, so moving to a new one is the best solution. The old one may be reused at your risk after a slow reformat (meaning not quick) which will re-magnetize all sectors and their addresses, but pay attention to the bad-sectors count. – harrymc – 2018-08-16T18:11:12.350

Tyler - I guess I didn't send you the link but after you get your backups completed and have a new larger HD which you can use for the replacement, simply follow these instructions: https://clonezilla.org/show-live-doc-content.php?topic=clonezilla-live/doc/03_Disk_to_disk_clone. I'm pretty certain you do not need to format or reformat or create or delete partitions on the replacement drive beforehand but if you want feel free to do so but I believe it's not needed for disk to disk as target disk will have source image pushed to it and replace the target's original content with this image.

– Pimp Juice IT – 2018-08-17T02:53:03.077

Answers

1

After making a full disk backup, you could try using GParted Live to delete the partition, and optionally create a new partition in the same space or move and resize the remaining two partitions to fill the entire drive. GParted Live is a simple usb-bootable Linux distribution designed specifically for creating, deleting, moving, and resizing partitions on your main boot drives. Using this type of bootable utility on an external USB is preferable because it allows us to format partitions on your boot drive without having to worry about


Installing GParted Live to a USB Stick

The easiest way to install GParted Live to a USB is to use Tuxboot, a tool for installing utilities like Clonezilla Live and GParted Live to USB. Here's a direct download link for Windows. First, you need to prepare your USB stick. Open Disk Management from the start menu, select your usb stick, and erase all partitions on it. Next, create a new partition formatted as FAT32. Open the Tuxboot executable, select gparted-live-stable in the top left drop-down menu, click update, and select the latest version available for AMD64 Architectures. Next, select your USB drive letter at the bottom, and click OK to begin installing.

Next, boot into your USB (specific instructions will vary here based on your motherboard), Select "GParted Live (Default Settings)", hit enter a few times at the prompts, and then the GParted application will pop up.


Rundown on How Linux Handles Hard Drive Partitions

Since the utility we will be using is actually a basic Linux OS, we'll need to understand some things about the way Linux handles hard drives and partitions. In Windows, each mounted drive partition is assigned a letter - C: for your boot partition, D: for the next one, and so on. Each letter corresponds to only one partition, and there is no notation for what drive the partition is on.

Things work differently in Linux. Each drive, regardless of how many partitions are on it, is assigned a "logical name" that follows this pattern: /dev/sda for the first drive, /dev/sdb for the second, and so on. These logical names are actually paths to files that represent the drive's raw data - /dev/ is the folder they are stored in, and sda is the filename for "scsi drive A".

Likewise, partitions have logical names as well, following this pattern: /dev/sda1 for the first partition on the first drive, /dev/sda2 for the second partition on the first drive, /dev/sdb1 for the first partition on the second drive, and so on. Now that you understand a few things about how drives and partitions are identified, you can get on to reformatting your drive.


Deleting Your Corrupted Partition

At the top right of the GParted window, you will see a drop down menu that says /dev/sda. This menu is for selecting different storage drives. Since you said your corrupted partition is the last partition on your main drive, you likely won't need to change this to a different drive. Below the toolbar, you will see a visual representation of the drive's partition order and relative sizes, and below that a list of all your drive's partitions. To delete the faulty partiton, select it at the bottom of the partition list, then hit delete. Press the apply button in the toolbar to run the command. You should now have a bunch of empty space at the end of your drive.


Creating a New NTFS Partition

To create a new partition, click the "New" button in the toolbar. Use the sliders to resize the partition however you like. Don't touch any of the options on the left, but on the right you should set "Partition Name" and "Label" to the same value, which should be the name of your partition. ("Temp" or the like in your case.) Also change the "File System" drop-down menu to NTFS, or alternatively FAT32 if you need the partition to be writable by other OS's. Click next once you are done, then click "Apply" in the toolbar to write the changes to your disk.


Resizing Your Existing Partitions

If you choose to resize your existing partitions to fill the drive instead of simply recreating your temp partition, things get a tad bit more complicated. In order to expand your boot partition, you will first need to move your Application Files partition to the right in order to make room for the boot partition to expand. Select your rightmost partition and select "Resize/Move" in the toolbar. Drag it all the way to the end of the drive, then optionally expand it to the left, leaving enough space for your other partition(s) to expand. You should NOT create any new partitions in the newly-created empty space, as this could break things very easily.

Before you click apply, you should also queue the the resizing of any other partitions on the drive, as this will take some time. Select the partition just to the left of the partition you just moved, and move/resize it as you wish.

Repeat this step until you get to your boot partition. This partition should not be moved, as this can make the drive not bootable. You may, however, expand the partition to the right without moving it.

Once you have queued all your move/resize commands, hit "Apply" to write all the changes to the disk.


Hope this helps! Let me know if you have any issues or questions.

Next-Door Tech

Posted 2018-08-12T20:25:11.087

Reputation: 622

Okay, that makes sense. I have two questions: (1) If I want to move everything to a new drive, does the live boot have the ability to copy from the old disk to the new disk. (2) What about drive letters? For example, if I set up the new partitions and copy the C: from old to new, fine, but what if my applications drive (on its own partition currently) which is currently the E: drive becomes the D: drive in the new setup? Then won't everything be screwed up because all my icons and registry settings are pointing to paths starting with E:, not D:? How do I handle this? – Tyler Durden – 2018-08-19T12:07:57.150

>

  • No, GParted live does not have an easy way to copy data from drive to drive. It can be done through the terminal, but that's a bit involved. I think the best way to do this is to use Clonezilla Live, which is a similar, again Debian based, tool for, well, cloning drives. It's a bit involved as well, but you should be able to find a youtube tutorial for cloning one drive to another.
  • < – Next-Door Tech – 2018-08-20T15:43:15.920

    start="2">

  • I'm not so sure on this part - I know you can change drive letters in Windows, but I don't know where the letters are stored for the OS or if they will be changed when the drive is cloned. If they are changed, you may need to change back the D: drive to E: in windows to fix your setup.
  • < – Next-Door Tech – 2018-08-20T15:47:51.697

    There are hundreds of pointers to drive letters. For example, every single application executable and icon, of which there are dozens, plus hundreds of registry entries have paths in them and those paths use drive letters, so it is essential that the drive letter mappings be maintained correctly if a drive with multiple parititions is replaced. – Tyler Durden – 2018-08-20T20:44:29.507

    0

    You should first make a backup of your data, or better of the whole drive.

    As your temp partition contains only temporary files that you don't need, the simplest solution would be to format that partition to get rid of the files. After that you should be able to use the partition again.

    RalfFriedl

    Posted 2018-08-12T20:25:11.087

    Reputation: 1 370