1

There was an SSD drive with Xubuntu distro installed. If booted, I can see it has one ext4 partition.

It worked fine but was planned to be moved to other HDD and to another machine.

I run live iso Ubuntu 18.10, started GParted and found out, that entire source drive is one partition of iso9660 type. I didn't know how to handle this, so I cloned all the source drive using dd, and saved it as a file.

Now, when I write image to HDD, it does boot, but there are some errors in FS and it finishes in initramfs. But that's not the point.

I still have the exact image of original drive and my question is how can I get the inner OS from iso9660 filesystem. After mounting this image I see and can browse only iso partition which is 2GB size. But where I can find target drive, ext4 partition, mentioned before, that would be visible if I had booted from original drive?

Update

I ran a few tests and the results are not consistent. When using fdisk with LiveISO, it show Linux partition, when doing the same using Gparted, it shows ISO9660. Another test, booting Ubuntu from the subject, fdisk shows the same as before, df -T show ext4, but Gparted again - iso9660.

LiveISO fdisk LiveISO fdisk

LiveISO GParted LiveISO GParted

Ubuntu fdisk and df -T enter image description here

Ubuntu GParted
enter image description here

qba-dev
  • 344
  • 1
    Would you please open a terminal windows, run sudo parted -l , copy the results, come back here, click [edit] and paste those results into your question? Please do not use Add Comment as that loses for formatting and makes it very difficult to read and understand. – K7AAY Mar 02 '20 at 17:44
  • 1
    Did you remember to update GRUB after moving your Xubuntu install to a different drive/partition? – user535733 Mar 02 '20 at 17:48
  • @K7AAY I can only run it in Live Ubuntu env as I don't have source drive and cloned HDD doesn't boot. – qba-dev Mar 02 '20 at 20:53
  • @user535733 no, I didn't update GRUB. I will do this from Live Ubuntu env – qba-dev Mar 02 '20 at 20:54
  • The ISO9660 partition is a clone of the ISO file, there is no new data on it. People generally want a full install of Ubuntu on the HDD as a Live install on the HDD is read only and will not save new programs or data. Better to use the 18.04 ISO file "Install Ubuntu" option to install to HDD. – C.S.Cameron Mar 03 '20 at 04:05
  • 1
    Comment on your updated question: I think that you can rely on the output from fdisk and df. I know that gparted can get confused by some data near the head end of the drive, and I think this is what happened in this case. Maybe the physical sectors of the SSD and the HDD did not match, maybe some hardware driver did not match the hardware in the second computer, maybe there was some other cause for the failure to boot from the cloned copy (in the HDD). – sudodus Mar 17 '20 at 08:29
  • 1
    @sudodus the same situation was on HDD before using SSD. Thanks, I will use CLI tools more often than before. – qba-dev Mar 17 '20 at 08:36
  • Also lsblk is reliable. It is easy to use lsblk -f and lsblk -m. See also this link. parted will often work, but suffers from the similar problems as gparted. – sudodus Mar 17 '20 at 09:57

1 Answers1

0

Installing ISO9660 File to HDD

The ISO9660 partition is a clone of the ISO file, Prior to 19.10 any space greater than the size of the ISO file is wasted. The Drive will fail if the ISO9660 partition is written to or modified.

A Live install on the HDD is read only and will not save new programs or data.

People generally want to put a full install of Ubuntu on the HDD, so that they can install programs and save data and settings. A full install also allows software updates and version upgrades, hibernation and proprietary drivers.

Use an app such as UNetbootin or Rufus to make an installer USB from your ISO file.

You can then use the Live USB "Install Ubuntu" option to install to HDD.

Another option is to dd your ext4 SSD install to another disk.

C.S.Cameron
  • 19,519
  • It was definitely a fully-operative OS, allowing to save data, files etc. Outside it looked like iso9660 when examining from Live Ubuntu, but after booting it was Xubuntu on ext4 partition. Drive's image is 180GB so I can't share it with You. – qba-dev Mar 03 '20 at 08:16
  • SSD is already in another aplication - can't use it. I did dd image to HDD and it does boot to initramfs - possibly only GRUB update needed. But after writing image to HDD, it still shows as ISO9660. – qba-dev Mar 03 '20 at 10:23
  • Can't install new OS, I need the one from my image. I can't afford loosing all the data and scripts. My situation does not fit to Your answer. – qba-dev Mar 03 '20 at 12:25
  • I did as You wrote: dd if=/source of=/image, but as I wrote before, writing this image to another drive (hdd) resulted in iso9660 fs, and not booting OS. – qba-dev Mar 03 '20 at 13:09
  • Some call dd disk destroyer, one small typo can make a lot of trouble. Is there any chance that you dd'd the ISO rather than the SSD? – C.S.Cameron Mar 03 '20 at 13:30
  • Image has 180GB so possibility is realy low :-) – qba-dev Mar 03 '20 at 15:12
  • @qba-dev : If you use SDC or balenaEtcher to install Live 18.04 to SSD the ISO9660 partition will span the entire drive, but only ~2GB will have data on it. I think this can also be true for some dd. – C.S.Cameron Mar 04 '20 at 03:06
  • I repaired FS and Grub, and it now runs fine, but still the mystery of iso9660 remains unraveled – qba-dev Mar 17 '20 at 08:35