[SOLVED]Accidentally created USB boot onto HDD

Questions about Grub, UEFI,the liveCD and the installer
Forum rules
Before you post please read how to get help
Post Reply
User avatar
moze229
Level 2
Level 2
Posts: 98
Joined: Fri Jul 17, 2015 3:53 pm

[SOLVED]Accidentally created USB boot onto HDD

Post by moze229 »

Hello all.

I thought I would be a rebel the other day. I was making a USB bootable of Mint 19. Instead of using the "Make bootable USB drive" option, I decided I'd try it this way because it was a new adventure. lol

Code: Select all

sudo dd if=~/Desktop/linuxmint-19-cinnamon-64bit-v2.iso of=/dev/sdc bs=1M
At any rate, I ended up with the wrong device in the command line. I used /dev/sdb instead of /dev/sdc. This in itself isn't a problem in my case, because that particular drive is empty and not being used. The problem is now though, by USB boot Mint 19 will not load with the /dev/sdb plugged in. (640 meg HHD). If I unplug the drive, the USB boots flawlessly. I did a compatibility boot of 19, and saw kernel panic errors.

Figuring there was a conflict, I repartitioned and formatted the drive. A couple of things I find interesting after this.

1.) Even after repartitioning and formatting, the drive is still labeled "Linux Mint 19 Cinnamon 64-bit", just like the bootable USB drive.
2.) I can't change this label. I can rename and label individual partitions on the drive, but not the entire volume. There's nowhere in GParted that I can find how to do that.

Conclusion - I used a "make a bootable USB drive" command on a regular HDD. Now my HDD thinks it's a bootable USB, and when I boot from the actual USB bootable drive, they seem to conflict with one another. If I unplug the HDD, I'm back in business.

I want to use this 640 HDD to install Mint 19 on. How can I change the label of the ENTIRE drive - not partitions? How can I fix this conflict? There's likely something else going on in the background that I don't understand. Thanks in advance for your suggestions.

And by the way - yes. It was not smart for me to do things this way. I get it. I take full responsibility, and now I'm trying to fix it.
Last edited by moze229 on Tue Nov 27, 2018 1:06 pm, edited 1 time in total.

User avatar
moze229
Level 2
Level 2
Posts: 98
Joined: Fri Jul 17, 2015 3:53 pm

Re: Accidentally created USB boot onto HDD

Post by moze229 »

I was able to write zeros to the drive and correct the problem. A little crude, but it solved the issue. Just zeroed enough to wipe any info at the beginning of the drive. Solved the problem. It seems that there should be a way to correct this issue without having to do that but, whatever works.

My system now consists of Windows 10/Mint 17.2 dual boot on a 1TB drive. I've been using this setup for about 3 years now with little issue. I have an additional 640GB drive installed now and would like to use it to install Mint 19. My goal is to integrate 19 into my daily use, and then eliminate 17.2 from the main drive, allowing Windows to consume the entirety of the drive. This is what I want to do.

1.) Install Mint 19 on the secondary drive.
2.) Have Grub give me the option to boot to Mint 19 or Windows 10, both located on separate drives.

Is this possible? When I install 19, what options should I choose? Where should the bootloader go? /dev/sda or /dev/sdb? Ideally, my boot process would pull Grub and ask which OS I'd like to boot (which it does now) but on separate drives. Thanks for any insight on this.

Scythe
Level 1
Level 1
Posts: 23
Joined: Sun Jul 07, 2013 9:29 am

Re: Accidentally created USB boot onto HDD

Post by Scythe »

This is what I want to do.

1.) Install Mint 19 on the secondary drive.
2.) Have Grub give me the option to boot to Mint 19 or Windows 10, both located on separate drives.

Is this possible? When I install 19, what options should I choose? Where should the bootloader go? /dev/sda or /dev/sdb? Ideally, my boot process would pull Grub and ask which OS I'd like to boot (which it does now) but on separate drives. Thanks for any insight on this.
You can certainly install Linux Mint on a separate drive. That's how my system is installed. Windows on one SSD, LM on another.

Are you using UEFI? Not sure how it works with legacy, but my drives are all GPT and there is an EFI partition. That's where you want to install the bootloader. Otherwise, install the rest of your linux on the seperate drive (/home, swap, etc.)

rbmorse
Level 3
Level 3
Posts: 186
Joined: Mon Mar 07, 2011 11:56 pm
Location: Albuquerque, New Mexico USA

Re: Accidentally created USB boot onto HDD

Post by rbmorse »

moze229 wrote:
Sat Nov 24, 2018 11:52 pm
1.) Even after repartitioning and formatting, the drive is still labeled "Linux Mint 19 Cinnamon 64-bit", just like the bootable USB drive.
2.) I can't change this label. I can rename and label individual partitions on the drive, but not the entire volume. There's nowhere in GParted that I can find how to do that.
From the Gparted, first select the device from which you want to clear the volume name then from the Gparted menu select "device" then select "create partition table". This will clear all existing partitions and data from the drive, just like using the dd command to zero out the first tracks on the device as you did.
Hope is not a plan

User avatar
moze229
Level 2
Level 2
Posts: 98
Joined: Fri Jul 17, 2015 3:53 pm

Re: Accidentally created USB boot onto HDD

Post by moze229 »

Scythe wrote:
Sun Nov 25, 2018 5:53 am

You can certainly install Linux Mint on a separate drive. That's how my system is installed. Windows on one SSD, LM on another.

