From mboxrd@z Thu Jan  1 00:00:00 1970
Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org)
	by finch.gentoo.org with esmtp (Exim 4.60)
	(envelope-from <gentoo-user+bounces-122829-garchives=archives.gentoo.org@lists.gentoo.org>)
	id 1QLzqS-0005LR-KA
	for garchives@archives.gentoo.org; Mon, 16 May 2011 15:36:32 +0000
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 18DA61C01B;
	Mon, 16 May 2011 15:35:09 +0000 (UTC)
Received: from mail-fx0-f53.google.com (mail-fx0-f53.google.com [209.85.161.53])
	by pigeon.gentoo.org (Postfix) with ESMTP id BE6AA1C01B
	for <gentoo-user@lists.gentoo.org>; Mon, 16 May 2011 15:35:08 +0000 (UTC)
Received: by fxm8 with SMTP id 8so4106093fxm.40
        for <gentoo-user@lists.gentoo.org>; Mon, 16 May 2011 08:35:07 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=gamma;
        h=domainkey-signature:mime-version:in-reply-to:references:date
         :message-id:subject:from:to:content-type:content-transfer-encoding;
        bh=O3eOrEGwMWrl731RpGtm0hLaS9OGZeyBkSNK6Ebc5Xw=;
        b=YqoxBNQ3UzbZUmNdGhDRm2dKSpsD6DswMJKtT6JkRFGG06gFI8L/rsArNPw2bfxy7z
         zOkVJeNU1+u6VQVOL5AgaPPHLvnJP2rRxx0VOkj8VMxfMSwmYCgzuUhrXb3kYsnEwAno
         Q2b7fsNdMjERGgCDRATUk0wlITlNgSJQTsWdk=
DomainKey-Signature: a=rsa-sha1; c=nofws;
        d=gmail.com; s=gamma;
        h=mime-version:in-reply-to:references:date:message-id:subject:from:to
         :content-type:content-transfer-encoding;
        b=GvNb9TSUzjF7YTowMrAHGW0du3VezVyE7QK6sl8cwIDL52uooayoMQkC2Sgt+wkuTP
         JMQy8nNcj/ruMhq+6W0eg9hQDOgRV/YCbT2lbwJDkTLpnTJkYKkvN4N9PTZ9RHyboLdY
         X5W539f/99eB+qTPW85SQBeazay1D7UarCyhA=
Precedence: bulk
List-Post: <mailto:gentoo-user@lists.gentoo.org>
List-Help: <mailto:gentoo-user+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-user+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-user+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-user.gentoo.org>
X-BeenThere: gentoo-user@lists.gentoo.org
Reply-to: gentoo-user@lists.gentoo.org
MIME-Version: 1.0
Received: by 10.223.27.18 with SMTP id g18mr3599164fac.52.1305560107763; Mon,
 16 May 2011 08:35:07 -0700 (PDT)
Received: by 10.223.151.3 with HTTP; Mon, 16 May 2011 08:35:07 -0700 (PDT)
In-Reply-To: <10DA6B9E-10FF-4D03-80CC-8701313F338F@stellar.eclipse.co.uk>
References: <BANLkTi=GVd9Gj_XZr7p+UkyPaqGmnu4KRw@mail.gmail.com>
	<3457739.e4pPBF490q@localhost>
	<BANLkTikzV7=Lr38HWrYF5GnaSw2puLLcBw@mail.gmail.com>
	<201105160700.42795.michaelkintzios@gmail.com>
	<BANLkTi=PjdeJd=rKW4wTeUq4O0jGecf0tw@mail.gmail.com>
	<BANLkTi=5etsv7A-KjyYenRRFg8vid85T3g@mail.gmail.com>
	<20110516114545.4d90dfac@digimed.co.uk>
	<BANLkTi=L30LZU1vOE0yLnVfPx9disN=B6w@mail.gmail.com>
	<20110516123701.32f9b515@digimed.co.uk>
	<BANLkTinkfUxdDfvf9=n2k_uWdjOaOhJWBw@mail.gmail.com>
	<10DA6B9E-10FF-4D03-80CC-8701313F338F@stellar.eclipse.co.uk>
