LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 03-12-2018, 08:24 PM   #1
pablo27
Member
 
Registered: Oct 2009
Posts: 55

Rep: Reputation: 0
dd command to make bootable USB


I am using Linux Mint 17.2, and 18.3(different Machine) and am trying to use the dd command to burn iso to USB. I have tried formatting the USB first, and not formatting the usb, I made a hybrid iso and tried that and when I look at the USB in Dolphin there is nothing there or it doesn't show up at all, or I get about 10 lines of errors about mounting the usb. Here are the things I have tried:

sudo fdisk -l
1038 cd Downloads
1039 sudo dd if=linux-lite-3.8-32bit.iso of=/dev/sdg bs=4M
1040 kdesudo dolphin
1041 history
1042 sudo fdisk -l
1043 kdesudo dolphin
1044 umount /dev/sdg
1045 sudo fdisk -l
1046 sudo dd if=linux-lite-3.8-32bit.iso of=/dev/sdg bs=4M


1081 sudo fdisk -l
1082 sudo dd if=/Downloads/linux-lite-3.8-32bit.iso of=/dev/sdg
1083 pwd
1084 sudo dd if=/home/pablo/Downloads/linux-lite-3.8-32bit.iso of=/dev/sdg
1085 sudo fdisk -l
1086 sudo dd if=/home/pablo/Downloads/linux-lite-3.8-32bit.iso of=/dev/sdg
1087 sudo apt-get install syslinux
1088 cd Downloads
1089 isohybrid linux-lite-3.8-32bit.iso
1090 cd
1091 pwd
1092 sudo fdisk -l
1093 sudo dd if=/home/pablo/Downloads/linux-lite-3.8-32bit.iso of=/dev/sdg
1094 kdesudo dolphin
1095 history
1096 pw
1097 history
1098 sudo fdisk -l
1099 sudo dd if=/home/pablo/Downloads/linux-lite-3.8-32bit-Hybrid.iso of=/dev/sdg


I realize there are other ways(?) to do this but I am working on learning Linux and I want to learn to do this this way.
Thank you in advance for any and all help and for your time.

Paul
 
Old 03-12-2018, 08:38 PM   #2
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
what is /dev/sdg, you got that many usb ports? if it is correct then go with it.

Code:
lsblk // to get your usb port with your usb stick plugged in.
//being inside of the same directory the iso is at.

sudo dd if=mint.iso of=/dev/sdx && sync
that's always worked for me, and the 'x' indicates the letter a,b,c etc.

make sure the usb stick is NOT mounted. Just plug it in and do not use a file manager or anything to read it first. get its address using lsblk and then issue the commands to dd to it. reboot and do your thing to select it on boot to boot into it to see if that worked. you do not have to go through the install process, ( said for that just in case )

Last edited by BW-userx; 03-12-2018 at 08:44 PM.
 
Old 03-13-2018, 08:08 AM   #3
rtmistler
Moderator
 
Registered: Mar 2011
Location: USA
Distribution: MINT Debian, Angstrom, SUSE, Ubuntu, Debian
Posts: 9,882
Blog Entries: 13

Rep: Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930
bw-userx is correct, but also to note that you were correct with the form of the command you entered a few times as shown in your history. Perhaps you did get the path to your USB stick incorrectly, perhaps the ISO file you have is not a boot capable one, or perhaps the ISO file you downloaded is flawed or has some other problem. Most Linux distributions provide an MD5 sum to check the ISO file and verify you have downloaded it all, and downloaded it correctly.

My only guess is that you did perform the sudo dd if=<filename>.iso /dev/sd<drive-letter> and it did not result in a bootable USB?

Last edited by rtmistler; 03-13-2018 at 08:09 AM.
 
Old 03-13-2018, 02:02 PM   #4
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
your commands used look ok.
and yes, the usb should NOT be mounted when you do that.

Quote:
Originally Posted by pablo27 View Post
when I look at the USB in Dolphin there is nothing there or it doesn't show up at all
this is correct; the usb does not contain a conventional filesystem, it is supposed to be booted.
 
Old 03-13-2018, 02:17 PM   #5
pablo27
Member
 
Registered: Oct 2009
Posts: 55

Original Poster
Rep: Reputation: 0
Thank you all so much for the rapid replies. I am not totally new to linux, I have been using it for a long time. I always check the midsum on my downloads. Don't know why it came up with /dev/sdg, since fdisk gave me that I just went with it. I think the problem was in formating it then checking it with dolphin or Kde partition manager, hence it was mounted. I tried unmounting before running dd and it worked. The other thing is it never showed up in dolphin even though it was a working USB??? Thank you all again, I wanted a bootable USB so I could copy some files off a windows laptop that wouldn't boot.

Paul

Last edited by pablo27; 03-13-2018 at 02:19 PM.
 
Old 03-13-2018, 04:55 PM   #6
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,980

Rep: Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624
"I made a hybrid iso " What exactly do you mean here?
 
