0

I've been using Clonezilla (partimage) to image all of the drives on one of my networks. The drive in question is used as data drive for a Fedora host, and is formatted EXT2, however the filesystem encompasses the entire device, not a partition. I can mount the drive no problem with /dev/sda /media/sda (as opposed to /dev/sda1) and access all the data, and the drive automounts when in the Fedora host.

When partimage attempts to image the drive it gets to this point:

Activating the partition info in /proc...done!
No Input device!
Press enter to continue...

I checked in /proc/partitions and here's what populates for sda

major    minor    #blocks    name
  8        0    1953514584    sda
 11        0        578560    sr0
  8       16     976224256    sdb
  8       17        102400   sdb1
  8       18     976118784   sdb2

I think when partimage looks for the partition data and doesn't find anything labeled as sda1 it assumes the drive has no partitions and is empty.

Is there a way to trick partimage into seeing the entire drive as a partition so that it will image? I was thinking maybe there's a way I could create a symblink from sda1 to sda or something along those lines, but wasn't sure about the best way to go about it. Maybe someone has come across this before and I'm just over thinking the issue. Any advice will help. Thanks in advance.

  • Are you using a network image transfer or something else specific to Clonezilla? Would "dd" work in the short term to keep things moving? – John Dec 22 '17 at 16:04
  • I'm actually using Parted Magic, which includes a "local" version of Clonezilla, installed on a local hard drive on a dedicated image machine. As a last resort yes, I should be able to dd to at least transfer the data to a local drive, and format the data drive with an actual partition, dd the data back to that and then image, but I'd like to avoid all the extra transfers if possible. – Gansheim Dec 22 '17 at 16:13
  • When you directly call partimage save /dev/sda <target file>, does it work then? – ridgy Dec 22 '17 at 16:22
  • @ridgy that seems to have done the trick. Thank you. – Gansheim Dec 22 '17 at 19:02
0

I would use dd or rsync to copy the data from the drive.

However, it doesn't make sense that there are no partitions on the drive if it has a filesystem on it. Maybe someone can correct me, but unless you are using LVM, this doesn't even sound possible. If you can mount the drive, it has a filesystem. If it has an Ext2, Ext3, or Ext4 filesystem I think it has to have a partition that spans the entire drive that Partimage is not identifying.

  • 1
    It's unusual, but not impossible. 99.99999% of the time a partition table is created before formatting to a specific filesystem, in order to allow resizing/managing the disk in the future. However, it's possible in Linux to format the entire drive, with creating a partition table. It's just frowned upon ;) unix.stackexchange.com/questions/346826/… – Gansheim Dec 22 '17 at 19:05
  • @David: "However, it doesn't make sense that there are no partitions" - why not? Partitioning only means a) to have the possibility for more than one filesystem on a drive, and b) to have an MBR, whatever this may be good for. With e.g. external drives like (small) USB flash drives, filesystems without partitioning was usual in the past. And I don't agree on the 99.99999%; in production environments (not Windows!) data disks often hold no partitions, but only filesystems. – ridgy Dec 22 '17 at 21:17
  • @ridgy: Anything I ever read stated that you needed at least one partition on the drive to install a filesystem. tldp.org/HOWTO/Partition/requirements.html – David Watson Dec 22 '17 at 21:53
  • @David: To create a filesystem you need a device node and a program to create that filesystem. In Linux the program is mkfs (or one of the mk*fs or mkfs.* binaries). There is no problem to call mkfs -t <type> /dev/sda (don't do that, if /dev/sda holds any data!!). You can try with some USB flash disk that you don't have valuable data on. It is usual for USB flash (as I already stated), but also for loop devices (files), iSCSI devices, FC devices, LVM volumes and the like (which are probably the most devices in productiom environments). – ridgy Dec 23 '17 at 12:37
  • The link you provided is a bit outdated. And yes, especially for beginners it is better to have not too many different possibilities (to say "you need to partition" is sort of simple rule you won't forget). And yes, there are disk utilities that don't work on non-partitioned devices, even if there is a filesystem on them (that was the reason for OP...) – ridgy Dec 23 '17 at 12:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.