Re: An Exercise: Manually creating a new boot disk from an existing one

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Philip Rhoades wrote:
>> I am interested to see if it is possible to boot on an existing disk -
>> say /dev/sda ("A") - and then manually create everything required on a
>> second disk - /dev/sdb ("B") eg:

Generally speaking, if you want to clone drives, you're much better off
booting from some third thing, and copying from source to destination
without any interference from an OS currently running from the drive
you're copying.

i.e. Boot from a live disc, probably a disk managing one, rather than a
full bloated live OS.

Theoretically, you can dd the whole partition, not have to do it in
stages (dd partition details, *then* copy files over).

> > - create the partition table and partitions on B
> > 
> > - dd the existing boot track(s) from A to a file and then dd that to B -
> > or create it from scratch somehow?
> > 
> > - rsync the the first level directories into the appropriate places on
> > the new drive and partitions (maybe by temporarily booting on a Live USB
> > so we are not copying from a running system?)
> > 
> > If this is possible, what else would need to be done on B so that when
> > drive A is removed, the remaining B (the new "A") drive will be able to
> > boot and run normally?

If new drive is identical to old drive, then simply swapping them ought
to be enough.  But if new drive is bigger than old drive, then your dd
of one to the other, will only occupy a portion of the new drive.  You'd
probably want to expand it to fit.  Unless you wanted to keep some
unused space.


Timothy Murphy:
> Presumably you would have to (at least)
> 1. Correct /etc/fstab

Depends on how it calls partitions.

> 2. Install grub on second disk

If he used "dd" to copy partitions, then it should copy the partitions
in their entirety (including all things stored in partition headers).
In essence, cloning them.  And that's where a problem will lay, he'll
now how have two (or more) identical partitions on the system, on
different drives.  You couldn't mount them without some headaches, and
if the current way of addressing them isn't unique (i.e.
uses /dev/sd..., which will be unique per drive, but names and IDs will
be duplicated), then you may be in for grief until you unplug one of the
drives.

-- 
[tim@localhost ~]$ uname -rsvp
Linux 3.9.10-100.fc17.x86_64 #1 SMP Sun Jul 14 01:31:27 UTC 2013 x86_64

All mail to my mailbox is automatically deleted, there is no point
trying to privately email me, I will only read messages posted to the
public lists.

If you don't understand how e-mail threading works, then follow the
instructions given by those who do, and don't argue with them.



-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Fedora Code of Conduct: http://fedoraproject.org/code-of-conduct
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
Have a question? Ask away: http://ask.fedoraproject.org



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux