Problems creating a Live USB for OS X from Linux Fedora 25 I've been considering to move from OS X to Linux, because I want to have full control over the source code of the os and the apps I use, and Linux and open-source software allows me that in general, without having to go against the EULA.

Bearing this in mind, I installed Fedora 25 on my Mac. I created a Live USB, with the given app for OS X, which I used to boot. I had no problems doing so, but after a while I started feeling like the os was not only comprising my hardware stability, but also there were a few tiny little bugs, which I didn't want to mess around. Furthermore, two days after installing the os, I had problems with the boot loader, and I had to format the computer again. Furthermore, I don't have graphics acceleration in my graphics card, and the Planet CCRMA repositories, which were the main reason why I moved to fedora 25, don't seem to work on my install.

Bearing all of this in mind, I want to know how can I move back to OS X, creating an OS X installer thumb drive straight in Linux. I tried doing so throughout three possible ways:


I tried to run createinstallmedia from the installaton disk, which didn't work out (I currently have a hard drive in the place of the dvd drive) - the command for doing so doesn't run in Linux, because it cannot run the specific binaries.
I tried to create an install media with sudo dd if=x of=y, straight after using dmg2iso command but it turned out not to work, simply because this has to be done using the predeceasing bash utility.
Finally, I tried to use an app called UNetbootin, but for some reason, it doesn't recognize the USB disk I need to use as a target, making it worthless (probably the software is needing some maintainance to work fine on Fedora 25)
thanks to klanomath, i realized that there was a much simpler way to fix this issue. it basically consists of: pressing alt command r in boot, to enter internet recovery. please notice that this will only work in macintosh computers released after 2010-2011. after doing so, the computer will connect to the internet and you will be able to download the stock version of your os from the cloud. after doing so, install it, then boot into the os. if it is like a really old version, you can boot into recovery mode (now installed). and download the latest version. if this procedure doesn't work, you can also download the latest version of macosx, and using createinstallmedia command in installation media, and install the latest version of osx