xboxscene.org forums

Pages: [1] 2 3 ... 5

Author Topic: How to Install Ubuntu onto Your Xbox 360 Hard Drive  (Read 1410 times)

stonersmurff

  • Archived User
  • Newbie
  • *
  • Posts: 7
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« on: April 01, 2007, 02:51:00 AM »

How to Install Ubuntu onto your Xbox 360 Hard Drive
(Using Debootstrap)


Introduction:
This is an advanced guide for installing Ubuntu to an Xbox360. I am assuming you already have Linux experience and understand the fundamentals. Anybody who is willing to write a guide for beginners can feel free to reference any information from this guide.


Prerequisites:
•   Xbox360 with a kernel version of 4532 or 4548. (If your kernel version is lower then 4532, you will need to update using HD_DVD_10-2006.zip.)
•   Hitachi 360 DVD Drive with modified firmware (Samsung does not work!)
•   Patched King Kong disk with the new King Kong Shader exploit for XeLL.
•   Cpasjuste’s Gentoo Beta Live CD found here http://downloads.sourceforge.net/free60/ge...on-beta.tar.bz2
   You must use the above version, because the first one lacks the tools needed.
•   Internet Connection (High Speed is preferred, since you will be downloading the install packages from the internet.)
•   Microsoft VGA cable for the 360 is also recommended, since it can be difficult to see what you are doing on a TV.
•   USB Keyboard/mouse.
•   Made a backup your retail xbox360 drive. (This is very important; not doing so will make it impossible to save 360 content to the drive again!)

Backing up your Xbox360 Retail Hard Drive WARNING:
Before even considering formatting your retail Xbox 360 Hard Drive for Linux, you must take a backup of either the whole drive or just the key sector to be able to use it again for saved games and other 360 content. This can be done with disk tools such as WinHex. If you’re unsure on how to do this, do not continue!

Installing Ubuntu Linux using Cpasjuste’s Gentoo Beta Live CD:
This guide is assuming that you have already patched and burned a King Kong ISO and have the new beta live CD booting your 360 into Gentoo. If you are not this far yet, then please refer to other guides to accomplish this. You will have to login as root before starting or put sudo at the beginning of each command, same goes for the rest of the guide.

At this point you should be in Gentoo Linux. DHCP should have setup your network connection. To check type ping www.google.com into the terminal you should get a response if your network connection is up and running. If not follow these steps to manually configure your network connection:

Type:
CODE
ifconfig eth0 192.168.0.2 up

Replace 192.168.0.2 with the IP address that you want to set.

CODE
route add default gw 192.168.0.1

Replace 192.168.0.1 with the gateway address that you want to set.

CODE
vi /etc/resolv.conf
nameserver 192.168.9.1

Replace 192.168.0.1 with the nameserver address that you want to set.

Now test your connection again, ping www.google.com you should now get a response, if you don’t get a response double check your settings.

Setting up the Hard Drive:
Type
CODE
cfdisk /dev/sda

This will bring up a graphical fdisk program.
Create your Linux swap partition:
Select New > Primary > 1024 > Select Beginning
Create your Linux install partition (you have to arrow down to free space first):
Select New > Primary > Let it use the rest of the free space and just press enter

Now you should have two partitions, sda2 should have the largest portion of space and sda1 should be around 1 gig to be used for swap space, if this is correct then arrow over to write, press enter and type yes. Then quit

Once that is done you need to format the install partition with:
CODE
mkfs.ext3 /dev/sda2

Then setup your swap partition with:
CODE
mkswap /dev/sda1
sync; sync; sync
swapon /dev/sda1


Install Ubuntu to the Xbox360:
Now that your drives are formatted and partitioned, it is time to mount the install partition and make a directory to get started from:
CODE
mkdir /mnt/ubuntu
mount /dev/sda2 /mnt/ubuntu
cd /mnt/ubuntu
mkdir work
cd work


Get the Debootstrap tools:
CODE
wget http://archive.ubuntulinux.org/ubuntu/pool/main/d/debootstrap/debootstrap_0.3.3.2ubuntu3_all.deb


Extract debootstrap:
CODE
ar -xf debootstrap_0.3.3.2ubuntu3_all.deb
cd –
zcat < /mnt/ubuntu/work/data.tar.gz | tar xv


Change folder paths by typing:
CODE
export DEBOOTSTRAP_DIR=/mnt/ubuntu/usr/lib/debootstrap
export PATH=$PATH:/mnt/ubuntu/usr/sbin


Run debootstrap:
CODE
debootstrap --arch powerpc edgy /mnt/ubuntu http://archive.ubuntulinux.org/ubuntu