Date: Mon, 16 May 2011 16:35:07 +0100
Message-ID: <BANLkTikkNd0_rercEZB5Nb0MTzRu_fv0HQ@mail.gmail.com>
Subject: Re: [gentoo-user] dd says no space left on device
From: Mick <michaelkintzios@gmail.com>
To: gentoo-user@lists.gentoo.org
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
X-Archives-Salt: 
X-Archives-Hash: 48ef80ec8fef26d845afcffe32262975

On 16 May 2011 15:21, Stroller <stroller@stellar.eclipse.co.uk> wrote:
>
> On 16/5/2011, at 12:56pm, Adam Carter wrote:
>> ...
>> Yes the new drive is bigger, going from 66G to 500G. Single partition on=
ly, ...
>>
>> So how do i proceed? Is it;
>> 1. dd the mbr without partition table, to get the boot code (so bs=3D446=
 count=3D1)
>> 2. use fdisk to set one big primary partition, mark it bootable and NTFS=
 (type 7)
>> 3. dd into what will be /dev/sdb1
>
> Just `dd if=3D/dev/sda of=3D/dev/sdb` if you can.
>
> As Neil posted: there is no need to copy MBR & partitions separately in s=
uch a simple situation. I don't know that I have ever needed to clone a har=
d-drive in the way that you're attempting - I have *always* cloned the whol=
e drive (and I've cloned quite a few Windows drives this way). `dd if=3D/de=
v/sda of=3D/dev/sdb` with no numbers on the end of sda or sdb.
>
>> but IIRC there is a 100MB unlabelled space (doesnt come up with fdisk -l=
). Is this is an OEM recovery hidden partition?
>
> Possibly. But this question should be preceded by: "do you have an OEM re=
covery hidden partition?"
>
> I mean, if the computer starts up and says "press R to boot into the Comp=
aq recovery partition" and there's no other place for it to be, then yes. B=
ut frequently OEM recovery hidden partitions are visible in Windows' disk m=
anagement console (Start > Run > "diskmgmt.msc") as partitions of DOS or un=
known type, or simply showing as "hidden" or with no drive letter assigned.=
 Therefore I'd expect them to be visible in fdisk as well.
>
> Whatever, if you clone the whole disk you will copy the recovery partitio=
n, if its present.
>
>> Will I be able to expand NTFS or it is better to make sure parition size=
 =3D NTFS filesystem size so it doesnt get confused, the boot into windows =
and expand it?
>
> It probably depends on the version of NTFS whether this can be done nativ=
ely or not. I believe that in XP you can expand D: and E: partitions from w=
ithin Windows, but not C:. So to expand an XP system drive you would use Pa=
rtition Magic or the GParted LiveCD [1]. I guess that Windows 7 allows you =
to expand C: from the management console, if not GParted claims to support =
it (and Vista).
>
> I would be trying to do this *after* you have cloned the whole drive and =
booted with the new copy. Don't try to be clever about whether the filesyst=
em should be the same size as the partition or not - just copy the whole lo=
t verbatim, so they'll remain the same sizes they are now. Then use the GUI=
 tools to expand the partition+filesystem afterwards and let those GUI tool=
s worry about it - preferably use Windows' own tools, otherwise use Partiti=
on Magic or GParted.
>
> Partition Magic is my resizing tool of choice for XP, but it's neither fr=
ee nor Free, nor is it supported on Vista or Windows 7. =A0GParted is the n=
ext choice, then - I understand it to be more than "just a graphical front-=
end", and I don't think you'll have such good results trying to use command=
-line tools to expand NTFS partitions.
>
> Stroller.
>
>
> [1] http://gparted.sourceforge.net/livecd.php

Only to add that the new larger drive will appear as small as the
original because the fs size is after all that of the smaller drive.
After your dd the data over to the new disk you will need to run
gparted as suggested by Stroller, or use ntfsresize which is what
gparted uses anyway.
--=20
Regards,
Mick