Optimizing raw Windows partition backup - Summer Glau






Optimizing raw Windows partition backup

I was going to do some experiments with Windows the other day. I do not use it much so I'm fine with complete reinstall. But after reinstalling it from CD, installing all updates, and tuning some settings I realized that it may be a good idea to look for another way of having a "clean" system set up and running. The obvious solution: use a "dd" command from your favorite *nix to copy raw partition on an external disk and then copy it back when you need it. The only problem: my Windows partition is 150GB and it almost empty (just installed and updated system), so the idea of wasting 150GB of my drive did not excite me. Of course I may try to compress that image but the blocks from unused space will most likely contain some random data (that partition was approx. 30GB before I started my experiments) and the compression may not be very efficient at this point. So the next step is to try to find a utility that will clean up partition by writing some simple pattern into all unused blocks. After a little googling I found an excellent solution: Eraser (http://www.heidi.ie/eraser/).

So I installed it but it needs an administrator account to write to empty blocks. At first I could not find a way to log in as administrator but Google was very helpful as usual: I had to start a command shell and run the following command

Code
net user administrator /active:yes


Important: do not forget to set up a password after you log in as administrator or anyone who have physical access to your computer will be able to log in as administrator without password.

After the administrator account was set up I proceeded with "Eraser" utility... just to find out that all built-in writing methods use random data because this utility was designed for security, not for optimizing data compression. At this point I had to read manual and the solution was found! Click on "Setting" link

Settings panel
scroll that window to the very bottom and right-click on "Default Erasure Methods and PRNGs" to open a settings window:

Erasure method

Then click on "Custom Erasure Method" tab and click "Add Method" button:

Add new method

In a new window type a name for a new method, click the "Add" button to add a pass and in a pass settings select "Text" and in a text field just type a single space:

Settings panel

Close all windows but the last one by clicking the "Ok" button. In the main window scroll back up and click the "Save Settings" button. You may also want to set "Spaces" as default method like you may see it in the first screenshot.

Now go to the "Erase Schedule" and click the small triangle arrow to click a "New Task" menu item:

New Task

In a "Task Properties" window click an "Add Data" button:

Task Properties

and in a "Select Data to Erase" make sure to select a new "Spaces (1 pass)" method and "Unused disk space - Local Disk C:" option:

Select Data to Erase

Now you may run that task. It will take a while and after that you may reboot into your favorite *nix to make backup.

Here is how my hard drive looks like:

Code
# fdisk -l /dev/sda

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xa6a46671

  Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 7 HPFS/NTFS
/dev/sda2 14 19595 157292415 7 HPFS/NTFS
...


I do not show remaining partitions as they are not important. Also I've already mounted an external hard drive into "/mnt/backups", so I may execute commands:

Code
# dd if=/dev/sda1 | gzip -1 > /mnt/backups/win7_sda1.gz
...
# dd if=/dev/sda2 | gzip -1 > /mnt/backups/win7_sda2.gz
314584830+0 records in
314584830+0 records out
161067432960 bytes (161 GB) copied, 2886.13 s, 55.8 MB/s

"/dev/sda1" is a small boot partition so I do not care about it. Now let's look what we have:

Code
# ls -lh /mnt/backups/win7_sda2.gz|awk '{print $5}'
9.8G


So the ~150GB partition was packed into a less than 10GB file. Looks good to me smile

Now let's make sure it works:

Code
# zcat /mnt/backups/win7_sda1.gz |dd of=/dev/sda1 bs=512k
...
# zcat /mnt/backups/win7_sda2.gz |dd of=/dev/sda2 bs=512k
567+4792245 records in
567+4792245 records out
161067432960 bytes (161 GB) copied, 2755.97 s, 58.4 MB/s

So about 45 minutes to restore and Windows started flawlessly after that.

