Replacing Toolbox with Busybox - Nexus S General

Hi,
I've just replaced the stock toolbox with busybox provided by netarchy kernel package. Maybe there is a better way to do this, but I'm just playing with my new phone
Anyway, this is what I did:
Info
nexus model: I9023
rom: stock 2.3.4 with root permission
kernel: 2.6.35.13-netarchy-nexus-1.3.7-bfs-2.3.4
busybox version: 1.16.0 (included in netarchy kernel package)
Entering adb shell
Code:
adb shell
Inside adb shell:
Replacing toolbox with busybox
Code:
mount -o rw,remount /dev/block/mmcblk0p1 /system
busybox mv /system/bin/toolbox /system/bin/toolbox.bak
busybox ln -s /system/xbin/busybox /system/bin/toolbox
mount -o ro,remount /dev/block/mmcblk0p1 /system
Add a new command
After remounting rw /system
Code:
ln -s /system/xbin/busybox /system/xbin/COMMAND
For example:
Code:
mount -o rw,remount /dev/block/mmcblk0p1 /system
ln -s /system/xbin/busybox /system/xbin/chroot
mount -o ro,remount /dev/block/mmcblk0p1 /system
If you know a better way, tell me! Anyway I hope this could be useful

Download "busybox" by Stericson
Install busybox thru that app
Uninstall "busybox" by Stericson (busybox will stay intact)

snandlal said:
Download "busybox" by Stericson
Install busybox thru that app
Uninstall "busybox" by Stericson (busybox will stay intact)
Click to expand...
Click to collapse
Or just download BusyBox from Titanium Backup.

Code:
# busybox --install /system/xbin
should do the trick -- be warned, you'll get *a whole lot* of symlinks to busybox

snandlal said:
Download "busybox" by Stericson
Install busybox thru that app
Uninstall "busybox" by Stericson (busybox will stay intact)
Click to expand...
Click to collapse
Great, thanks. I've installed that busybox and it works great!

suksit said:
Code:
# busybox --install /system/xbin
should do the trick -- be warned, you'll get *a whole lot* of symlinks to busybox
Click to expand...
Click to collapse
Yes, I installed busybox in /system/xbin and it created a lot of symlinks, but it's ok because in this dir there is almost nothing.
Anyway, thanks for the tip

???
Weird! After running shell script, I can no longer stay connected on wireless for more than a couple of minutes. I think something was replaced and it shouldn't be replaced!
Any hint?

In most Android systems, the c binary stalk is installed in /system/bin and is handled by TOOLBOX.
If we install BUSYBOX with any of the apps mentioned above, it will most likely be installed in /system/xbin
So at the end we'll end up with 2 utilities handling some binaries that are clones as it show in both /system/bin and /system/xbin
and because the PATH includes both locations then wouldn't that create some complications and possible hanging/crashing of the android system ???

Related

Trying to set rot permissions, install busybox AND install Superuser.apk.32B

Right im using the google ion ota update from the htc website
.
Im trying to root it (Done) add busybox (followed instructions to the t and no joy) and install superuser.apk
busybox
mkdir /data/busybox
cat /sdcard/busybox > /data/busybox/busybox
chmod 4755 /data/busybox/busybox
cd /data/busybox
./busybox --install
export PATH=/data/busybox:$PATH
Also tried all that but with /system/xbin instaed of /data
Im testing using louder volume hack.It isnt working, i have root i guess its this?
Superuser
after doing
cat sh>su
etc..etc..
and installing superuser i cant get it to work?doesnt pop up saying always allow etc?Any help would be frigging awesome thanks

[Q] Root 2.2 318 without ADBshell

