BDBits Bytes

Entries from April 2008

Reclaiming space on a Windows boot disk

April 23, 2008 · Leave a Comment

Where I work we have a number of older servers with limited space on the boot disk (normally C:). Here are some things I have found to help recover that space. Going through these things on a server that nearly filled up the C: drive this morning netted me around 2G of recovered space. Note: I am assuming your system is in a normal running state, you do not have installs waiting for a reboot, and you are the only one logged on.

  • Check C:\Windows\Temp and delete everything that isn’t in use. Windows Explorer will tell you it is in use when you try to delete it.
  • C:\Windows\PCHealth\ErrorRep\QSIGNOFF has two folders, QSIGNOFF and UserDumps. These hold error reporting and crash dump files, which can get quite large – on this server it was well over a gigabyte of space. Not only can you delete these, you can prevent them from accumulating. Get properties on “My Computer”, go to the Advanced tab and click Error Reporting. Disable error reporting and click OK.
  • You can delete “C:\Windows\system32\wbem\Logs\FrameWork.log. This file can get pretty big, on this server it was over 250M. That may not sound like much but when you’re desperate for space, every little bit helps.
  • You will find a number of $NtUninstallKB999999$ folders in C:\Windows. These are from Windows patches and are only required in the unlikely event you would want to uninstall a patch. If that is not a concern, you can delete them. If you think you might someday need them, just move them to another drive in a folder you’ll remember, say \Uninstall. :) Unfortunately you may need to do this on a periodic basis as patches are installed.
  • You can move the system paging file to another drive, but you should think about what if any impact this might have on performance for both Windows and the applications and files on the drive you are moving it to. Changing it will also require a reboot to take effect. To change paging files, go to My Computer properties on the Advanced tab and click Settings under Performance, then the Advanced tab there and finally click Change.
  • Do a Windows search and look for all files over 1M. You will have to use your knowledge and experience to know what to do with the results; if you are not sure then don’t delete it!
  • You may want to open the Control Panel’s Add or Remove Programs and look for things you know you no longer need. Same goes for Add/Remove Windows Components.
  • Delete unnecessary user profiles. You can do this easily by clicking Settings under User Profiles on the Advanced tab on My Computer properties.
  • For remaining user profiles, clean out C:\Documents and Settings\%username%\Local Settings\Temp, which is normally their working %temp% space when logged in. But, be careful about doing this for user profiles that do not represent people, e.g. NetworkService. Such “users” may be actively using those folders.
  • You might want to also look at C:\Documents and Settings\%username%\Desktop (their desktop) and C:\Documents and Settings\%username%\My Documents (their My Documents). I know I am guilty of putting installers and the like in these locations and forgetting to delete them when finished, and some can run into hundreds of megabytes.
  • C:\Documents and Settings\%username%\Local Settings\Temporary Internet Files is another possibility, as that is where IE caches files. Unfortunately they can be hard to “see”; you will need to be sure you have Folder options set to show hidden files and folders and have not checked Hide protected operating system files.
  • It’s easy and perhaps obvious, but don’t forget to empty the Recycle Bin.

Categories: Microsoft Windows

Clipboard from the keyboard

April 18, 2008 · Leave a Comment

I run into a lot of cases where you can select some content, like error message text, but you have no menu – even a right-click context menu – for cut, copy, and paste to capture the information to use in another application like email. (Yes, you can screenshot it, but that is an ugly approach at best.) Fortunately, if you can select it or type it, you can probably use keyboard equivalents to access the clipboard without the application having had to provide any mechanism to let you do so.

To do this

Use this
Copy Ctrl-C
Cut Ctrl-X or
Shift-Delete
Paste Ctrl-V or
Shift-Insert

I find this extremely useful, particularly in technical situations where I need to capture a crucial bit of information in order to troubleshoot a problem or submit the error to a vendor.

Categories: Fundamentals · Microsoft Windows

Windows cut, copy, and paste

April 4, 2008 · Leave a Comment

A Windows clipboard can be thought of as a holding place for something that exists on your system. For example, it can hold a snippet of text, the names of on or more files, or a graphic image like a screenshot. This article is about moving things in and out of this holding place. First, a few terms.

To copy something means you are not going to alter or remove the original text, files, or graphics; you merely copy them into the clipboard. To cut on the other hand means that your intent is to remove the source material, either before or after pasting it. To paste means to insert the contents of the clipboard into whatever currently has focus, be that a document or a folder like My Documents. If my definition of the terms seems a little vague, that is partly because cut, copy, and paste are concepts that apply to a variety of situations. The mechanics are going to vary somewhat by what it is you are cutting, copying, or pasting, and even perhaps the application you are using. Bear with me, and hopefully this will become clearer to you.

Let’s start with an example using text. Create a new document in Wordpad, Microsoft Word, or any other text-oriented application and type a few lines of text. Now you need to select some text. To do so you can hold down the left mouse button while dragging the mouse pointer across the text. In many cases, you can also put your cursor at one end of the text and hold down the Shift key, then press the arrow keys to select the text. Once the text is selected, we want to copy the text to the clipboard. In many cases, there will be an Edit menu with options to Copy, Cut, and Paste. Choose Copy. If there is no Edit menu, there is a Windows standard equivalent, which is to hold down the Ctrl key while you press the C key. This is often referred to as using Ctrl+C, where the first key is held while the second key is pressed. This method will generally work even when the application does not provide any other means to copy anything to the clipboard.

Now move your cursor to some other point in the document, like the very end. If you have an Edit menu, you should now be able to choose Paste, or use Ctrl+V and the text you copied will magically appear. Note that you can perform the paste many times if you like; the contents of the clipboard remain there indefinitely, typically until replaced by another copy or cut.

Now select some more text. This time, after selecting the text, use the Edit menu and choose Cut, or use Ctrl+X. Your text will disappear! This highlights the difference between copy and cut – cut removes the original selection. Pasting the text without changing your current position in the document will paste the text back in, essentially undoing your cut. If you position your cursor where you want to put the text and then paste, this is effectively moving the text from one spot to another. As with the copy operation, you can paste the text you cut many times.

Using this with graphics is very similar. While programs like Microsoft Paint, included with Windows, will let you select graphics and copy or cut them to the clipboard, copying what is on the screen is perhaps a more common example. Look for a key labeled PrtScn or perhaps spelled out as Print Screen. When you tap this key it will copy the contents of whatever is on your screen to the clipboard. If you hold the Alt key when you tap PrtScn, you will copy just the contents of the active windows.

Now open a program that lets you use images, e.g. Microsoft Paint. If present, use the Edit menu and choose Paste or use Ctrl-V. You should now see in your document a copy of what was on your screen.

These same concepts can apply to many different bits and pieces of documents. For example, you can select a range of cells in Microsoft Excel and paste them into a Word document, or select part of a picture you downloaded from your camera and paste it into a Microsoft Outlook email to send to someone. You can also do this with files or folders. When you select then cut or copy the files or folders, the names of your selection are held in the clipboard. If you do a copy, the original files/folders will remain; a paste will move the files/folders. Note that unlike text or graphics, cutting files will not make the originals disappear. I presume this is because it would be alarming to see all your files disappear, and the sheer size of a file or an entire folder’s contents could be much more than the clipboard can hold.

I hope this was useful to you. Personally I think the clipboard is one of the most useful features for any operating system like Windows, and I find it indispensable.

Categories: Fundamentals · Microsoft Windows