Gentoo Archives: gentoo-user

From: Adam Carter <adamcarter3@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] dd says no space left on device
Date: Mon, 16 May 2011 06:32:29
Message-Id: BANLkTi=PjdeJd=rKW4wTeUq4O0jGecf0tw@mail.gmail.com
In Reply to: Re: [gentoo-user] dd says no space left on device by Mick
1 > > To check my understanding - would it be correct to say that;
2 > > 1. Using dd to copy the first 512 bytes (MBR) is ALL that is needed to
3 > > setup the partitions - that is i wont need to run fdisk etc afterward.
4 >
5 > This is correct if you only have primary partitions. It will not copy the
6 > extended partition and any logical partitions in it. They reside in the
7 > first
8 > sector of the extended partition, which is not a boot sector, but contains
9 > the
10 > logical partition table. (I found this out the hard way!)
11 >
12 > Have a look at this to see how you can back up the extended partition
13 > tables
14 > with sfdisk (there's more than one of these, if you have more than one
15 > logical
16 > partition) :
17 >
18 > http://www.partimage.org/Partimage-manual_Backup-partition-table
19 >
20 >
21 > > 2. Using dd in this way of course will not update the kernel's knowledge
22 > of
23 > > the partition table so a partprobe is necessary
24 >
25 > Yes, or a reboot.
26 >
27 >
28 > > 3. When using fdisk to write a partition table and exit, it calls a
29 > re-read
30 > > of the partition table by the kernel so any changes should be ready
31 > > straight away. (there's a message about calling ioctl when it exits - so
32 > i
33 > > guess that is the update)
34 >
35 > They are ready (i.e. written) but not yet read by the OS. Tools like
36 > gparted
37 > (part)probe the device to re-read the partition table after saving changes
38 > to
39 > disk.
40 >
41
42 Thanks Mick. Great info, esp about the extended partitions. Fortunately, I
43 dont have any on this disk but good to know.

Replies

Subject Author
Re: [gentoo-user] dd says no space left on device Mick <michaelkintzios@×××××.com>