Jump to content

Ubuntu on LG Optimus 2X


Guest jastonas

Recommended Posts

Guest Le_PoUnT

LG2X has a Tegra processor, which is not "fully" supported by Froyo. Perhaps with Gingerbread, that will be available... but only perhaps.

Edited by Le_PoUnT
Link to comment
Share on other sites

Guest thedicemaster
LG2X has a Tegra processor, which is not "fully" supported by Froyo. Perhaps with Gingerbread, that will be available... but only perhaps.

cpu doesn't matter.

that ubuntu image works fine on the advent vega, which has froyo and a tegra 2 as well.

Link to comment
Share on other sites

Guest theguv
Has anyone managed to run ubuntu on their 2X?

I tried using the method and files from this thread but when running sh ubuntu.sh I just get a reboot.

That script uses the wrong paths on the 2x. I've managed to start ubuntu in this way using a script like this:

This assumes that your ubuntu.img file is in /mnt/sdcard/_ExternalSD/ubuntu/ubuntu.img (if it's not, change the path on the first line)

and that you have created the directory /data/local/mnt.

Save this script as runubuntu.sh and make it executable using chmod +x runubuntu.sh

then you can start it with either in adb shell or in a terminal on the phone. (Remember to su first)


export kit=/mnt/sdcard/_ExternalSD/ubuntu
export bin=/system/bin
export mnt=/data/local/mnt
export PATH=$bin:/usr/bin:/usr/sbin:/bin:$PATH
export TERM=linux
export HOME=/root
mount -o loop,noatime -t ext2 $kit/ubuntu.img $mnt
mount -t devpts devpts $mnt/dev/pts
mount -t proc proc $mnt/proc
mount -t sysfs sysfs $mnt/sys
sysctl -w net.ipv4.ip_forward=1

echo "Setting /etc/resolv.conf to Google Open DNS 8.8.8.8 and 8.8.4.4"
echo "nameserver 8.8.8.8" > $mnt/etc/resolv.conf
echo "nameserver 8.8.4.4" >> $mnt/etc/resolv.conf
echo "Setting localhost on /etc/hosts "
echo "127.0.0.1 localhost" > $mnt/etc/hosts
echo "READY TO ROCK AND ROLL BABY! "
echo "Brought to you by NexusOneHacks.net and the open source community! "
echo " "
chroot $mnt /bin/bash

#After exit command is executed clear it all up
echo " "

echo "Shutting down Ubuntu"
umount $mnt/dev/pts
umount $mnt/proc
umount $mnt/sys
umount $mnt
echo "Reboot device if umount didn't succeed"[/codebox]

Link to comment
Share on other sites

Guest jastonas

/data/local/mnt exists in system...

I also created /sdcard/_ExternalSD/data/local/mnt

Yet I get this error

export PATH=/data/local/bin:$PATH

$ $su

# cd sdcard

# cd _ExternalSD

# cd ubuntu

# sh runubuntu.sh

ioctl LOOP_SET_FD failed: Device or resource busy

net.ipv4.ip_forward = 1

Setting /etc/resolv.conf to Google Open DNS 8.8.8.8 and 8.8.4.4

runubuntu.sh: cannot create /data/local/mnt/etc/resolv.conf: directory nonexistent

runubuntu.sh: cannot create /data/local/mnt/etc/resolv.conf: directory nonexistent

Setting localhost on /etc/hosts

runubuntu.sh: cannot create /data/local/mnt/etc/hosts: directory nonexistent

READY TO ROCK AND ROLL BABY!

Brought to you by NexusOneHacks.net and the open source community!

chroot: can't execute '/bin/bash': No such file or directory

Shutting down Ubuntu

failed.

Reboot device if umount didn't succeed

Sent from my Android

Link to comment
Share on other sites

Guest theguv
/data/local/mnt exists in system...

I also created /sdcard/_ExternalSD/data/local/mnt

Yet I get this error

Oh, I forgot to mention, I couldn't mount _any_ img-files as loop devices if some games already have stuff mounted. Run "mount" and look at the last entries, I know angry birds for example conflicts with this. So either you have to disable their mounts or uninstall them if you want to mount devices like this.

If someone knows a better solution than to uninstall the conflicting games, please tell me too :)

Link to comment
Share on other sites

Guest jastonas
Oh, I forgot to mention, I couldn't mount _any_ img-files as loop devices if some games already have stuff mounted. Run "mount" and look at the last entries, I know angry birds for example conflicts with this. So either you have to disable their mounts or uninstall them if you want to mount devices like this.

If someone knows a better solution than to uninstall the conflicting games, please tell me too :)

Still nothing. I even flashed a clean Rom.

I get this

# cd sdcard

# cd _ExternalSD

# cd ubuntu

# sh runubuntu.sh

mount: Invalid argument

net.ipv4.ip_forward = 1

Setting /etc/resolv.conf to Google Open DNS 8.8.8.8 and 8.8.4.4

Setting localhost on /etc/hosts

READY TO ROCK AND ROLL BABY!

Brought to you by NexusOneHacks.net and the open source community!

chroot: can't execute '/bin/bash': No such file or directory

Shutting down Ubuntu

failed.

Reboot device if umount didn't succeed

#

edit: I found this which I ll try now

Ok everyone with the chroot: can’t execute ‘/bin/bash’ error. Open you bootubuntu file with a textmanager. And change all the loop1 to loop5. And then follow the instructions again.
Edited by jastonas
Link to comment
Share on other sites

Guest theguv
Still nothing. I even flashed a clean Rom.

I get this

edit: I found this which I ll try now

the reason you cant execute bash is because the mount fails... Don't know why it's not working for you though :S

Link to comment
Share on other sites

Guest N3M35I5
the reason you cant execute bash is because the mount fails... Don't know why it's not working for you though :S

im getting the exact same error on mine too.

maybe im missing something cause the ssh command doesnt work in my terminal either. any support of this would be very helpfull. Thanks

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.