Are you using UEFI? Not sure how it works with legacy, but my drives are all GPT and there is an EFI partition. That's where you want to install the bootloader. Otherwise, install the rest of your linux on the seperate drive (/home, swap, etc.)
I am using UEFI. There is already GRUB installed on /dev/sda, to handle the Windows/Mint 17.2. Do I want to overwrite that one, or should I create a new one on the new drive? (/dev/sdb) It seems as if I should put in on sda, since that's the first drive the system looks at. It's a little scary messing around with the original boot loader. I just want to do this without messing something up. I have the drive cloned in case something bad happens, but I'd rather just do it right to begin with. lol

User avatar
moze229
Level 2
Level 2
Posts: 98
Joined: Fri Jul 17, 2015 3:53 pm

Re: Accidentally created USB boot onto HDD

Post by moze229 »

rbmorse wrote:
Sun Nov 25, 2018 10:09 pm

From the Gparted, first select the device from which you want to clear the volume name then from the Gparted menu select "device" then select "create partition table". This will clear all existing partitions and data from the drive, just like using the dd command to zero out the first tracks on the device as you did.
I did exactly that. Several times. It didn't work. That's why I was confused. I don't have a lot of experience with Linux, but I have a LOT of experience with Windows, and I'm somewhat familiar with how partitioning works. Usually when you change any partition information it means that everything on that partition goes bye bye. That didn't happen in this case. I'm not sure why.

User avatar
moze229
Level 2
Level 2
Posts: 98
Joined: Fri Jul 17, 2015 3:53 pm

Re: Accidentally created USB boot onto HDD

Post by moze229 »

I’m going to install without installing a boot loader and hope that grub will find the new install when I update it.

User avatar
JerryF
Level 12
Level 12
Posts: 4384
Joined: Mon Jun 08, 2015 1:23 pm
Location: Rhode Island, USA

Re: Accidentally created USB boot onto HDD

Post by JerryF »

moze229 wrote:
Sun Nov 25, 2018 11:27 pm
rbmorse wrote:
Sun Nov 25, 2018 10:09 pm

From the Gparted, first select the device from which you want to clear the volume name then from the Gparted menu select "device" then select "create partition table". This will clear all existing partitions and data from the drive, just like using the dd command to zero out the first tracks on the device as you did.
I did exactly that. Several times. It didn't work. That's why I was confused. I don't have a lot of experience with Linux, but I have a LOT of experience with Windows, and I'm somewhat familiar with how partitioning works. Usually when you change any partition information it means that everything on that partition goes bye bye. That didn't happen in this case. I'm not sure why.
After creating a partition table, you need to create a partition(s) for the disk to be used.

When working on the hard drive that has Mint running, remember to use Gparted from a live USB/DVD when working on it. Gparted can't do certain things if the disk is mounted.
*** IF your problem has been solved, please edit your ORIGINAL post and add [SOLVED] to the beginning of the Subject Line. It helps other members when browsing posts. ***

jglen490
Level 5
Level 5
Posts: 999
Joined: Sat Jul 15, 2017 9:57 pm

Re: Accidentally created USB boot onto HDD

Post by jglen490 »

moze229 wrote:
Sun Nov 25, 2018 11:27 pm
rbmorse wrote:
Sun Nov 25, 2018 10:09 pm

From the Gparted, first select the device from which you want to clear the volume name then from the Gparted menu select "device" then select "create partition table". This will clear all existing partitions and data from the drive, just like using the dd command to zero out the first tracks on the device as you did.
I did exactly that. Several times. It didn't work. That's why I was confused. I don't have a lot of experience with Linux, but I have a LOT of experience with Windows, and I'm somewhat familiar with how partitioning works. Usually when you change any partition information it means that everything on that partition goes bye bye. That didn't happen in this case. I'm not sure why.
Apparently, there are filesystem-specific label renaming tools available. Looks like it is necessary to unmount the drive before applying the lable renaming function. https://help.ubuntu.com/community/RenameUSBDrive
I feel more like I do than I did when I got here.
Toshiba A135-S2386, Intel T2080, ATI Radeon® Xpress 200M Chipset, 2GB RAM, 500GB

User avatar
moze229
Level 2
Level 2
Posts: 98
Joined: Fri Jul 17, 2015 3:53 pm

Re: Accidentally created USB boot onto HDD

Post by moze229 »

JerryF wrote:
Mon Nov 26, 2018 6:15 pm

After creating a partition table, you need to create a partition(s) for the disk to be used.

When working on the hard drive that has Mint running, remember to use Gparted from a live USB/DVD when working on it. Gparted can't do certain things if the disk is mounted.
Thanks for the pointers. I was on a live USB and I had created partitions and 2 partition tables 2-3 times. Each time I was looking for different ways to label the volume, and each time it retained the previous information. The partitions were labelled correctly, but the VOLUME was still labelled as the boot USB. I'm not sure if the label itself was the conflict - likely not. But once I wrote some zeros and cleared the beginning of the drive, all was good and I was able to boot with USB again and carry on with the install.

I was reading about many different methods of installs, such as creating separate /home, /root, etc. I tried making the main an EFI partition, but that just crapped grub. As far as the install, what I had to end up doing was creating an ext4 "/" and a swap on the second drive, just like I had done with 17.2. I put the bootloader on sdb, not sda - there was no option to not install a boot loader. At the end of the install, grub updated and when I rebooted my Mint 19 was in the menu with the other OS's.

Years ago, I used to do this type of thing with Windows all of the time. It was my job. I suppose if I did this regularly with Linux it would be the same. Thanks everyone for guidance on what likely seems a super no-brainer operation.

Post Reply

Return to “Installation & Boot”