Linux chroot mount scripts - Transformer TF300T General

The actual creation of an arm linux chroot image is probably out here on teh internetz somewhere, but I can assist with my mounting shell script (which works).
My image is of a debian arm chroot, and the image filesystem is ext2 (a good idea for fewer writes. ie innately non-journaling), has been used extensively on fw DE .17 and I'm currently trying it out on WW .29 (thank you, miloj).
I would upload my debian img somewhere, but I've actually broken it somewhat (it works for my needs, but it's nonetheless a bit too hacked up to be reliable).
I've modified it somewhat for generalization, some of it is probably wrong and/or redundant, and it IS hackish and ugly, but it works for me (tm).
* the chroot image only need a root account (and probably bash installed, but it usually is)
* You need busybox installed.
* You need to upload your chroot image named linux.img to the internal sdcard in a folder named linux
A shell script to set things up is attached.
What you need to do:
push the install script and run it:
Code:
adb push installlinuxstuff.sh /data/local/
adb shell sh /data/local/installlinuxstuff.sh
Now you can (from adb shell or terminal emulator on device):
Code:
su -
/data/local/mnt/linux.sh
/data/local/mnt/notlinux.sh
Feel free to remove the install script at
/data/local/installlinuxstuff.sh
when you've got it up and running.
Alternative way to run the scripts from adb shell:
Code:
adb shell su -c /data/local/mnt/linux.sh
adb shell su -c /data/local/mnt/notlinux.sh
I usually symlink start and stop (in my case deb and undeb) shell scripts placed in /data/local/mnt in /system/bin (ie shell scripts with 'su -c /data/local/mnt/whatever.sh' in them) for easy start an stop from terminal emulator, and if you've gotten this far you may welcome the small advice. (in other words - don't do this unless you _really_ know what you're doing)

Debian ARMHF or ARMEL?
If you would uploaded it (good place is google drive , sharing as public, as there are no ads or bull**** and the download is extremely fast) I would love to try your image - after modifying your script so it can work on a UHS-1 class MicroSD I want to try running this off of (should give it a little more speed).

zamaditix said:
Debian ARMHF or ARMEL?
If you would uploaded it (good place is google drive , sharing as public, as there are no ads or bull**** and the download is extremely fast) I would love to try your image - after modifying your script so it can work on a UHS-1 class MicroSD I want to try running this off of (should give it a little more speed).
Click to expand...
Click to collapse
Armel (I use the same chroot installation on my phone in a smaller image file (with less stuff installed)). I've got loads of personal stuff all over it and besides - it's somewhat broken. I really don't want to try to fix it.
So I'm working on retracing my steps, creating a clean armhf ext2 image (debian wheezy base installation for now) and redo the mount script, but I can't make any promises on a release date.
Anyhu - there are loads of images (armel, at least) on teh internetz (BT5 and too many ubuntu, for instance).
Just check so our kernel can mount the filesystem.
Edit: if not you can just create a new image file with a filsystem that's mountable and copy the chroot files to it.

So the ideal image for this tablet is armhf? If I wanted to create a Gentoo image, I would go with armv7? I'm just not sure exactly which ARM architecture this tablet is.

EndlessDissent said:
So the ideal image for this tablet is armhf? If I wanted to create a Gentoo image, I would go with armv7? I'm just not sure exactly which ARM architecture this tablet is.
Click to expand...
Click to collapse
The CPU is the Tegra 3 if you want to google it and it is an ARMv7 w/ NEON extensions chip. ARMv7 specification requires hardware fp so naturally it is ARMhf.
Nice to hear, keep us updated on your progress. I'm currently running an armel copy of Ubuntu 12.04 but it has problems with some packages and others are armhf only.

When I run linux.sh, I get an error that /sdcard can't be mounted because it doesn't exist.
Code:
mount: mounting /sdcard on /data/local/mnt/linux/sdcard failed: No such file or directory
I also tried changing the script to mount /mnt/sdcard, but that didn't work either.

EndlessDissent said:
When I run linux.sh, I get an error that /sdcard can't be mounted because it doesn't exist.
Code:
mount: mounting /sdcard on /data/local/mnt/linux/sdcard failed: No such file or directory
I also tried changing the script to mount /mnt/sdcard, but that didn't work either.
Click to expand...
Click to collapse
Yes, it is somewhat hackish, like I wrote. My image has got an sdcard folder (/sdcard) inside of it where I mount /sdcard from android. (Ie chroot and mkdir /sdcard)

followed this:
http://androlinux.com/android-ubuntu-development/how-to-install-ubuntu-on-rooted-transformer-prime/
make sure you have busybox installed der. Or at least the cp command in /system/bin
works well on my TF300T, Yea its not native but im currently configuring it for kernel building ;-D

FlyingPoo said:
followed this:
http://androlinux.com/android-ubuntu-development/how-to-install-ubuntu-on-rooted-transformer-prime/
make sure you have busybox installed der. Or at least the cp command in /system/bin
works well on my TF300T, Yea its not native but im currently configuring it for kernel building ;-D
Click to expand...
Click to collapse
Why does the mount script remount a non-existing block device with an ancient (according to android) filesystem?
Code:
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
Edit: I read all the scripts, and they all mount that crap. It's not made for transformers, and on the android device it's made for it leaves /system mounted rw after you've run it, and WHEN run (installed) it modifies too much in /system/bin
Code:
# At first it copies loads of crap to /system/bin, and then:
cd /system/bin/
chmod 4777 *
It's not even "hackish" - it's just... wrong...
Will loop1 work every mount?
Code:
mknod /dev/loop1 b 7 0
losetup /dev/block/loop1
I'm almost only asking, since this thread was supposed to be about scripts?