Old 03-13-2018, 06:28 PM   #7
AwesomeMachine
LQ Guru
 
Registered: Jan 2005
Location: USA and Italy
Distribution: Debian testing/sid; OpenSuSE; Fedora; Mint
Posts: 5,524

Rep: Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015
I'm pretty sure most distro install isos are hybrid. That just means the iso will boot off an optical disk or a USB flash drive.
 
Old 03-13-2018, 07:28 PM   #8
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,980

Rep: Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624
To the OP.
Did you take some iso and modify it to make the statement "I made a hybrid iso "?
 
Old 03-14-2018, 12:25 AM   #9
pablo27
Member
 
Registered: Oct 2009
Posts: 55

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by jefro View Post
"I made a hybrid iso " What exactly do you mean here?
After looking at the iso in ARK I could only see where the iso was meant to be a CD. After some research I found out about Hybrid iso's that are able to be burned to CD or USB (see 1087-1089) of my terminal post. I am not sure if I had unmounted the USB first the original iso may have worked. I will try and post the results. If I just plug in the USB and use fdisk will it be mounted, even if I don't use dolphin or KDE partition manager?

Paul
 
Old 03-14-2018, 08:46 AM   #10
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
  1. get an iso
  2. open a terminal then change directories to where your iso is at
  3. plug in your usb stick
  4. lsblk to get which port it is in, or (sudo) blkid
  5. dd if=linux.iso of=/dev/sdXx && sync
  6. press Enter
when that is done reboot, then tell your BIOS/System to boot the USB Stick and cross your fingers and hope it worked.

Last edited by BW-userx; 03-14-2018 at 08:53 AM.
 
Old 03-14-2018, 10:37 AM   #11
rtmistler
Moderator
 
Registered: Mar 2011
Location: USA
Distribution: MINT Debian, Angstrom, SUSE, Ubuntu, Debian
Posts: 9,882
Blog Entries: 13

Rep: Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930
I believe this is solved and the problem appears to be that the USB was mounted when you first attempted it.

If so, please mark the thread as solved for future seekers of a similar problem.

Best Regards
 
Old 03-14-2018, 02:21 PM   #12
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,980

Rep: Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624
Many disto's used to proclaim they had hybrid iso images or usb/optical images available. They don't all seem to report it as such anymore.

From the lite page "If you are writing the ISO to a USB on Windows, Mac or Linux, please use Etcher - https://etcher.io/

Linux or Mac command line: sudo dd if=linux-lite-3.8-32bit.iso of=/dev/sdx bs=4M"

however they didn't mention the usb did need to be unmounted.
 
Old 03-15-2018, 01:48 AM   #13
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
everyone please go back and read post #1.
the commands look ok to me.

i'll say it again, it is totally normal that the resulting usb medium won't show up in the filemanager or can't be browsed with it.
if you need to get some data off it, you can mount it first.
i just tried with any old iso, the command:
Code:
mkdir mnt; sudo mount Anyold.iso mnt
should be sufficient.

Last edited by ondoho; 03-15-2018 at 01:49 AM.
 
Old 03-15-2018, 08:50 AM   #14
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
yes, the other line of thought,
Quote:
Originally Posted by pablo27
made a hybrid iso and tried that and when I look at the USB in Dolphin
if he made it himself then it 'has' to be a bad build. But the ultimate test would be trying to boot it. if it fails then ask why.
 
Old 03-15-2018, 12:38 PM   #15
DavidMcCann
LQ Veteran
 
Registered: Jul 2006
Location: London
Distribution: PCLinuxOS, Debian
Posts: 6,140

Rep: Reputation: 2314Reputation: 2314Reputation: 2314Reputation: 2314Reputation: 2314Reputation: 2314Reputation: 2314Reputation: 2314Reputation: 2314Reputation: 2314Reputation: 2314
Just to clarify a bit, if you use dd to put an iso image on to usb, then the usb now has the filing system appropriate to an optical disk. As far as Linux is concerned, it looks like an optical drive run off a usb port. Naturally, it won't be treated as a random-access memory device any more.

Incidentally, if ever you need to turn it back into a conventional memory device, a partition editor probably won't do it. It will see the device has the iso9660 filing system and assume you're trying to partition a DVD! The secret is to destroy the filing system ID before using the partition editor, with
dd if=/dev/zero bs=1M count=10 of=/dev/sdx
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
make bootable usb Raied_F1 Linux - Newbie 4 10-16-2016 07:19 AM
how to make bootable usb malli Linux - Software 2 11-27-2011 04:30 PM
Cant make a bootable Ubuntu USB Latios Ubuntu 2 06-10-2011 02:19 PM
[SOLVED] How to make XP bootable from usb, linuxishard Linux - Newbie 30 08-22-2010 01:36 PM
How do you make a usb drive bootable? comcastuser Linux - General 4 06-25-2007 02:19 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 11:46 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration