2

I have installed Cubian on Cubieboard using SD. After that I moved it to NAND. NAND have 4 Gb memory and I want to leave there only boot, another partitions move to the SD. Maybe leave on NAND something else? But I fear overflow memory when will install more programs.

Can I moved partitions and if true how can I do that?

McBodik
  • 177

1 Answers1

2

When dealing with partitions there are 2 ways to move their content. You can either make an exact copy of the partition(s) using a tool such as dd or copy the contents of the partition(s).

exact copies

This approach will not only copy the content but also the filesystem's metadata too. Depending on what you're trying to accomplish this may be a good or bad thing.

NOTE: You're literally making a byte for byte copy of the drive.

For example, say you have 2 harddrives, 1TB & 2TB. Let's imagine that all your data is currently on the 1TB and you'd like to move/migrate it to the 2TB drive. If you were to enlist the help of dd, you'd only be able to clone the drive as is onto the 2TB drive, there by wasting the balance of the larger space.

$ sudo dd if=/dev/sda of=/dev/sdb

copying data

The other approach is to createcompletely discrete drives/partitions from one another. Then copy the contents of the partition on the 1TB drive (/dev/sda1) to a partition on the 2TB drive (/dev/sdb1), using a tool such as rsync.

Once you have the partitions squared away you'll need ot mount them:

$ sudo mount /dev/sda1 /media/ssd
$ sudo mount /dev/sdb1 /media/backup-drive/ssd-backup

And then use rsync to copy:

$ sudo rsync -ax /media/ssd /media/backup-drive/ssd-backup
slm
  • 369,824