Using terminal to convert iso file

Joined
Dec 16, 2018
Messages
20
Reaction score
0
Points
1
Hi
I am trying to create a bootable usb drive containing Linux Mint Mate. I would like to run it on my old MacBook Pro which is stuck with 10.6.8 and is not very useable now sadly. I thought a version of Linux might extend its life a little. Neither disc utility nor any other apps seem to be able to accomplish it. I can’t even burn a dvd because somehow all of my discs are reported as incompatible. I found some instructions on how to do it using terminal and thought I’d give it a go.
Using, hdiutil convert /path/file.iso -format UDRW -o /path/file.dmg
I get an error saying the file path is incorrect or the file/folder does not exist. I dragged the source file into the terminal window as per instructions. I am not sure whether the output file is simply the same destination but in the new format, so that is what I used but amended the ending to img. I also tried this line which claims to convert too, the image appeared on the usb but the Mac could not “see” it when I tried booting holding down the option key. sudo dd if=/path/image.iso of=/dev/r(identifier) bs=1m
Could someone point out what I might be doing wrong?
Thanks in advance for any help.
 

Raz0rEdge

Well-known member
Staff member
Moderator
Joined
Jul 17, 2009
Messages
16,033
Reaction score
2,438
Points
113
Location
MA
Your Mac's Specs
2022 Mac Studio M1 Max, 2023 M2 MBA
If Disk Utility isn't able to use your machine SuperDrive to burn a disk, the Terminal will likely have the same problem.

Either way, try the following command in Terminal
Code:
hdiutil burn <path/to/.iso>

You don't need to convert the ISO to DMG to burn. To get the full path, you can drag the file from Finder to Terminal.
 
OP
K
Joined
Dec 16, 2018
Messages
20
Reaction score
0
Points
1
I have tried again from scratch. I have erased the usb stick, created the partition etc. In terminal I typed in the command hopefully as you meant it to be
hdiutil burn /users/myname//linuxmint.iso of=/dev/disk2 bs=1m
It returns with the message: Only a single input file can be specified
What could be wrong?

If I use
sudo did if=/users/myname/linuxmint.iso of=/dev/disk2 bs=1m
It sends the file to the usb but it is still an iso file
Is there anything else I could try?
Thanks
 

Raz0rEdge

Well-known member
Staff member
Moderator
Joined
Jul 17, 2009
Messages
16,033
Reaction score
2,438
Points
113
Location
MA
Your Mac's Specs
2022 Mac Studio M1 Max, 2023 M2 MBA
Not sure why you are passing random arguments to hdiutil which is more meant for dd. What happens if you use JUST the command I suggested?

You should do a 'hdiutil burn -help' to read the help information.
 
OP
K
Joined
Dec 16, 2018
Messages
20
Reaction score
0
Points
1
Ah, sorry. Being unsure, I had thought I was meant to enter the rest of the command that I had been trying. Silly me.
The code was from an online guide I found.

Ok. So if I just input the code you gave it asks for a disc and then begins the burn. After a while it said, finishing burn, and ejected, the disc. Then another message said, Burn failed. The disc drive didn’t respond properly and can’t recover or retry.

Could it be an incompatible disc? That is what disc utility reported.
If it will not write to disc does that mean it won’t write to the usb stick either?
Thanks ever so much for your patience.
 

Raz0rEdge

Well-known member
Staff member
Moderator
Joined
Jul 17, 2009
Messages
16,033
Reaction score
2,438
Points
113
Location
MA
Your Mac's Specs
2022 Mac Studio M1 Max, 2023 M2 MBA
Let's hope it is certainly an incompatible disc, that is easier to fix than a failed optical drive. You should try another disc and see if that works. If that fails as well, then it might point to the optical drive going bad which was a verpossible thing on the old Macs.

If you want to use a USB stick (recommended in my opinion), the process would be a close to the dd command you were trying.

First you should do diskutil list to list all the available devices. One of them will be the USB stick. I'm going to assume it was disk2 for the rest of the command here, but you would change that to match what you actually see.

Unmount the USB stick with diskutil unmountDisk disk2 and then 'burn' the ISO image to it using sudo dd if=/path/to/Linux.iso of=/dev/disk2 bs=8m.

For your info, the arguments to DD are:
- if = input file
- of = output file (/dev/disk2 is a virtual file that points to the physical USB stick)
- bs = block size (8 megabytes in this case)

The command won't show any progress while it's doing its job, so wait until you are back at the shell prompt to proceed. This could take at least 5 or more minutes.

Finally, eject the stick with diskutil eject disk2 and now you should be able to use that USB stick as a bootable device to install Linux.

If any of this gives you grief, you can try Etcher to burn the ISO image using an application.
 
OP
K
Joined
Dec 16, 2018
Messages
20
Reaction score
0
Points
1
Thank you. I have a feeling it might be incompatible discs at fault. I have tried the same operation on my iMac, also 10.6.8, and it spits the discs out too.
Is this line from my earlier post the same as the one you have suggested? The only difference appears to be bs=1m as opposed to bs=8m. It does go to the usb but is still an iso file and does not appear when trying to boot.
Etcher will not work on either my iMac or MB Pro.

If I use
sudo dd if=/users/myname/linuxmint.iso of=/dev/disk2 bs=1m
It sends the file to the usb but it is still an iso file
Is there anything else I could try?
Thanks
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top