Re: https://forum.obarun.org/viewtopic.php?pid=4437# p4437
saleem wrote:
fungalnet wrote:

The quick and dirty installation for me is # cp -ax / /mnt then you go in and fix things, then reboot to a non-live clone of the live system. /etc/fstab ..gshadow group passwd sudoers ... then make a boot entry.
This part sounds intriguing to me , would you further elaborate it please? You do this to an ISO? ( I have always wondered how to copy contents of an ISO onto a spare partition and boot it from that partition rather than making a USB and doing hard disk installation ) ( I could use this method on a distro on which I want to make my hands dirty for a long time but since it`s locale is Cyrillic I can`t take a risk to do hard disk installation )
This doesn't work for all linux distributions, but it works on arch based ones.
Have a new partition ready made to build a new system, let's say it will be /dev/sdb3
You start the live image and mount the partition

# mount /dev/sdb3 /mnt
# cp -ax / /mnt
this copies all parts of the system that are static, none of the live created parts like /run or /proc etc.
After you do this you have to chroot and install a kernel as the image in the live system is not appropriate for booting from a hard installation. Edit your /etc/fstab to give it the correct root / uuid for /dev/sdb3, you can use the live user or delete and create a new one, change passwords, and depending on your bootloader create a new boot entry (bios/efi) grub/syslinux etc.
Then you can boot the system. You do not even need internet connection to do this, the system that will boot will be pretty much the same as it was on the live image.
This is not a proper installation but if something keeps failing from the normal installer this is a way out. Also any changes you make on the live image will be transferred to the cloned installation, like if you have removed packages and installed extra ones. In Obarun make sure you edit /etc/66/boot.conf
What if I do

# dd if=file.iso of=/dev/sdX
e.g

dd if=arch-example-experiment.iso of=/dev/sda23

Will it work similarly as your way of doing it ?
No, an iso file has to be copied to a whole disk not just a partition because it incorporates part of the whole disk formating, boot sector/mbr, and partitions. Hopefully if you try it will give you an error before it destroys your disk.
/dev/sdx --> /dev/sdb not /dev/sdb3
I followed these commands to copy ISO to a partition

# mount /dev/sda23 /mnt

# mkdir -p /mnt/disk

# mount -o loop pra6408-1904.iso /mnt/disk

# cp -av /mnt/disk/* /mnt

lets see how my experimentation goes

Powered by Obarun