For the fastest installation, use a mirror closest to you. Mirrors are listed at
http://wiki.ubuntulinux.org/Archive.

Downloading the basic installation can take an hour or so.

Configure the Base System:
Once the download is complete change root to your new Ubuntu file system:
CODE
chroot /mnt/ubuntu /bin/bash


Create a custom fstab:
CODE
editor /etc/fstab


You will need to add these entry’s to your fstab:
CODE
/dev/sda2     /          ext3     defaults   0   0
/dev/sda1     none    swap    sw           0   0
proc          /proc     proc    defaults  0   0
sys          /sys      sysfs   defaults  0   0


Configure Networking:
You will now need to configure your network, below is an example. Make sure to use the settings for your network. (If you do not set a loopback as shown in the example, gnome will fail to boot correctly)
CODE
editor /etc/network/interfaces


CODE
iface lo inet loopback
auto lo

# To use dhcp:
auto eth0
iface eth0 inet dhcp

#To use static:
auto eth0
iface eth0 inet static
address 192.168.0.45
network 192.168.0.0
netmask 255.255.255.0
broadcast 192.168.0.255
gateway 192.168.0.1


Edit resolv.conf to insert your nameserver, below is an example. Make sure to use the settings for your network
CODE
editor /etc/resolv.conf

search hsd1.mn.comcast.net.
nameserver 192.168.0.1
nameserver 192.168.0.2
domain WORKGROUP


Now reboot the Xbox 360.

Booting into Ubuntu from the Hard Drive:
Since you are no longer using the live cd, you will need to burn this ISO that includes a kernel that will boot from the Hard Drive.
http://mydedibox.homelinux.com/ubuntu-inst...loader-sda2.iso

Boot this cd just as you booted the live cd. You should now be in Ubuntu Linux.

Adding users, groups, setting root password, and hostname:
Set a root password:
CODE
passwd root


Create a user for yourself:
CODE
adduser your_username


Create an admin group:
CODE
addgroup admin


Add yourself to the admin group:
CODE
adduser your_username admin


Add your username to sudoers:
CODE
visudo
your_username ALL=(ALL) ALL


Set a host name:
CODE
echo Xenon > /etc/hostname


Installing Ubuntu Desktop (Gnome):
Make sure your logged in as root and type:
CODE
aptitude install ubuntu-desktop


This also can take up to and hour or so. When it’s almost finished you will get a resolution setup screen, select 1280x768 as the default resolution with space bar, and deselect the rest. The setup will continue for ten or so more minutes.

Configuring X:
Next you will need to download the xenon Xorg driver.
Type:
CODE
cd /usr/lib/xorg/modules/drivers/
wget http://mydedibox.homelinux.com/ubuntu-install/xenonfb_drv.so


Then run the visual Xorg configuration:
CODE
sudo dpkg-reconfigure xserver-xorg


Setup as follows:

1.   Attempt to autodetect video hardware? > No
2.   X Server Driver: Xenonfb
3.   Generic Video Card  > Enter
4.   Video card’s bus identifier: Press enter for default
5.   Amount of memory: Press enter for default
6.   Use kernel framebuffer device interface? > Yes
7.   Autodetect keyboard layout? > Yes
8.   Keyboard layout: us              
That’s if you’re in the united states, if your not then fill in your default layout.
9.   XKB rule set to use: xorg
10.   Keyboard model: choose your rule set based on the options
11.   Keyboard variant: leave blank if you’re in the U.S.
12.   Keyboard options: Leave as default
13.   Mouse Protocol: ImPS/2
14.   Emulate a 3 button mouse? > Your choice
15.   Xorg server modules: Default
16.   Write default Files section to configuration file? > Yes
17.   Attempt monitor detection? > Yes
18.   Use generic monitor if it doesn’t detect it.
19.   Video modes to be used by the X server: 1280x768
20.   Method for selecting the monitor characteristics: Medium
21.   Monitors best video mode: Choose what’s best for your monitor.
22.   Write monitor sync ranges to the configuration file? > Yes
23.   Desired default color depth in bits: 24

Now reboot and you will be greeted by ubuntu with Gnome the next time you load the XeLL boot cd.

Have fun!!

