This post has already been read 40464 times!
Update on Jan 12: You should use the SeasOnPass app from fireCore — it does exactly what I outline below, only much more quickly and easily.
After a few days of screwing around with a new AppleTV 2G that came from Apple with 4.2.1 pre-installed (so no going back to older firmware) and reading numerous blogs and forums (many which are just copying the original posts) I have Plex running on my AppleTV.
Here is how I did it.
NOTE: When I use ATV in this post, I mean AppleTV 2G with firmware 4.2.1, the latest from Apple as of January 9th, 2011.
NOTE: This is a tethered-jailbreak (TJB), which means the ATV must be hooked up to your Mac via USB in order to BOOT it. Every time.
Hopefully an un-tethered jailbreak will be released soon, so that you don’t need to do this.
This post will center on installing PLEX on the ATV, and so it assumes that there have been quite a few things already done to your ATV, in order to prepare it for PLEX.
1. Jailbreak your ATV
At this time you must modify Pwnagetool in order to jailbreak the 4.2.1 ispw from Apple. A really good guide is over at funkyspacemonkey.com. There is a slightly confusing post about how to this over on the Appletvhacks.net site you can read that just to reinforce what is going on, however, the funkyspacemonkey.com is easier to follow.
What worked consistently for me is this:
- Jailbreak using Pwnagetool with JUST USB connected to ATV
- Restore Custom IPSW using iTunes with POWER and USB
- Boot ATV with POWER and USB (if you don’t have the power connected when you boot the ATV then you won’t have WIFI).
2. Boot your TJB (tethered jailbroken ATV).
Here is a good guide at funkyspacemonkey.com.
Booting my ATV consisted of:
$ cd Desktop/tboot/ $ ./tetheredboot -i iBSS.k66ap.RELEASE.dfu -k kernelcache.release.k66 Initializing libpois0n No matching processes belonging to you were found Waiting for device to enter DFU mode opening device 05ac:1227... Found device in DFU mode Checking if device is compatible with this jailbreak Checking the device type Identified device as AppleTV2,1 Preparing to upload limera1n exploit Resetting device counters Sending chunk headers Sending exploit payload Sending fake data libusb:error [darwin_transfer_status] transfer error: timed out Exploit sent Reconnecting to device Waiting 2 seconds for the device to pop up... opening device 05ac:1227... Uploading iBSS.k66ap.RELEASE.dfu to device [==================================================] 100.0% libusb:error [darwin_reset_device] ResetDevice: device not responding libusb:error [darwin_close] USBDeviceClose: no connection to an IOService Waiting 10 seconds for the device to pop up... opening device 05ac:1281... Setting to configuration 1 Setting to interface 0:0 Uploading kernelcache.release.k66 to device [==================================================] 100.0% libusb:error [darwin_transfer_status] transfer error: device not responding (value = 0xe00002ed) Exiting libpois0n
The output may look confusing, but it worked. The test is to try and ssh over to the ATV. Note that I had the Desktop/tboot/ directory setup and prepared according to the posted guides on what to do. It’s not just going to work. Read the guide.
3. Setup your ATV on your network
If you are using WIFI or wired and DHCP, you need to get on the ATV and find out what IP address it was assigned in order to complete the next step. To find the current IP of the ATV go here: [Settings/General/Network].
3. ssh into your ATV
It should be on the network and no longer connected to your mac via USB. Ssh in as root, the password is ‘alpine’.
$ ssh email@example.com
Note: Use your local IP address….
You should have a PLEX9 media server installed and a PLEX9 client running. I downloaded the latest version from Plex and installed on a MacMini and did nothing other than set it up to read my media from a local NAS, and then ran the client. I verified that it was working by purchasing and installing the Plex client from the iTunes store. This also helps support the plex project.
Installing PLEX on ATV
Now you can follow along to install PLEX and Nitro.TV. Nitro.TV is from AkwardTV and adds a nice menu interface to install additional software like weather and some additional tools.
AkwardTV’s wiki has a nice page on the AppleTV – but note it’s slightly out of date.
Commands on ATV:
Note: you do not type the ‘$’ in the commands below….
wget -O- http://apt.awkwardtv.org/awkwardtv.pub | apt-key add - $ echo "deb http://www.ambertation.de ./downloads/PLEX/" > /etc/apt/sources.list.d/plex.list $ echo "deb http://apt.awkwardtv.org ./" > /etc/apt/sources.list.d/awkwardtv.list $ apt-get update $ apt-get install com.nito.nitotv $ apt-get -f install Yes, do as I say! $ apt-get install com.nito.nitotv $ apt-get install com.plex.client-plugin
Each of the lines above was entered into the ATV via my ssh connection in the ATV’s shell.
Breakdown of the commands:
Note: some of those lines wrapped, they should not wrap in the shell. Copy and paste them into a text editor before you paste them, if you intend to.
1. Get the key for awkwardt and install it
2. Add the repos for PLEX and Nitro.TV
3. Update apt
4. The command to install nitrotv, and the subsequence commands removed libxml2-lib and sqlite3-lib, however, installing the PLEX package made everything work again.
This is what the command looked like in my shell:
Apple-TV:~ root# apt-get -f install Reading package lists... Done Building dependency tree... Done Correcting dependencies... Done The following packages will be REMOVED: libxml2-lib sqlite3-lib WARNING: The following essential packages will be removed. This should NOT be done unless you know exactly what you are doing! libxml2-lib sqlite3-lib 0 upgraded, 0 newly installed, 2 to remove and 2 not upgraded. After this operation, 36.9kB disk space will be freed. You are about to do something potentially harmful. To continue type in the phrase 'Yes, do as I say!' ?] Yes, do as I say! dpkg - warning, overriding problem because --force enabled: This is an essential package - it should not be removed. (Reading database ... 820 files and directories currently installed.) Removing libxml2-lib ... dpkg - warning, overriding problem because --force enabled: This is an essential package - it should not be removed. Removing sqlite3-lib ...
5. The last 2 commands install NitroTV and PLEX. Installing the PLEX package restarted “AppleTV” the main application interface (it was called “Lowtide” before version 4.2.1 of the iOS).
If you need to restart AppleTv just run:
$ killall AppleTV
from the shell and you should see the interface restart.
After this, Plex worked and I could connect to my Plex client running on the Macmini and play movies over WIFI.
Then I plugged in the USB cable to keep the ATV powered and moved it to my TV. Then I used the powercable to keep the ATV powered at my TV. I’m enjoying movies, and as long as there are no power interruptions, I’m ok.
Final Words, Troubleshooting and Links
Some links that I found helpful:
- Plex Forum (the original post that started it all)
- iphoneblogger (saving your SHSH blobs)
Notes on Jailbreaking – I tried dozens of times to jailbreak the ATV and almost all of them ended up with the iTunes error of 1600, which is a generic USB error. I think it may have to do with DFU mode.
The only consistent way I could get the jailbroken ISPW to load was to use Pwnagetool to get the ATV into DFU mode, then switch to iTunes and alt-restore in the custom IPWS. Trying to get the ATV into DFU mode while in iTunes never worked. YMMV.