Score:0

How to Install Ubuntu-Based OS on Internal Hard Drive Without a Flash Drive Using Another Drive

cn flag

I have a pc with two 250 gb ssd's. I have ubuntu 21.10 on working well on one, and I want to install another linux-based os on the other so as to have a dual-boot. I have tried mounting the second ssd (with the first ssd) and installing the other os on it with Balena etcher as if it were a flash drive. When I boot to it, it thinks it is a flash drive, and treats the installation like it, asking me to remove the installation medium at shutdown, which is, of course, impossible, as the "installation medium" is the internal drive. It also will not save any settings changes I make. How can I install a working os on the second drive using the first one and without using a flash drive?

guiverc avatar
cn flag
You can add other ISOs (installed on a partition, drive on the system) to the `grub` options and have the box offer them as alternatives. I've done that so I could use boxes without working USB ports for QA-testing (meaning I just had to boot an installed OS on a partition of the machine, copy/update the ISOs there I wanted to QA-test; run a script so they changed ISOs were recognized; then `update-grub` so next boot would offer them for boot. You're asking about an off-topic OS though (mint & drauger are not Ubuntu or *flavors*)
oldfred avatar
cn flag
While I still use boot stanza like those in the link in guiverc comment, just used this for jammy.
Random-Ubuntu-User avatar
cn flag
I am aware they are off-topic. I just said that so it would be easier to understand the question, otherwise, I would have just called it "the os" and it would have been frustrating to try to understand. The question was about the ubuntu I was using to install. I don't know what jammy is.
guiverc avatar
cn flag
Ubuntu releases are known by the *codename* until they are released, the current *development* cycle is *jammy* which will change name to Ubuntu 22.04 LTS in the hours (RC or *release candidate* stage of cycle) before it's released; Ubuntu 22.04 LTS being the released name (it's still in *development* and hasn't been released yet). eg. my system reports itself as *Lubuntu Jammy Jellyfish (development branch) x86_64* (no mention of 22.04 is seen in `neofetch` yet - it's currently *jammy*)
guiverc avatar
cn flag
Also FYI I don't believe anyone voted it off-topic; as your changes were on Ubuntu as I (& others likely) understood it
Random-Ubuntu-User avatar
cn flag
Well, I just wanted to be sure. Thanks.
guiverc avatar
cn flag
FYI: You see the *codename* in your sources; ie. you won't see 21.10 is `/etc/apt/sources.list` (*unless it was on your installation media so will be in a comment*) with the file referring to 21.10 by codename, ie. *impish*; this being a Debian convention Ubuntu keeps. The first letter increments (ie. 21.04 was h, 21.10 was i, 22.04 is j etc for Ubuntu which can be a help in working out release even if you don't remember codenames)
Random-Ubuntu-User avatar
cn flag
mine is impish.
Score:2
cn flag

While I still use boot stanza like those in the link in guiverc comment, just used this for jammy.

I never would remember to run sudo update-grub after changing an ISO or adding one. So I use a configfile entry to load a text file with boot stanzas that is in my ISO folder.

Entry in grub that I never change:

menuentry 'Live ISOs in data drive' {
search --set=root --label data --hint hd1,gpt4
configfile /ISO/livecdimage.cfg
} 

I also found using label works better as my hd1 was changing to hd2 when rebooting with a flash drive or my external SSD connected. Used to have to edit stanza as I booted. But forget to edit stanza and found using label it still found it correctly.

Also found that newer versions of ISO have both grub & a loopback entry. So tried booting with the loopback entry. It worked.

This is one of many boot stanzas in my livecdimage.cfg which is just a text file, that is in my /mnt/data/ISO folder with all my ISO. The /mnt/data is only seen once booted in my system. When not booted or not mounted it is just /ISO.

menuentry "Kubuntu 22.04 Jammy amd64 loopback.cfg" {
      iso_path=/ISO/jammy-desktop-amd64.iso
      export iso_path
      loopback loop $iso_path
      set root=(loop)
      configfile /boot/grub/loopback.cfg
    }
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.