Hi,
a pin of my USB connector is broken so I cannot get a USB data connection to a PC (but charging still works ...).
How can I root the official 318 build of froyo ? More specifically, in the new build, there doesn't seem to be any mounted filesystem on which one can copy RATC to run it.
Any hint welcome.
Have you already tried superoneclick, androot, or z4root? If so, then maybe try the below.
I don't know if this will work but you can try fard's instructions to root manually and use "Terminal Emulator" from Market instead of ADB SHELL, but i don't know what will happen when you run rageinthecage~ You will need to change the instruction a bit for your case.
http://forum.xda-developers.com/showthread.php?t=844966&highlight=rageagainstthecage
Instructions:
1. Copy all the needed files (from fards thread) into the SDCARD.
2. run Terminal Emulator
3. cd /sdcard/
4. busybox cp rageagainstthecage-arm5.bin /data/local/tmp/rageagainstthecage
5. busybox cp Superuser.apk /data/local/tmp/Superuser.apk
6. busybox cp su /data/local/tmp/su
7. busybox cp busybox /data/local/tmp/busybox
8. chmod 700 /data/local/tmp/rageagainstthecage
9. chmod 700 /data/local/tmp/busybox
10. cd /data/local/tmp
11. ./rageagainstthecage
12. Reset Terminal
13. Start Terminal Emulator again
14. mount -o remount,rw -t yaffs2 /dev/block/mtdblock6 /system
15. follow the rest of the instructions below "mount -o remount,rw -t yaffs2 /dev/block/mtdblock6 /system "
In case you can't find it in the thread, here is the original post by fards:
GET ECLAIR/FROYO version of Superuser.apk and su
from http://forum.xda-developers.com/showthread.php?t=682828 extract the two files to the directory you're working from..
GET rageagainstthecage from
http://stealth.openwall.net/xSports/RageAgainstTheCage.tgz
extract the rageagainstthecage-arm5.bin to the same directory you're working from
open a terminal/command line
adb push rageagainstthecage-arm5.bin /data/local/tmp/rageagainstthecage
adb push Superuser.apk /data/local/tmp/Superuser.apk
adb push su /data/local/tmp/su
adb push busybox /data/local/tmp/busybox
adb shell chmod 700 /data/local/tmp/rageagainstthecage
adb shell chmod 700 /data/local/tmp/busybox
adb shell
cd /data/local/tmp
./rageagainstthecage
******this will kill adb server but manually kill it anyway and restart it ******
adb kill-server
adb start-server
* daemon not running. starting it now *
* daemon started successfully *
adb shell
mount -o remount,rw -t yaffs2 /dev/block/mtdblock6 /system
**********Follow the following steps to install Superuser.apk, busybox,su ****************
cd /data/local/tmp
./busybox cp busybox /system/bin/
chmod 4755 /system/bin/busybox
busybox cp Superuser.apk /system/app/
busybox cp su /system/bin/
chmod 4755 /system/bin/su
exit
exit
then reboot streak
************to remount filesystem as readonly,*************
adb shell
# su
su
#mount -o remount,ro -t yaffs2 /dev/block/mtdblock6 /system
# exit
exit
Click to expand...
Click to collapse
Well...
yes, I have tried all that.
The main problem with the last option (i.e. CLI) is that the directory /data/local/tmp/ is not user writable (actually /data permissions are 751). So I was in search of a another directory (in an executable partition) where I can copy rageagainstthecage-arm5.bin.
Finally found it : "find" was my friend. /firstboot/sqlite/jackpal.androidterm/ is owned by my user (ID 10123)! It's the only one I found in all the filesystems!
Note that "find" is available through /system/bin/busybox_1P8P1. Btw /firstboot/sqlite/jackpal.androidterm/ seems to be linked to the terminal process.
Ran rageagainstthecage-arm5.bin various times to no avail ! It didn't give me root!

How change permissions dir APP by ADB shell?