Guide written by stonersmurf ( http://xboxhacker.net / http://free60.org/)
Thanks to:
Cpasjuste for all the help.
Tmbinc for all the great tools, drivers, and patches.
Gentoo and Ubuntu developers for the great distro’s.

Where to find more info on Linux for Xbox 360:
http://www.free60.org/
Free60 is a project towards porting GNU/Linux, BSD, Darwin and related open-source operating systems to the Microsoft Xbox 360 video game console.

Microsoft, Xbox, Xbox360 (and probably some more) are registered trademarks by
Microsoft Corp. No affiliation between the Free60 Project and Microsoft Corp.
exists or is implied. All other trademarks and copyrights are
property of their respective owners.


This post has been edited by stonersmurff: Apr 1 2007, 09:58 AM
Logged

burgerbee

  • Archived User
  • Newbie
  • *
  • Posts: 20
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #1 on: April 03, 2007, 01:26:00 AM »

Works perfekt! Tnx for a nice tutorial.

The only thing i added was "restricted universe multiverse"  in /etc/apt/sources.list. It is only "main" after debootstrap.

Will try Feisty when i come home from work. Tnx again.

/BurgerBee
Logged

burgerbee

  • Archived User
  • Newbie
  • *
  • Posts: 20
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #2 on: April 03, 2007, 08:38:00 AM »

Ubuntu 7.04 Beta

Officially isnt Ubuntu supported on PPC after 6.10, but here we dont care about that  biggrin.gif

I was too lazy for reinstalling from scratch but that should problably work with this tutorial. Just change to feisty like below. Please post if you try it. I will do it next time.

CODE

debootstrap --arch powerpc feisty /mnt/ubuntu http://archive.ubuntulinux.org/ubuntu


I updated instead. Edit /etc/apt/sources.list

CODE

deb http://ftp.acc.umu.se/mirror/ubuntu  feisty main restricted universe multiverse


Update the packagelist and then do the upgrade

CODE

apt-get update
apt-get dist-upgrade -y


Got some small non-critical errors like missing multi-cast support in the kernel, but nothing special. It works fine directly. Will post again when I have done some tweeking.

BurgerBee, posting from Ubuntu 7.04 Beta
Logged

Cpas

  • Archived User
  • Newbie
  • *
  • Posts: 40
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #3 on: April 03, 2007, 11:43:00 AM »

Thanks stonersmurff good tut and job smile.gif
Logged

throwingks

  • Archived User
  • Hero Member
  • *
  • Posts: 2690
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #4 on: April 04, 2007, 02:41:00 AM »

Nice work!
Logged

Perplexer

  • Recovered User
  • Hero Member
  • *
  • Posts: 1096
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #5 on: April 05, 2007, 12:59:00 PM »

Post deserves to be pinned, or put in the tutorials section.

This is quite possibly the most valuable "first post" from a member I've ever seen.  Thanks!
beerchug.gif
Logged

semajturtle

  • Archived User
  • Newbie
  • *
  • Posts: 9
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #6 on: April 05, 2007, 04:35:00 PM »

Absolutely awesome tut. Is it possible to format any sata hard drive to work with this since it erases all the ms stuff anyways? Throw a 300gb sata in there and you have a kick ass desktop.
Logged

stonersmurff

  • Archived User
  • Newbie
  • *
  • Posts: 7
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #7 on: April 05, 2007, 07:57:00 PM »

QUOTE(semajturtle @ Apr 5 2007, 11:42 PM) *

Absolutely awesome tut. Is it possible to format any sata hard drive to work with this since it erases all the ms stuff anyways? Throw a 300gb sata in there and you have a kick ass desktop.

Sure, it is possible to use any SATA hard drive no matter the size, just make sure you buy a 2.5 SATA laptop hard drive. Then its as simple as swapping out the retail 360 drive for your new one.

BTW: Since I wrote this guide there has been a few updates, no samsung support yet, but VGA scaling has been fixed. So if your using a VGA cable and want to go above 1280x700 resolution, use this boot CD in place of the one posted above:
https://home.comcast.net/~ssmurf/XELL-Bootl...er-sda2-new.iso

You might have to rerun Xorg config to choose additional resolutions, just follow the same steps as above, but select the new resolutions you prefer. (IMG:style_emoticons/default/smile.gif)
Logged

burgerbee

  • Archived User
  • Newbie
  • *
  • Posts: 20
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #8 on: April 08, 2007, 04:33:00 PM »

Have been thinking a bit about Xbox 360 optimization of Ubuntu. We want to keep up with the Gentoo folks :-)

Here is some non-scientific compiler tests I did. I dont think we can get speed gains like this but there should be atleast some gain from rebuilding.

CODE

bongy@xbox360:~$ gcc -mpowerpc speedtest.c -o speed;./speed
10E6 RDTSC time=1862 ms
10E6 RDTSC time=1863 ms
10E6 RDTSC time=1862 ms
bongy@xbox360:~$ gcc -mpowerpc64 speedtest.c -o speed;./speed
10E6 RDTSC time=1812 ms
10E6 RDTSC time=1812 ms
10E6 RDTSC time=1812 ms
bongy@xbox360:~$ gcc -mpowerpc -Os speedtest.c -o speed;./speed
10E6 RDTSC time=708 ms
10E6 RDTSC time=709 ms
10E6 RDTSC time=708 ms
bongy@xbox360:~$ gcc -mpowerpc64 -Os speedtest.c -o speed;./speed
10E6 RDTSC time=702 ms
10E6 RDTSC time=702 ms
10E6 RDTSC time=702 ms


So where could we start?

Like Gentoo you can go all the way from source with Ubuntu

CODE

apt-get -b source packagename


and for dependencies

CODE

apt-get build-dep packagename


Maybe just go for ubuntu-desktop and dependencies this way? (Doesnt look like debootstrap will help much if we want to go from source.)

Another way is to find an build script and make a new unofficial PPC64 depository and hook up depootstrap.

Just some random midnight thoughts.

/BurgerBee

Logged

epsilon72

  • Archived User
  • Hero Member
  • *
  • Posts: 712
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #9 on: April 08, 2007, 04:40:00 PM »

text based install still scares me, but that is a very good guide. (IMG:style_emoticons/default/beerchug.gif)

This post has been edited by epsilon72: Apr 8 2007, 11:40 PM
Logged

JKD

  • Archived User
  • Newbie
  • *
  • Posts: 33
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #10 on: April 08, 2007, 04:41:00 PM »

QUOTE(Perplexer @ Apr 5 2007, 09:06 PM) View Post

Post deserves to be pinned, or put in the tutorials section.

This is quite possibly the most valuable "first post" from a member I've ever seen.  Thanks!
beerchug.gif



Totally agree. Respect  biggrin.gif
Logged

Olsenius

  • Archived User
  • Newbie
  • *
  • Posts: 2
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #11 on: April 11, 2007, 10:16:00 AM »

Tried installing with

CODE

debootstrap --arch powerpc feisty /mnt/ubuntu http://no.archive.ubuntu.com/ubuntu/


Froze at "Configuring libssl0.9.8". Froze as in no keyboard, no mouse etc.

Ill try it once more b4 i get edgy and upgrade afterwards.
Logged

Olsenius

  • Archived User
  • Newbie
  • *
  • Posts: 2
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #12 on: April 11, 2007, 11:22:00 AM »

QUOTE(Olsenius @ Apr 11 2007, 06:23 PM) View Post

Tried installing with

CODE

debootstrap --arch powerpc feisty /mnt/ubuntu http://no.archive.ubuntu.com/ubuntu/


Froze at "Configuring libssl0.9.8". Froze as in no keyboard, no mouse etc.

Ill try it once more b4 i get edgy and upgrade afterwards.



Worked on second try.
Logged

burgerbee

  • Archived User
  • Newbie
  • *
  • Posts: 20
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #13 on: April 12, 2007, 04:02:00 PM »

a bit off-topic but still....

Debian Etch 64-bit

I took a trip to the country of 64-bits over at http://debian-ppc64.alioth.debian.org/.

Debootstraped with...
CODE

wget http://ftp.se.debian.org/debian/pool/main/d/debootstrap/debootstrap_0.3.3.2_all.deb


and then ran it on...
CODE

debootstrap --arch ppc64 sid /mnt/debian http://debian-ppc64.alioth.debian.org

(etch didnt work at this stage)

adjusted /etc/apt/sources.list again
CODE

deb http://debian-ppc64.alioth.debian.org stable main contrib non-free
deb http://debian-ppc64.alioth.debian.org testing main contrib non-free
deb http://debian-ppc64.alioth.debian.org unstable main contrib non-free
deb http://debian-ppc64.alioth.debian.org experimental main contrib non-free


and updated to Etch...
CODE

apt-get update
apt-get upgrade -y
apt-get dist-upgrade -y


O well, they said 98% of the packages was built with autobuilder, but it felt more like 50%. This could be good option if you are after a LAMP-server or so. Not for the desktop atm. They should have credit for building and serving us PPC64 anyway. Tnx!

/BurgerBee

Edit: spelling

This post has been edited by burgerbee: Apr 12 2007, 11:20 PM
Logged

seaweed

  • Archived User
  • Newbie
  • *
  • Posts: 20
How to Install Ubuntu onto Your Xbox 360 Hard Drive
« Reply #14 on: April 15, 2007, 03:53:00 AM »

Great tutorial!

Any chance of installing linux on usb-disk yet?

I use component cables to my tv (doesnt support vga), how will this look?

This post has been edited by seaweed: Apr 15 2007, 10:54 AM
Logged
Pages: [1] 2 3 ... 5