If you look for a similar utility for another OS then "Wipe Free Space" (http://wipefreespace.sourceforge.net/) is probably what you want (but I have not tried it).




Views: 606 | Added by: Charley_Dixon | Date: 11-07-23
Total comments: 0



 
Only registered users can add comments.
[ Registration | Login]


SEARCH

LAYOUT
Bright theme
Dark theme
Mobile theme
PAGES MENU

Open folder Summer Glau Open folder Career Open folder Fanfiction
Upcoming TV/Movies

Inside the Box
film festivals, VOD and DVD

Peter Panzerfaust Motion Comic
Upcoming Events

Ottawa Comiccon:
May 09-11, 2014

Dallas Comic Con 2014 :
May 16-18, 2014

London Film & Comic Con:
July 11-13, 2014
LOGIN

Old login form

ARCHIVE

«  July 2011  »
SuMoTuWeThFrSa
     12
3456789
10111213141516
17181920212223
24252627282930
31

APPS

Google play

OUR POLL

If Summer is casted in an upcoming Avengers movie which character should she play?

Total of answers: 582

STATISTICS


Total online: 13
Guests: 13
Users: 0


NEW FORUM POSTS

A gift for Summer?
MattM

The OFFICIAL Summer Glau Appreciation Page!
MattM

Avengers/Marvel’s Agents of S.H.I.E.L.D. thread
chrisdvanne

Submit a News or Article
robbo

Terminator 5 and 6
robbo

The official funny thread
chrisdvanne

Summer Glau's true identity on Arrow [Spoilers]
Fox012

Summer Glau at Ottawa Comiccon 2014
chrisdvanne

Actors and their Stunt/Body/Dance Double
MattM

Poll: What did you think of Arrow 2x19 "Man Under The Hood"
chrisdvanne


RECENT NEWS

Isabel Rochev and Slade Wilson Ready To Fight in Arrow 2.19 Promo Images
by chrisdvanne


Arrow 2.19 The Man Under The Hood - Screencaps & Clips
by chrisdvanne


Arrow Spoilers: Summer Plays a Mirakuru-ed DC Comics Character
by chrisdvanne


Summer Happy To Be On Team Deathstroke & More Arrow Spoilers
by chrisdvanne


Arrow Spoiler: Summer Is Not Deathstroke's Daughter Rose Wilson
by chrisdvanne


Summer Signing Autographs in St. Louis
by chrisdvanne


Impressions from Summer and the Firefly cast at St.Louis Comic Con
by chrisdvanne


Pictures of Summer and Impressions from the St. Louis Comic Con - First Day
by Fermi


Summer joins Dallas Comic Con 2014
by chrisdvanne


Summer, Celina Jade and Team Deathstroke on set of Arrow
by chrisdvanne


NEW BLOG ENTRIES

Arrow 2.19 The Man Under The Hood - HQ Stills
by chrisdvanne


Meet the Full Cast of Firefly at Dallas Comic Con
by chrisdvanne


Best of St Louis 2014 Celebrity Photo Ops
by chrisdvanne


Summer in Truckers Excuse Shirt for Esquire
by chrisdvanne


James Cameron talks Battle Angel Alita/Gunnm and announces Neill Blomkamp and Summer Glau
by chrisdvanne


On-screen Style: Red Cap Sleeve Dress by Judith & Charles
by chrisdvanne


Meet Summer's Stunt Double on Arrow
by chrisdvanne


On-Screen Items: Juliana Dress by Judith & Charles
by chrisdvanne


Serenity Props - Project Oracle Items
by chrisdvanne


Screen-Worn Burberry Dress from Dollhouse
by chrisdvanne


NEW COMMENTS

MattM made a comment on: Arrow 2.19 The Man Under The Hood - Screencaps & Clips


chrisdvanne made a comment on: Arrow Spoilers: Summer Plays a Mirakuru-ed DC Comics Character


Metal made a comment on: Arrow Spoilers: Summer Plays a Mirakuru-ed DC Comics Character


Metal made a comment on: Arrow Spoiler: Summer Is Not Deathstroke's Daughter Rose Wilson


Metal made a comment on: Summer Happy To Be On Team Deathstroke & More Arrow Spoilers


Fox012 made a comment on: Isabel Rochev and Slade Wilson Ready To Fight in Arrow 2.19 Promo Images


chrisdvanne made a comment on: Isabel Rochev and Slade Wilson Ready To Fight in Arrow 2.19 Promo Images


Fox012 made a comment on: Isabel Rochev and Slade Wilson Ready To Fight in Arrow 2.19 Promo Images


chrisdvanne made a comment on: Meet the Full Cast of Firefly at Dallas Comic Con


Frank made a comment on: Isabel Rochev and Slade Wilson Ready To Fight in Arrow 2.19 Promo Images


NEW VIDEOS




00:00:27

00:00:23

Sign up
Go to top