How do I clone a drive and resize (downsize) a partition ? fdisk verify warning.

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

 



I'm moving /, /boot and swap from a conventional hard drive to an SSD.

Both drives are 160 GB in size.

I want to resize the /boot and swap partitions from 200 MB and 2 GB to
500 MB and 8 GB respectively.   The first resize is because preupgrade
now fails to run unless /boot is 500 MB or larger and the second because
the swap file is supposed to be as big as the RAM in the computer and my
laptop currently has 4GB and I want to upgrade to 8 GB in the future.

So... I partitioned the SSD to the appropriate sizes.   I then ran
Clonezilla and installed the /boot data seemingly without any problem.
I used the expert mode and told it to resize things to fit the new /boot
partition size. 

Unfortunately, Clonezilla won't let me do the same for / because / on
the SSD is 6 GB or so smaller than it was on the hard drive
because /boot and swap are larger.

So how do I move ALL the data from / on the hard drive to / on the sdd ?

dd won't work because its for device files, not for partitions.  If I
use dd between the devices, it won't resize anything.

Or should I do an outright dd and then use gparted to resize everything
afterward ? 

Can one make cp copy EVERYTHING on one drive to another and keep the
timestamps, etc, all correct ?

I think I did this once a few years ago using tar, but I can't remember
how and I think it took up a lot of disk space and took forever to run.

BTW: if I verify the partition table for the SSD, it tells me
Remaining 5165 unallocated 512-byte sectors

Yet:
Disk /dev/sdb: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 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: 0x0001ab7d

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1          66      530113+  83  Linux
/dev/sdb2              67        1111     8393962+  82  Linux swap /
Solaris
/dev/sdb3            1112       19457   147364245   83  Linux


Am I missing something ?

Thanks !

-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines

[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