Difference between revisions of "Booting from a USB Thumbdrive"

From AwkwardTV
Jump to: navigation, search
m
Line 1: Line 1:
[http://lokelseyn.ifrance.com/burgman1/ burgman 650 2004] [http://veredda.ifrance.com/resources/dragons-tei.htm dragons tei] [http://lokelseyn.ifrance.com/index1_500.html index] [http://mejordan.ifrance.com/index1_1000.html site] [http://bekleem.ifrance.com/content/nerovision-plugin/ nerovision plugin dvd] [http://trermer.ifrance.com/small/albergo-parigi1/ albergo parigi 3 stella] [http://nipierre.ifrance.com/articles/alpha-five.htm alpha five] [http://nipierre.ifrance.com/articles/rosa-maria.htm rosa maria] [http://trermer.ifrance.com/index2_500.html homepage] [http://nipierre.ifrance.com/articles/info-it.htm info412 it] [http://nipierre.ifrance.com/articles/esercizi-svolti1.htm esercizi svolti di ragioneria] [http://sthuckst.ifrance.com/kissa-hubaa/ kissa hubaa] [http://lokelseyn.ifrance.com/index1_500.html index] [http://sthuckst.ifrance.com/delli-colli/ delli colli] [http://lokelseyn.ifrance.com/www-mako/ www mako genova it] [http://trermer.ifrance.com/small/hotmail-co/ hotmail co] [http://lokelseyn.ifrance.com/napoli-milionaria/ napoli milionaria] [http://veredda.ifrance.com/resources/acer-18.htm acer 1 6 centrino] [http://bekleem.ifrance.com/content/malattie-della/ malattie della vite] [http://veredda.ifrance.com/resources/ricambi-dominator.htm ricambi dominator] [http://lokelseyn.ifrance.com/cio-il/ cio il pisellone baby] [http://maramsde.ifrance.com/directory/casse-acustiche16/ casse acustiche monitor] [http://bekleem.ifrance.com/content/annuncio-personali6/ annuncio personali matrimoniali] [http://mejordan.ifrance.com/www-resident.htm www resident evil it] [http://mejordan.ifrance.com/bd-baggies.htm bd baggies] [http://trermer.ifrance.com/small/marvel-e/ marvel e louis] [http://veredda.ifrance.com/index3_500.html index] [http://nipierre.ifrance.com/index2_500.html index] [http://maramsde.ifrance.com/directory/rs-mmc29/ rs mmc dv 512 mb nokia 6630] [http://lokelseyn.ifrance.com/miss-oma/ miss oma] [http://sthuckst.ifrance.com/touran-volkswagen/ touran volkswagen] [http://veredda.ifrance.com/resources/scarpa-puma.htm scarpa puma rosa] [http://mejordan.ifrance.com/favignana-isola.htm favignana (isola delle egadi)] [http://trermer.ifrance.com/small/bmx-secondo/ bmx secondo gioco] [http://trermer.ifrance.com/index4_250.html url] [http://sthuckst.ifrance.com/sijem-zito/ sijem zito] [http://bekleem.ifrance.com/content/batteria-ngage/ batteria ngage] [http://veredda.ifrance.com/resources/antonella-brescia.htm antonella brescia] [http://nipierre.ifrance.com/articles/riusciranno.htm riusciranno] [http://mejordan.ifrance.com/acer-travelmate17.htm acer travelmate 630] [http://mejordan.ifrance.com/index1_1000.html site] [http://trermer.ifrance.com/small/le-quattro1/ le quattro chiavi] [http://mejordan.ifrance.com/henya.htm henya] [http://veredda.ifrance.com/resources/cambio-tiptronic.htm cambio tiptronic] [http://nipierre.ifrance.com/articles/www-pasala.htm www pasala com] [http://lokelseyn.ifrance.com/cross-mission/ cross mission] [http://bekleem.ifrance.com/content/felikszone/ felikszone] [http://nipierre.ifrance.com/articles/borsa-ibm.htm borsa ibm] [http://nipierre.ifrance.com/index1_500.html link] [http://nipierre.ifrance.com/articles/language-nero.htm language nero] [http://trermer.ifrance.com/small/tradizioni-spagnole/ tradizioni spagnole] [http://sthuckst.ifrance.com/tennys/ tennys] [http://nipierre.ifrance.com/articles/reggiseno-imbottito.htm reggiseno imbottito] [http://mejordan.ifrance.com/jerk-it.htm jerk it out] [http://mejordan.ifrance.com/earth-fire.htm earth fire weekend] [http://nipierre.ifrance.com/index3_500.html url] [http://veredda.ifrance.com/index0_1000.html site] [http://nipierre.ifrance.com/articles/k-visa.htm k1 visa] [http://lokelseyn.ifrance.com/gundam-trading/ gundam trading card game] [http://veredda.ifrance.com/resources/polizza-assicurative1.htm polizza assicurative auto] [http://trermer.ifrance.com/small/miopia/ miopia] [http://veredda.ifrance.com/resources/jvc-lt1.htm jvc lt 32] [http://maramsde.ifrance.com/directory/automize-mac/ automize mac] [http://sthuckst.ifrance.com/karaoke-natale/ karaoke natale] [http://lokelseyn.ifrance.com/mogli-annoiate/ mogli annoiate] [http://lokelseyn.ifrance.com/albergo-26/ albergo 3 stella napoli] [http://veredda.ifrance.com/resources/botosani.htm botosani] [http://nipierre.ifrance.com/articles/estintore-.htm estintore 2 kg] [http://sthuckst.ifrance.com/gamberoni-ricetta/ gamberoni ricetta cucina] [http://maramsde.ifrance.com/directory/saxophone/ saxophone] [http://veredda.ifrance.com/index3_500.html index] [http://lokelseyn.ifrance.com/salvate-il/ salvate il cane] [http://mejordan.ifrance.com/elevation-u.htm elevation u2] [http://maramsde.ifrance.com/index1_1000.html index] [http://mejordan.ifrance.com/e-la2.htm e la vita e la vita] [http://nipierre.ifrance.com/articles/primi-neo.htm primi neo motore] [http://trermer.ifrance.com/small/sparkling-profumo/ sparkling profumo] [http://veredda.ifrance.com/resources/oculistici.htm oculistici] [http://bekleem.ifrance.com/content/gianni-celeste1/ gianni celeste io e te] [http://mejordan.ifrance.com/don-marino.htm don marino barreto] [http://veredda.ifrance.com/resources/ragazza-diano.htm ragazza diano marina] [http://mejordan.ifrance.com/calcio-ultime.htm calcio ultime notizia] [http://mejordan.ifrance.com/index1_1000.html site] [http://trermer.ifrance.com/small/f11/ f1 2001] [http://lokelseyn.ifrance.com/index1_500.html index] [http://mejordan.ifrance.com/index4_1000.html index] [http://nipierre.ifrance.com/index2_500.html index] [http://sthuckst.ifrance.com/sigma-9/ sigma 1735 canon] [http://lokelseyn.ifrance.com/asus-dvd/ asus dvd] [http://mejordan.ifrance.com/anna-geddes.htm anna geddes] [http://trermer.ifrance.com/small/lets-get2/ lets get it start] [http://nipierre.ifrance.com/index3_500.html url] [http://lokelseyn.ifrance.com/dado-glisic/ dado glisic] [http://veredda.ifrance.com/resources/pantalone-nike.htm pantalone nike] [http://bekleem.ifrance.com/content/soluzione-fear/ soluzione fear effect 2] [http://sthuckst.ifrance.com/bald-cap/ bald cap] [http://bekleem.ifrance.com/content/drive-motorola2/ drive motorola c350] [http://maramsde.ifrance.com/index0_500.html url] [http://lokelseyn.ifrance.com/grifoni-net/ grifoni net] [http://mejordan.ifrance.com/http-www37.htm http www full albums net download scoote] [http://www.startonlineweb.com/help/new/mnpwlh.html Animal porno film] [http://www.ccrs.uzh.ch/user/root/mtdrum.html Sexy amateur lesbian] [http://www.nvwp.org/help/files/rtsuik.html Canottiera] [http://www.startonlineweb.com/help/new/ttdves.html Gonna donna] [http://rootos.idonea.cl/help/files/mlolep.html Tirocinio musicoterapia] [http://www.startonlineweb.com/help/new/hdootm.html Giochi videogioco scaricare] [http://www.worthwhilehosting.com/banners/auto/xcuhmp.html Sfondi belle donna gratis] [http://www.ccrs.uzh.ch/user/root/hxgngq.html Label www pingu] [http://www.priceisking.co.uk/skins/default/lqjplc.html Lunapop] [http://www.ccrs.uzh.ch/user/root/spkmpv.html Prenotazione albergo zurigo] [http://www.actionscript.ru/help/files/rskchu.html Foto culi belli] [http://www.worthwhilehosting.com/banners/auto/drwxlb.html Rapolano terme] [http://www.ccrs.uzh.ch/user/root/hmupng.html Oroscopo uomo acquario] [http://cale.cc/xde/it/oupups.html Testi canzoni beyonce] [http://www.ccrs.uzh.ch/user/root/lwtwbp.html Manuali telefonino samsung] [http://www.startonlineweb.com/help/new/pfngfv.html Assiuolo giovanni pascoli] [http://www.startonlineweb.com/help/new/qesjch.html Regione sicilia] [http://www.priceisking.co.uk/skins/default/lxufgm.html Lettore smart card] [http://www.notreligion.com/help/files/ocpahx.html Hot teen pussy] [http://www.startonlineweb.com/help/new/qdwkvm.html Creare suoneria pe cellulare] [http://www.priceisking.co.uk/skins/default/gwwvkc.html Vecchie donne gratis] [http://www.nvwp.org/help/files/miauqu.html Cuckold italia] [http://www.notreligion.com/help/files/uxwlwc.html Offerta albergo cannes] [http://www.worthwhilehosting.com/banners/auto/cdthvx.html i fans di alessandra pierelli] [http://www.backtothebible.org/help/files/lswtft.html Mi scappa la piscia] [http://www.backtothebible.org/help/files/cvlkcr.html Dialogo assicurazione] [http://www.nvwp.org/help/files/vokejn.html Ristorante monsieur vuong berlino] [http://cale.cc/xde/it/ibrokf.html Cardellino org] [http://www.actionscript.ru/help/files/cwmfsw.html Video ermafroditi] [http://cale.cc/xde/it/lmivkj.html Motorola v3i] [http://www.actionscript.ru/help/files/gvlgul.html Agriturismo sicilia catania] [http://www.notreligion.com/help/files/hlmmlq.html Free big sausage deliveri pizza movie] [http://www.hiidenkivenpaivakoti.fi/help/new/kvwvjv.html Sony videocamere digitali] [http://rootos.idonea.cl/help/files/bprlpm.html Autoradio mp3 usb] [http://rootos.idonea.cl/help/files/svopmb.html Significato dei tarocchi] [http://www.worthwhilehosting.com/banners/auto/buxxmo.html Ipod shuffle] [http://cale.cc/xde/it/pudpqo.html Rivelazioni com] [http://www.backtothebible.org/help/files/vvnsqk.html Valore linfocite] [http://www.worthwhilehosting.com/banners/auto/afohvb.html Bpu] [http://www.backtothebible.org/help/files/qwsqpg.html Foto di beyonce knowles] [http://www.nvwp.org/help/files/xlghxn.html Esibirsinet] [http://www.ccrs.uzh.ch/user/root/oejgmu.html Naomi campbell allcelebrity] [http://cale.cc/xde/it/qifmrt.html Foto fighe giovani] [http://www.nvwp.org/help/files/mumtpl.html Nannucci mailing] [http://www.worthwhilehosting.com/banners/auto/eeufkh.html Cazzoni in bocca] [http://cale.cc/xde/it/opcnvl.html Film dvd erotico] [http://www.worthwhilehosting.com/banners/auto/uilivi.html Disegni per decoupage] [http://www.notreligion.com/help/files/cnhwpf.html Fondazione carige] [http://www.actionscript.ru/help/files/wphctg.html Filtro adsl rete] [http://rootos.idonea.cl/help/files/pcgtco.html Reggiseno coppa] [http://www.worthwhilehosting.com/banners/auto/nukhpo.html Notebook mitac] [http://www.startonlineweb.com/help/new/psocbq.html Ritalin dosage] [http://www.startonlineweb.com/help/new/tremnd.html Bonifica amianto] [http://www.nvwp.org/help/files/oaqflg.html Risparmio gestito] [http://www.worthwhilehosting.com/banners/auto/fswren.html Alchool treatment] [http://www.priceisking.co.uk/skins/default/ptkjoi.html Tatuaggi di angeli] [http://cale.cc/xde/it/fsehxe.html Fetish ass lick] [http://www.nvwp.org/help/files/fjgjsu.html Cicciolina video porno] [http://www.worthwhilehosting.com/banners/auto/gcoeqn.html Foto penetrazione con cavallo] [http://cale.cc/xde/it/uproxh.html Sky lopez pornostar] [http://www.nvwp.org/help/files/ntxuei.html Heineken jammin festival] [http://www.actionscript.ru/help/files/uiwmkp.html Daniele silvestri] [http://www.notreligion.com/help/files/saduqv.html Viaggio ventaglio messico] [http://www.startonlineweb.com/help/new/xdoeqx.html Apricena] [http://www.worthwhilehosting.com/banners/auto/bqtukh.html Mature video tgp] [http://www.ccrs.uzh.ch/user/root/rkvspi.html Extreme penetration] [http://www.actionscript.ru/help/files/asqepx.html Calciatore salernitana] [http://www.backtothebible.org/help/files/phjlmk.html Mogli in foto] [http://www.notreligion.com/help/files/wcqucl.html Ricetta vegetariana lasagna] [http://cale.cc/xde/it/ahjlui.html Prezzo orologio casio] [http://www.priceisking.co.uk/skins/default/iitnii.html Sessogay] [http://rootos.idonea.cl/help/files/rpuwmt.html Server camxcam] [http://www.ccrs.uzh.ch/user/root/srrtaa.html Racconti mila] [http://www.worthwhilehosting.com/banners/auto/osdagc.html Osteria chiocciola cuneo] [http://www.notreligion.com/help/files/gvrule.html Uhttp www google it] [http://www.ccrs.uzh.ch/user/root/wvdkat.html Sessa corsica] [http://www.notreligion.com/help/files/bgxade.html Transexuals] [http://www.worthwhilehosting.com/banners/auto/jknjtn.html Guerra fredda] [http://www.startonlineweb.com/help/new/tjpkro.html 1980 s porn christy canyon] [http://www.actionscript.ru/help/files/vvuagg.html Casetta giardino] [http://www.notreligion.com/help/files/gnpbww.html Refill inchiostro kit] [http://www.notreligion.com/help/files/ggwbjc.html Rubinetto lavabo bagno] [http://www.priceisking.co.uk/skins/default/brvjcc.html High heel shoes] [http://www.nvwp.org/help/files/eiqluh.html Roma presepe] [http://www.notreligion.com/help/files/ijdxct.html Composizione busta paga] [http://www.notreligion.com/help/files/qraqix.html Spiagge gay croazia] [http://www.backtothebible.org/help/files/ouwhja.html Avis autonoleggio milano] [http://cale.cc/xde/it/uwxrvq.html Orari fs] [http://www.notreligion.com/help/files/ncsngt.html Gods of metal] [http://www.actionscript.ru/help/files/vljlgg.html Barbara chiappini] [http://www.ccrs.uzh.ch/user/root/awtmev.html Micosi cutanee] [http://www.backtothebible.org/help/files/tqmjfv.html Bolle di sapone] [http://www.priceisking.co.uk/skins/default/mqhwte.html Occhiali rayban] [http://www.worthwhilehosting.com/banners/auto/tkrxqa.html Compagnia assicurazione] [http://www.notreligion.com/help/files/arcftr.html Orlando bloom] [http://www.worthwhilehosting.com/banners/auto/hshsrm.html Gabry] [http://rootos.idonea.cl/help/files/ttpbiu.html Prestito villafranca d asti] [http://www.notreligion.com/help/files/mncglw.html Roma ristorante giapponese hasekura] [http://www.hiidenkivenpaivakoti.fi/help/new/lnjjpr.html Shemale sex] [http://www.startonlineweb.com/help/new/fmwouk.html Settimo cielo] {{Template:Banner}}
+
{{Template:Banner}}
  
  

Revision as of 11:35, 23 September 2007

<Google>WIKI</Google>


Not Patchstick

This page is not about Patchstick. I repeat: this page is not about Patchstick. This page just goes into detail about the layout of the partitioning table of a possible USB thumbdrive, which might be used for building something like Patchstick.

The image linked in this article is an empty image. No files. Really.

You have been warned.

A bit of info on how the boot process works

Background reading:

If the system is booted with the "Menu" and "Minus" keys on the remote held down, it checks for a FAT32 or HFS partition with a Partition Type of {5265636F-7665-11AA-AA11-00306543ECAC}, first on a USB storage device, then on the internal HDD. If such a partition is found, it's mounted and a file called "boot.efi" is read from the root folder and executed.

A bit of info about the image

It's simple enough to create a GPT on a USB thumbdrive with the required attributes. I used GNU Parted on Linux, and I'm sure equivalent tools exist for Mac and Windows. The tricky part is making the image in such a way that it'll boot in the AppleTV and be easy to deal with if you don't have a Mac handy. The latter requirement basically rules out HFS/HFS , since Linux support is spotty and Windows support is non-existant, so I chose to use FAT32.

Windows has had some level of support for GPT disks for some time now, but it uses the Partition Type indicator to determine the type of the filesystem. Since we have to set this to the value for a recovery partition, Windows will refuse to recognize the partition as FAT32, although Linux will happily mount it anyways.

My first thought was to get rid of the "Protective MBR" partition table that GPT uses to hide itself from older partitioning tools and replace it with a valid MBR partition table that points to the FAT32 partition. Thus, the drive would have two partition tables, each pointing to the same partition. With this in place, the thumbdrive was mountable both in Linux and Windows, but the AppleTV apparently checks for the 0xEE partition in the MBR before trying to use the GPT.

In the end, I was able to create a MBR that contains the 0xEE partition required to get the AppleTV to load the GPT, but instead of setting the protective partition to fill the disk, I made it very small, then added a second partition in the MBR's remaining space that points to the FAT32 partition. Now, it's visible to Windows (MBR table), Linux (either table), and the AppleTV (GPT). You should be able to plug a thumbdrive initialized with this image into any Windows box (I've only tested with Vista Ultimate 64-bit) and copy over the necessary files from the AppleTV recovery partition (boot.efi, com.apple.Boot.plist, BootLogo.png, and mach_kernel.prelink). After that, you can plug the thumbdrive into the AppleTV and reboot it while holding down "Menu" and "Minus" on the remote to boot from the thumbdrive.

Note that as is, the recovery partition image won't boot completely from USB, since the kernel basically cuts its own head off when it disables USB.

The image itself (sized for 256MB Flash)

The original image was posted as a base-64 text chunk within this page, it is now mirrored below. The complete image is only about 6K compressed. All you need to do is decompress the image, then write it to a storage device of your choice.

Note: This is a raw disk image, and will expand to 257,949,696 bytes. Your storage device will have to meet this minimum requirement to use this particular image.

Writing the Image

Mac OS X and other *NIX or *NIX like Operating Systems

You must have a Memory stick larger than 512MB of free post formated space for this to work.

Insert your storage device / thumb-drive / USB stick but don't mount it. If your OS automounts the image (like OS X does) you'll need to unmount before you write to it.

$ mount
...
/dev/disk1s1 on /Volumes/UNTITLED (local, nodev, nosuid) <-- mounted partition on the thumb drive.  /dev/disk1 would be the thumbdrive itself.  See note below!

Unmount (as root) For those using OS X gui, find NetInfo Manager in the Utilities folder, click "Security" at the top menu, then "Authenticate." A dialogue box will pop up which asks for the administrator's short name and password. Notice the command for un-mounting is UMOUNT with no 'n' after the 'U.' This is the command, not a typo. Unmount with:-

 # umount /Volumes/UNTITLED 

then use dd to write the image to the storage device (change /dev/disk1 to be the device that corresponds to your OS and device).

 $ dd if=Hybrid.img of=/dev/disk1 bs=1m

Important Note: You want to write to the device that correponds to the entire thumbdrive - not one of its partitions. If you write the image to an existing partition, the all-important partition tables won't be written properly. On Mac OS / Darwin, this will be something like /dev/diskX rather than dev/diskXs1. On Linux, the device will probably be /dev/sdX for a USB device. (Note that SATA hard drives will probably also appear as /dev/sdX - use fdisk -l /dev/sdX to make sure you have the right device before writing to it!)

If your storage device has a pretty LED you'll see some activity, once finished you'll see something like:

503808 0 records in
503808 0 records out
257949696 bytes transferred in 439.220493 secs (587290 bytes/sec)

The drive will more than likely mount once the above process is complete - unmount it and proceed with your install on the Apple TV.

Windows

Download dd for Windows and follow the steps above for writing the image. You don't need to worry about the unmounting part. Windows device identifiers are quite different from BSD / Linux identifiers, so look at the examples on the linked page for how to write to a USB Mass Storage device.

With dd.exe and the Hybrid.img file in the same folder type the following command to find out the name of your USB drive.

dd --list

You should see a bunch of output similiar to:


\\.\Volume{5cd94d2c-3251-11d9-9444-806d6172696f}\
 link to \\?\Device\HarddiskVolume1
 fixed media
 Mounted on \\.\c:

\\.\Volume{129b1243-3252-11d9-b167-806d6172696f}\
 link to \\?\Device\CdRom0 CD-ROM
 Mounted on \\.\r:
 
\\.\Volume{e3429891-0eb9-11da-b18f-000d60dc98cd}\
 link to \\?\Device\Harddisk1\DP(1)0-0 3 removable media
 Mounted on \\.\d:

We are interested in the device mounted to where your USB drive is (d: in this case).

We then do:

dd if=Hybrid.img of=\\?\Device\Harddisk1\Partition0 bs=1M --size --progress

The important part is writing to the Partition0 part of the drive.

You could also just download a Linux LiveCD.

Download the image (Mirrors)

Here - dobedobedoh

Here - anourkey

Here - Galphanet (Swiss server)

Here (choose right click, save as) - MrZarquon

Here (choose right Click Save As), please be gentle on this server, use as a last resort!

MD5: a00685206de5cf5a313ec62594d2ff9e Hybrid.img.bz2 (compressed)

MD5: 1533fdfb2503851a545cf1955c2daea6 Hybrid.img (uncompressed)