Hi i have problem with Kindle Fire,
i changed permissions folder system/app with app Root explorer and then I restart Kindle Fire and now dont want start. I think this is problem permissons for this directory.
Pleas can you send me setting permissions folder APP and how i can change it by ADB SHELL?
I have tried:
adb shell
su
chmod 644 app
Unable to chmod app: Read-only file system
THX very much .-(
Sory my english is very bad.
adb shell
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
chmod 755 /system/app
or look here:
http://forum.xda-developers.com/showthread.php?t=1356257
guys please use the search function !
I have tried it but:
$ mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
mount: Operation not permitted
$ chmod 755 /system/app
chmod 755 /system/app
Unable to chmod /system/app: Read-only file system
THX I'm a little desperate
pitrsonek said:
I have tried it but:
$ mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
mount: Operation not permitted
$ chmod 755 /system/app
chmod 755 /system/app
Unable to chmod /system/app: Read-only file system
THX I'm a little desperate
Click to expand...
Click to collapse
you need root before you can do any of those (i.e. su)
But i think i have root because I install Google market and other app. Or how i can check if i have root?
THX!
c:\Program Files (x86)\Android\android-sdk\platform-tools>adb devices
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
List of devices attached
4D1A002600000001 device
c:\Program Files (x86)\Android\android-sdk\platform-tools>adb shell
$ ls
ls
config
dropbox
cache
sdcard
acct
mnt
vendor
d
etc
ueventd.rc
ueventd.omap4430.rc
ueventd.goldfish.rc
system
sys
sbin
proc
init.rc
init.omap4430.rc
init.goldfish.rc
init
default.prop
data
root
dev
$
at the $ prompt type
su
should turn to # instead of $
Then you are Root.
krelvinaz said:
at the $ prompt type
su
should turn to # instead of $
Then you are Root.
Click to expand...
Click to collapse
Yes, what he said...you're confusing having root on the command line for "I installed su and superuser to their correct locations"
adb shell
$ su
su
[1] + Stopped (signal) su
$ su
su
[2] + Stopped (signal) su
[1] Segmentation fault su
$
I have try install root by this manual: http://rootkindlefire.com/kindle-fire-root/how-to-root-kindle-fire/
I see device when i write: adb devices
I have executed runme.bat
but SU dont go
pitrsonek said:
adb shell
$ su
su
[1] + Stopped (signal) su
$ su
su
[2] + Stopped (signal) su
[1] Segmentation fault su
$
I have try install root by this manual: http://rootkindlefire.com/kindle-fire-root/how-to-root-kindle-fire/
I see device when i write: adb devices
I have executed runme.bat
but SU dont go
Click to expand...
Click to collapse
Something is wrong with your device then.
as a first step look if you have superuser.apk in \system\app\
Ho i dont have Superuser.apk in /system/app/
b63 said:
as a first step look if you have superuser.apk in \system\app\
Click to expand...
Click to collapse
Doesn't really matter if su is not working. Superuser.apk is just a wrapper for su and he's trying to do things on the command line so su is what he's calling to, not SuperUser.apk.
He either didnt root correctly to begin with or he did something after that messed things up. Temp rooting with zergRush and redoing things is most likely what he needs to do.
Is ther somebody who can help me online on gtalk? I will pay you by PayPal. If anybody has freetime send me PM. THX
Ther is content dir app:
c:\Program Files (x86)\Android\android-sdk\platform-tools>adb shell
$ ls /system/app
ls /system/app
-------------------------------------------------------------------------
ATVAndroidClient.apk
AccountAndSyncSettings.apk
AmazonVenezia.apk
ApplicationsProvider.apk
AudibleAndroidApplication-venezia.apk
CSApp-unsigned.apk
CalendarProvider.apk
CertInstaller.apk
Cloud9-unsigned.apk
Cloud9SystemBrowserProvider-unsigned.apk
Contacts.apk
ContactsProvider.apk
DefaultContainerService.apk
DownloadProvider.apk
DownloadProviderUi.apk
DrmProvider.apk
Email.apk
Facebook.apk
Gallery3D.apk
HTMLViewer.apk
IMDb-2.3.apk
KindleForOtter.apk
LatinIME.apk
Launcher.apk
LiveWallpapers.apk
LiveWallpapersPicker.apk
MagicSmokeWallpapers.apk
MarketIntentProxy.apk
MediaProvider.apk
MyAccount-unsigned.apk
OOBE-unsigned.apk
OTASilentInstall.apk
OtterAppManager.apk
OtterTutorial.apk
PackageInstaller.apk
PicoTts.apk
Provision.apk
Pulse-amazon.apk
QuickSearchBox.apk
QuickSettings.apk
Quickoffice_AMAZON_4.1.408_VC.apk
Settings.apk
SettingsProvider.apk
SystemUI.apk
TtsService.apk
UserDictionaryProvider.apk
VisualizationWallpapers.apk
VpnServices.apk
Windowshop.apk
air_runtime.apk
amazonmp3-unsigned.apk
com.amazon.dcp.apk
oem_install_flash_player_signed.apk
Superuser.apk
Vending.apk
$
agree - but it's an indication that his device is not rooted
i would suggest to install superoneclick to the computer and root again
all you need is here : http://forum.xda-developers.com/showpost.php?p=19789892&postcount=35
pitrsonek said:
Is ther somebody who can help me online on gtalk? I will pay you by PayPal. If anybody has freetime send me PM. THX
$
Click to expand...
Click to collapse
Maybe on Thursday I can. Busy until then.
I just run SuperOneClick and there is log http://jsfiddle.net/tVnDv/ from this program.
Kindle Fire is Back
Jupiiie Kindle Fire is back.
So first i try SuperOneClikck install root, but this code doesnt go:
adb shell
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
chmod 755 /system/app
Then i tried unroot and this code go?
How my Kindle Fire start ,-) Its crazy but true.
Thank you very much guys...
glad to help ...
pitrsonek said:
Jupiiie Kindle Fire is back.
So first i try SuperOneClikck install root, but this code doesnt go:
adb shell
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
chmod 755 /system/app
Then i tried unroot and this code go?
How my Kindle Fire start ,-) Its crazy but true.
Thank you very much guys...
Click to expand...
Click to collapse
I'm having the same issue, but when I go to change the mount permissions I get permission denied. Anyone care to give me some insight on how to fix it?
you have the $ prompt !!!
type su - the prompt has to change to #
then do the commands ...

