<div dir="ltr"><br><br><div class="gmail_quote">On Thu, Oct 16, 2008 at 10:00 AM, Dan Rue <span dir="ltr"><<a href="mailto:drue@therub.org">drue@therub.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="Ih2E3d">On Thu, Oct 16, 2008 at 09:35:54AM -0500, Adam Monsen wrote:<br>
> * use dd to clone the whole disk onto a larger disk<br>
> * use parted to grow the partition<br>
> * use resize2fs to grow the filesystem<br>
<br>
</div>dd is a good tool, but it's best to understand what it does. dd copies<br>
data at the block level - it cares not about the data, or the<br>
partitioning, or anything like that. Chunk in, chunk out. It's great<br>
for doing things like:<br>
<br>
"Oh, I need a 100MB test file"<br>
dd if=/dev/random of=100MB_test_file bs=1M count=1024<br>
<br>
I think dd is bad, however, for moving disks.<br>
<br>
First, unless your disks are exactly the same size, you might/will run<br>
into problems (perhaps with some filesystems you can adjust them after<br>
the fact). Second, it's inefficient. Say you're moving from a 200GB<br>
hard drive to a 400GB hard drive, and you're using about 40GB of your<br>
200GB hard drive. DD will copy 200GB, even though you're only using<br>
40GB. That's right, it'll copy 160GB of empty space, because it doesn't<br>
know better. Also, you'll end up with 200GB partitions on the 400GB<br>
drive.<br>
<br>
I've always preferred to setup the partitions on a new device and then<br>
use a higher level tool to move the data over to the new locations.</blockquote><div><br>This is good advice too. I would use "rsync -av /source /destination" to copy your files from a high level, then reinstall grub to the MBR of your new drive. See the rsync man for more options. <br>
This method also gives you the opportunity to switch up file systems if you want (though, I would recommend ext3 for your system partitions). <br><br>Andy<br></div></div><br></div>