gasingvar said:
Yes, it is somewhat hackish, like I wrote. My image has got an sdcard folder (/sdcard) inside of it where I mount /sdcard from android. (Ie chroot and mkdir /sdcard)
Click to expand...
Click to collapse
Thanks. I created /sdcard, and it works almost perfectly now. However, mounting devpts at /dev/pts doesn't seem to work. I replaced that line with
Code:
mount --bind /dev $mnt/dev
and it seems to work fine. Is there anything wrong with my method?
/dev/void said:
Why does the mount script remount a non-existing block device with an ancient (according to android) filesystem?
Code:
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
Edit: I read all the scripts, and they all mount that crap. It's not made for transformers, and on the android device it's made for it leaves /system mounted rw after you've run it, and WHEN run (installed) it modifies too much in /system/bin
Code:
# At first it copies loads of crap to /system/bin, and then:
cd /system/bin/
chmod 4777 *
It's not even "hackish" - it's just... wrong...
Will loop1 work every mount?
Code:
mknod /dev/loop1 b 7 0
losetup /dev/block/loop1
I'm almost only asking, since this thread was supposed to be about scripts?
Click to expand...
Click to collapse
I'm assuming you're talking about the link in the post you quoted, even though you seem to be referencing the OP's use of the word "hackish". The script in the OP doesn't do any of that stuff. It just creates a few directories in /data/local/mnt/ and writes the mount/unmount scripts, which themselves only un/mount appropriate directories for the tablet. As for your question, I'm not nearly experienced enough to answer it. Sorry.

EndlessDissent said:
Thanks. I created /sdcard, and it works almost perfectly now. However, mounting devpts at /dev/pts doesn't seem to work. I replaced that line with
Code:
mount --bind /dev $mnt/dev
and it seems to work fine. Is there anything wrong with my method?
Click to expand...
Click to collapse
AFAIK your mount seems to be more complete, ie more android hardware goodies accessable from the chroot environment. However - that means more things possibly going wrong (like writing to a device who's critical to the android environment).
Personally I'd try to find what "hardware goodies" and whatnot I'd need to get the chroot environment working optimally, and not mount ALL of /dev.
EndlessDissent said:
I'm assuming you're talking about the link in the post you quoted, even though you seem to be referencing the OP's use of the word "hackish". The script in the OP doesn't do any of that stuff. It just creates a few directories in /data/local/mnt/ and writes the mount/unmount scripts, which themselves only un/mount appropriate directories for the tablet. As for your question, I'm not nearly experienced enough to answer it. Sorry.
Click to expand...
Click to collapse
Yes, and the OP is very honest about his script(s) being "hackish", which I interpret to mean 'not optimal, possibly redundant but working', all of which it is (and I applaud the early release, since for instance I could get things rolling), but the ubuntu image installation and mounting scripts from the other poster ( whom I was addressing ) are plain faulty.

I am looking for a armhf build of ubuntu or debian that I can chroot (newer the better), if anyone knows of such a build that would be fantastic but if not does anyone know of an easy to follow guide to compile such a thing?

I found two pretty good guides. I mostly followed THIS ONE, but I found that it doesn't mount enough before "first boot", so what I did was follow the guide until the point where you move the image to the tablet. Then I ran the OP's installlinux.sh script, and then the mount script. However, the mount/unmount scripts need to be edited before using them. Comment out the sdcard line and probably the devpts line (mounting devpts didn't work; Bash complained that devpts didn't exist; I had to replace it with the line I mentioned a few posts above, but as /dev/void says, it could be problematic, so be careful). Mount the image, make the /sdcard directory, exit, unmount, and edit the scripts again to mount/unmount /sdcard.
Next time you enter the chroot, feel free to run the
Code:
sh /debootstrap/debootstrap --second-stage
command to build the image, and follow the linked guide until the next time it tells you to exit the session (NOTE: The second echo "whatever" > sources.list command is wrong; it should be echo "whatever" >> sources.list; Also, remember to replace "squeeze" with the appropriate Debian version, in my case, "testing"). Instead of exiting right after the apt-get update, I'd recommend playing around with the chroot and configuring whatever apps you install. You can just use the OP's scripts now and ignore the script in the linked guide.
When the guide I linked above gets to this line:
Code:
sudo debootstrap --verbose --arch armel --foreign squeeze /mnt/squeeze/ http://ftp.debian.org/debian
just replace armel with armhf, and if you want a testing image, replace squeeze with testing.
Sorry I'm not attaching my image. I made it gigantic (5GB), so I don't really have anywhere to store it, and you probably wouldn't want to download a file that big. Plus, it already has Openbox and a bunch of other things you probably don't want installed. I'm assuming you'd want GNOME or KDE instead.

Related

BusyBox Error

Im working with Andrizoid atm at seeing if we can get some progress on his Ubuntu project. Heres the issue.
Code:
busybox mount -o --bind ./dev/pts /data/local/ubuntu/dev/pts
mount: cannot read /etc/fstab: No such file or directory
In doing a little research I came across this
If there is no entry for /dev/fd0 in my fstab when I issue the command above, mount gets very confused because it doesn't know where to mount the floppy.
Click to expand...
Click to collapse
This come from http://www.tuxfiles.org/linuxhelp/fstab.html which gives a quick breakdown of what the etc/fstab file is. When i went exploring I couldnt find an etc/fstab
Code:
[B]
mount: cannot read /etc/fstab: No such file or directory
[/B]
The thing about Android though...there IS NO /ETC/FSTAB file because its become obsolete.
The init program directly mounts all filesystems and devices using either hard-coded file names or device names generated by probing the sysfs filesystem (thereby eliminating the need for a /etc/fstab file in Android). After device/system files are mounted, init reads /etc/init.rc and invokes the programs listed there (one of the first of which is the console shell).
Click to expand...
Click to collapse
EDIT: Conclusion
After bouncing some ideas around, I've come to the conclusion that it HAS to be a Busybox issue.
An Android specific variation of Busybox should take into account the fact that there isnt an etc/fstab file. The fact that these commands work on other phones leads me to think that its an Eris specific issue. If anyone remembers there were issues when using the Busybox available on the market on the Eris.
Looks like we need a Busybox update
es0tericcha0s said:
Or is there something else I can do?
Click to expand...
Click to collapse
Modify the mount command.
If the version of BusyBox is the Android version, report this issue (as a bug?). If it's the standard Linux BusyBox, the devs may not be interested. Or, if BusyBox is just calling the standard mount command, then it's not a BusyBox issue for them to worry about.
hallstevenson said:
Modify the mount command.
If the version of BusyBox is the Android version, report this issue (as a bug?). If it's the standard Linux BusyBox, the devs may not be interested. Or, if BusyBox is just calling the standard mount command, then it's not a BusyBox issue for them to worry about.
Click to expand...
Click to collapse
I'm using the Android Busybox, and those commands are being executed in an adb shell so I doubt that its calling the standard mount command-it should be calling the (hopefully) Android specific mount command. The things thats confusing me is that those same commands worked just fine for other phones. I dont see why I would get an error and others would have no issue with it?
EDIT:
And if you ave any recommendations for what I should modify the mount command to, let me know.
You mention a reference to /dev/fd0 but I'm 99.9% that's referring to the *nix mount command. The Android/BusyBox version should know better than to look for a floppy drive.
Where is BusyBox maintained ?
I did find a page about an Android ROM from Nov 2008 that mentions
- changed the "mount" symlink to be busybox's mount instead of toolbox's mount
- added an /etc/fstab file that busybox's mount can use, that lists the standard system partitions.
Click to expand...
Click to collapse
Is "mount" in fact an internal adb command ?
hallstevenson said:
You mention a reference to /dev/fd0 but I'm 99.9% that's referring to the *nix mount command. The Android/BusyBox version should know better than to look for a floppy drive.
Where is BusyBox maintained ?
I did find a page about an Android ROM from Nov 2008 that mentions Is "mount" in fact an internal adb command ?
Click to expand...
Click to collapse
The floppy drive reference was just from some background info I pulled on the etc/fstab file. I wasnt actually trying to mount a floppy disk
I have no idea where I would put in a bug report or anything. I know Stericson was the publisher of the BusyBox app thats avaiable on the market, but the one for the Eris is different anyways so idk if he could help.
Im not sure what you mean by your last statement, but mount is not a command that you can use in a shell on its own. You have to use busybox mount ...
If you can show me where you found that rom from I may be able to finish this. I was just talking to a buddy of mine about making my own /etc/fstab and slipping it in just so that the mount command would work. If theres already one put together then thats way less work for me
What I meant by referring to that info you found was that person couldn't have been talking about the Android version. I didn't think you were trying to mount a floppy.
You sure that there's no "adb mount" ? Look here, http://forum.xda-developers.com/showthread.php?t=517874. They refer to "adb shell mount".
Personally, I would just create an /etc/fstab file (I believe it can be empty) and see what happens.
hallstevenson said:
What I meant by referring to that info you found was that person couldn't have been talking about the Android version. I didn't think you were trying to mount a floppy.
You sure that there's no "adb mount" ? Look here, http://forum.xda-developers.com/showthread.php?t=517874. They refer to "adb shell mount".
Personally, I would just create an /etc/fstab file (I believe it can be empty) and see what happens.
Click to expand...
Click to collapse
well ive got an /ect/fstab file that i took from here http://www.android-devs.com/?p=152
Code:
# /etc/fstab: static file system information
#
# file system mount point type options dump pass
/dev/block/mmcblk0p2 / ext2 defaults 1 1
proc /proc proc defaults 0 0
/dev/mmcblk0p1 /media/sdcard vfat defaults 0 0
But thats from a guide about debian on the N1 and the way they are doing it is much different from the method I'm using.
adb shell mount give the error that mount isnt found. it has to be called through busybox-at least in the instance that im using it in
Code:
busybox mount -o --bind /dev/pts /data/local/ubuntu/dev/pts

CLI Play

One thing that I really love about Android, is the Gnu/Linux system running in the background. I use Linux on all my regular machines where I do most work via my beloved terminal.
Playing in CLI on Android Phones is just as much fun only Android is missing a lot of the toys I'm used to. So I'm making a collection of some of these tools, some found on the Web and some Home made.
Here if the first collection of the things I've collected so far.
Most of it can be found in different places on the Web, but I find it a lot easier to just get it in one place.
http://dl.dropbox.com/u/14234754/XDA_GLOBAL/android_cli_extras.tar.gz
This small Archive contains the fallowing:
Bash 4.1 - This shell is made to become the default shell on your phone regardless if you connect via SSH or local terminal. Also added an bashrc file.
SSH Shell Client
Remount script - Makes it easier to optain RW on /system (HTC Users will need S-Off)
Nano Editor with terminfo not defined, fix
Init Script to set a user defined hostname and update the hosts file
Now, I don't remember where everything comes from. I believe that the Nano Editor is from the MoDaCo Forum (The terminfo fix is placed in the /system/bin/sh script). The Remount Script is from somewhere on this forum. Bash, I don't remember. SSH Client is from the Better Terminal APK (Perhaps an SFTP client would be nice to). The rest is just some small home made shell scripts.
The Hostname can be changed in /system/etc/init.d/05userinit (Make sure that your current ROM does not already has init scripts to alter hostname. Some custom ROMs do)
The bashrc file is placed in /system/etc/bashrc
This location can be changed in /system/bin/sh
The remount script makes it faster and easier to option RW on /system.
Just type "remount rw" in the shell to switch to Read/Write and then "remount ro" to switch back to Read-only. HTC Users needs S-Off in order to write to /system.
In order to copy the files to the /system partition, you need to option Read/Write without the remount script. In the Shell type "mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system". (HTC Users without S-Off will need to do this using ADB in recovery)
If you use the Better Terminal APK for Android, you need to go to settings and make sure that it uses Android Terminal. Otherwise it will use it's own bash which only works when in Better Terminal and also it's full of errors. Also in the option "Command Line" it should be "/system/bin/sh". Make sure that there is NO - at the end, example "/system/bin/sh - ". You might need to remove it twice before it is gone.
(Just in case anyone should wonder. Yes your phone needs to be rooted)
Also if anyone has more fun CLI stuff for android then please bring it

Optware for Android

I was looking for a command line ssh program for Android, and was surprised that I couldn't find anything. I didn't want to install a chroot environment, but then I found Optware for Android. I've used it before on other devices and it's VERY useful for getting a more complete unix environment on otherwise stripped down linux devices.
The version on that page was built for a rooted Nook Color, but I only had to make minor changes to get it to run on an Epic running SRF:
1. Extract miniunz from Barnes and Noble's Nook Color 1.2 update zip and put it somewhere in the path - I put mine at /system/bin. You can get it from the first link here http://www.google.com/search?q=nook+color+1.2+update.
2. Make sure /system has at least 2MB or so free. Mine was full... I deleted a few ringtones from /system/media/audio/ringtones/
3. run this:
mount -o remount,rw /
ln -s /data/tmp /tmp
4. Follow the instructions from the Optware for Android page
Optware will now be installed, but pretty much nothing will run at the moment. I'm VERY new to Android, so I don't know that this is the right way to fix it, but here's what I did to get it working:
1. mount -o remount,rw /system
create /system/xbin/optlinks.sh with these contents:
#!/bin/sh
if [ ! -L /tmp ]; then
mount -o remount,rw /
ln -s /data/opt/lib/ld-linux.so.3 /lib/ld-linux.so.3
ln -s /data/opt /opt
ln -s /data/tmp /tmp
mount -o remount,ro /
fi
create /system/xbin/shell.sh with these contents:
#!/bin/sh
/system/bin/su -c /system/xbin/optlinks.sh
/system/bin/su -c "/opt/bin/bash --login"
2. chmod 755 shell.sh and optlinks.sh
3. Edit /etc/profile and add :/opt/sbin:/opt/bin to the PATH export and :/opt/lib to the LD_LIBRARY_PATH export.
4. Install Jack Palevich's Terminal Emulator from the Market
5. In Terminal Emulator's Prefs, set Initial Command to shell.sh.
I had to put the optlinks.sh part in because that's what optware expects - the Nook has those locations, SRF doesn't. Symlinks seem to work fine, but they disappear on reboot - no idea why - so that's why I run it every time.
Now, when I launch Terminal Emulator, I get a root shell, and can use ipkg install to get anything optware provides. It would be really cool if I the shell was run as a normal (non-root) user, and even better if the optware installer didn't need all the workarounds. Anybody have any ideas?
Tried this on CM 7
First off, thanks!
I tried this on CM 7 nightly (nexus one) and here is what I found:
- Most importantly, it broke root access to other apps on the phone. Not sure if this is due to not being able to update init.rc, may try to sort this out later.
- The goal of the install is to be able to run an SSH server and in addition to that you will have access to optware.
- The default busybox that is included with CM7 does not include adduser, addgroup or passwd applets which will cause things to fail once the install script tries to add a new user. Also, there is an app called "busybox installer" on the market that *will* update busybox, however it depends on libraries that CM7 does not include by default. The result is none of the busybox applets can reach the internet due to not being able to resolve domain names.
If you open the optware-bootstrap-0.0.1.shar file with 7zip, you will see there is a busybox executable included. It's an older version, however it includes what you need. I copied that version to /system/xbin and I was able to use the aforementioned applets
- At the end of my install I received an error that it was unable to edit the ram disk while trying to update init.rc. I think the solution is to add a script to /system/etc/init.d/ . Still working that out.
- I'm probably going to try combining this method with this one: http://android.modaco.com/topic/312...cripts-installing-bash-dropbear-mc-nano-opkg/ Since this is more of a manual method, however it's connecting to a custom optware feed that only has a few packages.
I dont suppose you got anywhere with this?
Looking to install optware on my desire hd running miui rom.

Ubuntu 11.04 unity-2d VNC

Hi guys,
I'm really new here, I can't post in this thread: http://forum.xda-developers.com/showthread.php?t=836022
I created a working ubuntu11.04 .img, with unity-2d. I don't know if anybody cares, it was funny to make.
It is just a minimal install with unity-2d and tightvncserver. Really minimal. Firefox, office applications, anything else DOES NOT installed.
However, you can install anything using apt-get install.
I installed wget and nano, because it was needed to configure the vnc. I plan to make a bigger one with all the programs and stuff installed. Maybe tomorrow. Or next week.
How to use: Unzip, rename to ubuntu.img and simply replace the original ubuntu.img with this one. Use root as user/nickname and ubuntu as password, as usual.
Download link to .img:
Download link to the other files needed:
Links tomorrow. "New" .img too.
If you are a mod and you're reading this, please move this post it the thread I linked in the beginning, or anywhere where this post is in its place.
-Sorry for my english.
Please help! Give me additional space by using my referral: http://db.tt/W0knUea
edit1: So, now I've got 10 comments, I don't have to write everything in separate comments. What I've done yet: make some simple script to automatically turn on/off the vncserver (1024x600, tab native res, I found it enough), and get tired of the resource hungriness of unity-2d. I mean it needs about the same CPU power (I guess) as the galaxy tab has, and it needs about 200MB RAM. But this is to run native. The VNC version is far from native, so it's slow as f..., I mean, very slow. Then I looked for a little less resource-hungry desktop environment, and I found lxde. I made an image with that. It's slow too, but much faster than unity-2d. I need to configure it a little more, to be more touch-friendly. And I want to do a few other thing, and write a how to make your own .img file thing. If you want to do it now, here some links, I will write about it sometimes.
http://androlinux.com/android-ubuntu-development/how-to-install-ubuntu-on-android/
https://wiki.ubuntu.com/ARM/RootfsFromScratch
http://tldp.org/HOWTO/Bash-Prog-Intro-HOWTO.html
http://galaxytabhacks.com/galaxy-ta...tall-ubuntu-linux-on-galaxy-tab-10-1-tabuntu/
http://androlinux.com/android-ubuntu-development/how-to-build-chroot-arm-ubuntu-images-for-android/
I also suggest reading mount, umount and rootstock man pages.
This image works quite well. As with every VNC build, its a bit slow and Unity doesn't help that (even in its nice Unity-2d form), but if you want Ubuntu on your Tab this is a pretty sweet image. Ultra-lightweight, too. Nice work, OP!
Firstly, thankyou for not making 10 spam posts just to get this posted in the Development section, shouldnt take you long to get 10 posts under your belt in this thread then I'll move it into the dev section for you
Good job by the way..
how to run this?
http://forum.xda-developers.com/showthread.php?t=836022
It's writen down here.
The link to the files is in the first post.
Do I write 'bootubuntu' in command line instead of 'bootlinux' or do I have to change the filename of 'bootubuntu' file? I guess first of the two is correct, but it's better to ask than to brick
Oh and is the AndroidSDK really needed? I don't see anything about usage of it in instruction....
maslak666 said:
Do I write 'bootubuntu' in command line instead of 'bootlinux' or do I have to change the filename of 'bootubuntu' file? I guess first of the two is correct, but it's better to ask than to brick
Oh and is the AndroidSDK really needed? I don't see anything about usage of it in instruction....
Click to expand...
Click to collapse
Hi!
The SDK is not strictly necessary since you could use a Terminal Emulator to run the necessary commands but using an ADB shell is just bit easier sometimes. That being said, you should install the SDK if you ever want to do much with an Android. It's easy to install and very powerful.
And yes, write bootubuntu instead of bootlinux when prompted. I know what you mean
Allright, I went through it and now got it installed . But I can't see firefox nor any office application... How to access them? Also can't get into terminal to write 'apt-install' there.....
maslak666 said:
But I can't see firefox nor any office application... How to access them?
Click to expand...
Click to collapse
sisa7 said:
Really minimal. Firefox, office applications, anything else DOES NOT installed.
However, you can install anything using apt-get install.
Click to expand...
Click to collapse
I'll write a howto tonight or next day or I don't know. I need to study to university too. You need adb or android terminal emulator (from the market) to use apt. Short version: when your prompt is "[email protected]:/#" simply do this command: "apt-get install firefox"
Just poked around a little. Now I know (or at least I think I now) what else I have to do.
http://dl.dropbox.com/u/41806444/bootubuntu2
Cleaned up version of bootubuntu. Copy it to /sdcard/ubuntu and simply run it. You need to use the sh command, so type "sh bootubuntu2" in android terminal emulator or adb shell in /sdcard/ubuntu foler.
Oh, sorry I forgot to mention, this script only works with overcome kernel and rom. You shold modify the
mount -o remount,rw -t ext4 /dev/block/stl9 /system
and the
mount -o remount,ro -t ext4 /dev/block/stl9 /system
rows. Enter "mount" to android terminal to see your /system dir type and path.
Synaptic looks like to work, software-center doesn't even start.
To really enjoy full linux distros like this, one should have a swap-enabled kernel. Instead, kernel on the Tab has no swap, and if you dare open some large app, the lack of ram makes it slow and unresponsive.
This is the main problem imho.
Ernesto de Bernardis
N900 - Galaxy Tab 7"
sisa7 said:
Oh, sorry I forgot to mention, this script only works with overcome kernel and rom. You shold modify the
mount -o remount,rw -t ext4 /dev/block/stl9 /system
and the
mount -o remount,ro -t ext4 /dev/block/stl9 /system
rows. Enter "mount" to android terminal to see your /system dir type and path.
Click to expand...
Click to collapse
Or keep it simple silly
mount -o remount,rw /dev/block/stl9 /system
mount -o remount,ro /dev/block/stl9 /system
cdesai said:
Or keep it simple silly
mount -o remount,rw /dev/block/stl9 /system
mount -o remount,ro /dev/block/stl9 /system
Click to expand...
Click to collapse
The /dev/block/stl9 part is changing too.
debernardis said:
one should have a swap-enabled kernel. Instead, kernel on the Tab has no swap
Click to expand...
Click to collapse
Thanks. I didn't know this is the problem. I will try out http://forum.xda-developers.com/showthread.php?t=483110 this and see what happens.
@sisa7 do you have any update?
debernardis said:
@sisa7 do you have any update?
Click to expand...
Click to collapse
Yep.
This email is an automated notification from Dropbox that your Public links have been temporarily suspended for generating excessive traffic. Your Dropbox will continue to function normally with the exception of Public links.
This suspension is temporary (3 days for the first time).
Sorry guys. Anybody know a decent upload site?
Also, I'm working on LXDE desktop. But the university makes me busy, so I haven't got too much time. Sorry.
Minus.com
Box.net
Multiupload.com
Is this still alive?
I tried installing the one in the other [MOD] Forum but when I try to install apps to Ubuntu I get a conection "404" error
Do you guys think this image will work?

Getting rid of FAT, UMS, vold

FAT (the old DOS-based file system) is a bad idea.
It's ugly, doesn't mix well with Linux and saves timestamps in local time.
Moreover, the Nook has problems with FAT, randomly changing timestamps a number of hours.
Certainly at daylight savings time transitions everything changes.
If you use timestamps as an indication for syncing files from a host, this is a problem.
UMS (USB Mass Storage) is a bad idea.
It takes a happily mounted volume from an OS, and hands it in a raw block view to a remote system.
Outside of using noogie for full physical backups or initial partitioning and formatting there is no need for UMS.
The last need of UMS was the Adobe Digital Editions which was discussed and obviated in this thread
Finally, there are some devices and occasions where you'd want to hot swap SD cards.
A camera taking megapixels shots might have a need for swapping SD cards.
Our Nooks use SD cards more as permanent expansion units.
Get a 32 GB card, stick it in and never take it out.
Then we wouldn't need vold (the volume daemon).
In another thread I posted a modified vold so that the SD card could be ext3 formatted.
To my mind, the cleanest solution to all this is to:
Format the SD card with ext3
Mount the SD card in init.rc inside the uRamdisk
Disable UMS
Disable vold
Right now I'm running into problems mounting the SD card inside init.rc
Code:
mount ext3 /dev/block/mmcblk1p1 /sdcard wait nosuid nodev noatime nodiratime
chown system sdcard_rw /sdcard
chmod 0777 /sdcard
init has not very useful error reporting, it returns an error of -1 for any condition.
I was trying to build init that could tell me something more.
This is a work in progress.
(If we get rid of vold, we'll have to strip the Android MountWatcher so that it doesn't flail.)
I found out what the problem with doing a normal mount in init.rc was.
The system had not found /dev/block/mmcblk1p1 yet.
I'm still working on this.
For now I have a oneshot service that mounts /sdcard.
It uses a little executable that waits until /dev/block/mmcblk1p1 appears.
I disabled vold.
I would have liked to be able to mount the SD card inside init.rc,
but apparently /dev/block/mmcblk1p1 has not appeared by then.
You need to have a service do the job, a few seconds later.
Yes, you could probably write a little script, but I'd rather write a little Linux program.
I'm still wondering if there is an easier solution to mount inside init.rc
People use their Nooks in such different way.
I would really like to know what exactly people are interested in this thread.
There is a poll at the top to fill in, please.
Pieces of the pie ready to go now:
mke2fs
tune2fs -j
Mods to init.rc - disable vold, enable mntsdcard
mntsdcard - a Linux program
Patches to MountService to disable it.
Is anybody interested in trying this?
Well, if you want to give it a go, here's how.
Black = commands to the Nook shell over ADB
Blue = commands to the Windows shell
Convert your SD card to ext 3
Backup the data on your SD card (or just let it all get deleted).
You can use adbsync.exe if you like:
Code:
[color=blue]mkdir sdcard[/color]
[color=blue]adbsync /hscu /s C:\sdcard sdcard[/color]
Then you can re-partition the SD card.
Code:
umount /sdcard
busybox fdisk -H 255 -S 63 /dev/block/mmcblk1
Do the commands to delete (D) old partitions, create a new (N) primary partition.
Then write (W).
Then format the SD card in ext2, upgrade to ext3 and check the mount.
Code:
mke2fs /dev/block/mmcblk1p1
tune2fs -j /dev/block/mmcblk1p1
mount -t ext3 /dev/block/mmcblk1p1 /sdcard
Install mntsdcard
Copy over mntsdcard:
Code:
mount -o rw,remount /dev/block/mmcblk0p5 /system
[color=blue]adb push mntsdcard /system/bin[/color]
chmod 755 /system/bin/mntsdcard
Get uRamdisk and extract init.rc:
Code:
mount -o rw,remount rootfs /
mkdir /boot
mount -t vfat /dev/block/mmcblk0p1 /boot
[color=blue]adb pull /boot/uRamdisk[/color]
[color=blue]bootutil /x /v uRamdisk init.rc[/color]
Add in a mount for media (we'll leave it FAT for now):
Code:
mount ext2 /dev/block/mmcblk0p5 /system
mount ext2 /dev/block/mmcblk0p5 /system ro remount
[b] mount vfat /dev/block/mmcblk0p6 /media sync noatime nodiratime uid=1000,gid=1000[/b]
Comment the old vold stuff out:
Code:
#service vold /system/bin/vold
# socket vold stream 0660 root mount
Add in the mntsdcard stuff at the end of init.rc:
Code:
service mntsdcard /system/bin/mntsdcard
oneshot
Replace init.rc and push the uRamdisk back:
Code:
[color=blue]bootutil /r /v uRamdisk init.rc
adb push uRamdisk /boot[/color]
reboot
If there are any problems, look in /data/mntsdcard.log
Restore your SD card
Code:
[color=blue]adbsync /ascu /s C:\sdcard sdcard[/color]
Wow, this seems like a lot of stuff to do! :cyclops:
Thanks so much for all this great dev work, Renate!
:good:
BUT!
Will this definitely make noogie not function correctly? (I make new backups with it, like, once every week and a half, so that would definitely stop me from trying this)?
What will this do to the regular USB mounting onto a PC?
What will this do to mounting USB devices on the Nook using host mode?
And, finally: Will this mean I can't ever remove my SD card to use for something else temporarily (or to write a Nook-bootable image to it for miscellaneous reasons)?
Thanks,
3N
It's ugly, doesn't mix well with Linux and saves timestamps in local time.
Click to expand...
Click to collapse
That isn't correct. Linux has had support for FAT file systems very early on
and Linux support is quite stable. Saving timestamps in local time should not be a problem.
These mods look like it would make it non-trivial to side load content (unless you are using Linux for a main PC) for no reason.
smeezekitty said:
...These mods look like it would make it non-trivial to side load content (unless you are using Linux for a main PC) for no reason.
Click to expand...
Click to collapse
Hmmm. Good point. Thanks for pointing this out, as I use a Windows 7.
Here's your first post thank!
smeezekitty said:
TSaving timestamps in local time should not be a problem.
Click to expand...
Click to collapse
It's a problem twice a year when daylight savings time makes all your file times shift one hour.
Also, try moving timezones on your device.
smeezekitty said:
These mods look like it would make it non-trivial to side load content (unless you are using Linux for a main PC) for no reason.
Click to expand...
Click to collapse
Mmm, not really. I have a Windows desktop and I use ADB push/pull and my adbsync utility.
Moreover, I can easily sync all my Android devices before going out the door.
Renate NST said:
...Mmm, not really. I have a Windows desktop and I use ADB push/pull and my adbsync utility.
Moreover, I can easily sync all my Android devices before going out the door.
Click to expand...
Click to collapse
But if we wanted to transfer files without WiFi, ADB wouldn't be available, and so how would we sideload our files w/out ADB?
I agree ADB file transfer is more fun - heck, you can use an FTP Server app and manage your whole filesystem in the comfort of Windows Explorer! But without WiFi...
thenookieforlife3 said:
But if we wanted to transfer files without WiFi, ADB wouldn't be available, and so how would we sideload our files w/out ADB?
I agree ADB file transfer is more fun - heck, you can use an FTP Server app and manage your whole filesystem in the comfort of Windows Explorer! But without WiFi...
Click to expand...
Click to collapse
It is a little harder to set up, but adb usb has been available in the Nook since it was first rooted. This is just one of the multiple threads here that gives instructions....
Getting USB-enabled ADB working
thenookieforlife3 said:
But if we wanted to transfer files without WiFi, ADB wouldn't be available, and so how would we sideload our files w/out ADB?
I agree ADB file transfer is more fun - heck, you can use an FTP Server app and manage your whole filesystem in the comfort of Windows Explorer! But without WiFi...
Click to expand...
Click to collapse
ADB is something a little advanced for me at this point. But regardless of if you want to use it or not,
It is still very handy to be able to just copy files on and off the device just by moving the SD card or mounting by USB
I suggest that the OP adds a note for less experienced users so they know that you lose those capabilities if you do these mods.
smeezekitty said:
ADB is something a little advanced for me at this point. But regardless of if you want to use it or not,
It is still very handy to be able to just copy files on and off the device just by moving the SD card or mounting by USB
I suggest that the OP adds a note for less experienced users so they know that you lose those capabilities if you do these mods.
Click to expand...
Click to collapse
I entirely agree. Although ADB is fantastic and I absolutely love it, it's good to still have the USB mounting option instead.
The post you replied to was actually pointed toward Renate, so yeah.
---------- Post added at 02:50 PM ---------- Previous post was at 02:48 PM ----------
David0226 said:
It is a little harder to set up, but adb usb has been available in the Nook since it was first rooted. This is just one of the multiple threads here that gives instructions....
Getting USB-enabled ADB working
Click to expand...
Click to collapse
Thanks for the link - this topic has given me grief for the whole month, as I just can't seem to get the danged thing working! :laugh:
thenookieforlife3 said:
Thanks for the link - this topic has given me grief for the whole month, as I just can't seem to get the danged thing working! :laugh:
Click to expand...
Click to collapse
Good luck. My experience is that much depends on the model you have and the rooting method used. I have an original NST on which ADB over USB works without an issue. I also have a NST with Glowlight (rooted with NookManager) that I can't seem to get it working on. (I can't remember how I rooted the NST, it was a couple of years ago.)
David0226 said:
Good luck. My experience is that much depends on the model you have and the rooting method used. I have an original NST on which ADB over USB works without an issue. I also have a NST with Glowlight (rooted with NookManager) that I can't seem to get it working on. (I can't remember how I rooted the NST, it was a couple of years ago.)
Click to expand...
Click to collapse
AH! Good to know! I thought that I was just being a dumbo not being able to get ADB USB working (I have an NSTG rooted w/NookManager), but now that I hear that you're having problems, too, maybe I won't worry so much!
Getting ADB to work should be easy, especially if you have a few devices and can see if the problem is with the device or the host.
On Windows getting ADB over USBcan be a pain. There are a few roadblocks:
Make sure that your device is using USB and not WiFi for ADB. The option is set in init.rc in uRamdisk. Use bootutil.exe to check/edit.
Getting the WinUSB driver loaded. Use the driver package from here: http://forum.xda-developers.com/showthread.php?p=49665945#post49665945
Getting ADB to recognize B&N devices. The newer adb.exe has the VID for B&N built in. The older adb.exe required fiddling with adb_usb.ini
Renate NST said:
Getting ADB to work should be easy, especially if you have a few devices and can see if the problem is with the device or the host.
On Windows getting ADB over USBcan be a pain. There are a few roadblocks:
Make sure that your device is using USB and not WiFi for ADB. The option is set in init.rc in uRamdisk. Use bootutil.exe to check/edit.
Getting the WinUSB driver loaded. Use the driver package from here: http://forum.xda-developers.com/showthread.php?p=49665945#post49665945
Getting ADB to recognize B&N devices. The newer adb.exe has the VID for B&N built in. The older adb.exe required fiddling with adb_usb.ini
Click to expand...
Click to collapse
Yep, already seen these in previous posts. Modifying uRamdisk doesn't seem to work, as I can still use wireless ADB with or without the mentioned changes. Already edited adb_usb.ini to include B&N. And, I think, already got the WinUSB driver. I'll check that, though.
As stated many times, if you can connect to ADB over WiFi then you can not connect to ADB over USB.
Renate NST said:
As stated many times, if you can connect to ADB over WiFi then you can not connect to ADB over USB.
Click to expand...
Click to collapse
Yes, I know that, too. The problem, as stated, is that I always can connect over WiFi, and never USB!
No matter what mods I apply to any system file, it's the same result!
thenookieforlife3 said:
No matter what mods I apply to any system file, it's the same result!
Click to expand...
Click to collapse
Are you modifying init.rc inside uRamdisk? (Not the one that appears in the root after you have booted.)
What about default.prop in uRamdisk?
Do you see a 5555 anywhere?
Are you using some amazing-super-duper-ADB-instant-turn-on-offer-application?
Well, don't.
Renate NST said:
Are you modifying init.rc inside uRamdisk? (Not the one that appears in the root after you have booted.)
What about default.prop in uRamdisk?
Do you see a 5555 anywhere?
Are you using some amazing-super-duper-ADB-instant-turn-on-offer-application?
Well, don't.
Click to expand...
Click to collapse
Answer 1: Yes, I most definitely am. In fact, I am using your bootutil.exe program to do it.
Answer 2: Yes, I also edited that to match what you wrote in the Minimal rooting - back to basics thread.
Answer 3: Yes, in the line of code
Code:
setprop service.adb.tcp.port 5555
It doesn't matter if I comment it out, it still connects wirelessly.
Answer 4: Yes, I am. But if I don't use one, then how will I turn ADB on or off?

Categories

Resources