SwiFTP - fix for freezing downloads

I was using SwiFTP to upload files, but it seemed to freeze when downloading ...
The reason is that the /system/bin/ls command on S3 returns output which is different from previous Android versions ...
The solution is to replace /system/bin/ls (which points to toolbox) to point to busybox.
Code:
cd /system/bin
mv ls ls.orig
ln -s /system/xbin/busybox ls
Make sure you have busybox installed in /system/xbin and that your /system partition is mounted read/write.
If you don't know what this is doing, please don't attempt to do it

wrongly mounted s4 i9506 = now bricked?

I just rooted my SG S4 Android 5.0.1 with auto-root. Everything worked fine (root complete and SU installed) till I think I gave a bad mount command in the root directory on the phone in terminal (i guess here it went wrong, not sure. Or perhaps during installation of bash or nano) when I was installing bash and nano. Since it rebooted, I **lost the wifi and cannot adb shell into my phone** anymore from mac.
Afterwards, I managed to flash clockwork mod recovery v6.0.4.6. and was able to mount /system, which enabled the ./adb shell again. However i can now only pwd and cd, everything else gets this error: /sbin/sh: ls: Permission denied
I think my phone is still recoverable, however I don't know what to do and don't want to risk making things worse. Which andoird wizard can help me please?
**Below here were my bash nano install commands:**
./adb shell
su
mount -o remount,rw /system
cp -r /storage/extSdCard/bashnano/terminfo /system/etc
cp /storage/extSdCard/bashnano/profile /etc
cp /storage/extSdCard/bashnano/bash /data
cp /storage/extSdCard/bashnano/nano /data
chmod 755 /data/bash
chmod 755 /data/nano
cd /system/bin/
mv sh sh.old
ln -s /data/bash sh
ln -s /data/bash bash
ln -s /data/nano nano
export TERMINFO=/etc/terminfo
export TERM=linux
mount -o remount,ro /system
**P.S. So I also performed a regular mount in root, which i think is what made things bad, but not totally sure!**
ansjovis86 said:
I just rooted my SG S4 Android 5.0.1 with auto-root. Everything worked fine (root complete and SU installed) till I think I gave a bad mount command in the root directory on the phone in terminal (i guess here it went wrong, not sure. Or perhaps during installation of bash or nano) when I was installing bash and nano. Since it rebooted, I **lost the wifi and cannot adb shell into my phone** anymore from mac.
Afterwards, I managed to flash clockwork mod recovery v6.0.4.6. and was able to mount /system, which enabled the ./adb shell again. However i can now only pwd and cd, everything else gets this error: /sbin/sh: ls: Permission denied
I think my phone is still recoverable, however I don't know what to do and don't want to risk making things worse. Which andoird wizard can help me please?
**Below here were my bash nano install commands:**
./adb shell
su
mount -o remount,rw /system
cp -r /storage/extSdCard/bashnano/terminfo /system/etc
cp /storage/extSdCard/bashnano/profile /etc
cp /storage/extSdCard/bashnano/bash /data
cp /storage/extSdCard/bashnano/nano /data
chmod 755 /data/bash
chmod 755 /data/nano
cd /system/bin/
mv sh sh.old
ln -s /data/bash sh
ln -s /data/bash bash
ln -s /data/nano nano
export TERMINFO=/etc/terminfo
export TERM=linux
mount -o remount,ro /system
**P.S. So I also performed a regular mount in root, which i think is what made things bad, but not totally sure!**
Click to expand...
Click to collapse
If you can get into download mode ,flash stock rom from Sammobile

Categories

Resources