I've been messing around with my Dev Magic and found a site for the G1 with some stuff to try:
http://gettinthru.blogspot.com/2009/04/mods-for-tmobile-g1-at-your-own-risk.html
In there, some of the things suggested use the linux command "cp" to copy files from/to the SD card. Problem is, I can't see it listed. Here is the listing of commands in /system/bin:
system_server
mediaserver
app_process
surfaceflinger
dalvikvm
dexopt
rild
wlan_loader
sdutil
service
netcfg
dumpsys
hcid
dd
cmp
df
date
cat
bugreport
chmod
chown
wpa_supplicant
wpa_cli
wipe
watchprops
vmstat
umount
top
vold
sync
stop
start
smd
sleep
setprop
setconsole
sendevent
schedtop
set_grp_id
route
rmmod
rmdir
renice
rm
reboot
radiooptions
ps
qemud
printenv
notify
netstat
mv
mount
mkdosfs
lsmod
mkdir
ls
log
ln
ioctl
kill
installd
iftop
insmod
ifconfig
id
hd
htclogkernel
getevent
getprop
flash_image
dvz
dmesg
dumpcrash
dhcpcd
debug_tool
toolbox
dumpstate
servicemanager
hciattach
logcat
sdptool
dbus-daemon
gzip
showlease
sh
schedtest
ping
logwrapper
iptables
linker
debuggerd
dosfsck
gdbserver
pm
svc
input
am
ime
monkey
akmd
As you can see, no cp. Any suggestions like a .apk of the command to push over to it?
Cheers
you can use dd to copy files aslong as you dont have busybox ( on the dream "all" the rooted images come with busybox )...
However you can use busybox from a non-rooted device by copying it to the folder "sqlite_stmt_journals" as it has both exec/write rights...
Seem to be sorted now...
I found that I can install Busybox like the G1 owners have as standard:
http://www.androidfanatic.com/cms/community-forums.html?func=view&id=228&catid=9
Folowed the guide and have cp and loads of stuff to play with now.
Cheers for your responses.
No problem... Wont take long before custom images are put together that include busybox as the magic now can also be rooted like the dream.
the "rootme" rom i provide in my rooting procedure has busybox installed, as well as apps2sd
the easiest way to replace the "cp" command is using "cat"
cat "sourcefile" > "targetfile"
if you need to copy more files, create a small script with a "for" loop.
Tom
Related
if anyone can help that would be awesome.. only take 5 min of your time...
we are trying to get some development going for the LG thrill 4g...
can somebody plz copy the flash_image file in the system/bin folder on your device and post it on this thread please!!!
thankyou your help is appreciated!!!
Looked but couldn't find the file you're talking about. Here's the file listing of my /system/bin folder:
heapMemMPApp.out
sharedRegionApp.out
mv
toolbox
dmmcopy.out
syslink_daemon.out
rtcreset
ifconfig
strmcopy_dyn.out
rm
framebuffer_test
mount
wlan_cu
interm3.out
ln
hd
sync
scale.out
rft.sh
lgospd
event_listener.out
lgdrmserver
lge_signaling_d
d2c_test
mke2fs
svc
sgx_flip_test
tomservice
sgx_init_test
nameServerApp.out
mpld
camera_test
stop
tune2fs_static
keystore
hal_client_test
btipsd
ip
am
mmclient
gsm0710muxd
procMgrApp.out
hciattach
audiotest
schedtop
omx_tests
dynreg.out
emc_serial_test
v4l2_gfx_client
dnsmasq
zerocopymsg.out
cmp
SkLibTiJpeg_Test
playwav
dhcpcd
flash_renderer_test
resize2fs
dd
strmcopy.out
pvr2d_test
printenv
chmod
testwrap
ls
cexec.out
ndc
rft
netstat
texture_benchmark
bridgeutil
syslink_tilertest.out
rcm_multithreadtest.out
pppd
input
wlan_loader
rzscontrol
qostest.out
ping.out
slpmtransport.out
tiap_loader
debuggerd
kill
watchprops
hostap
pcsync
chown
dosfsck
service
linker
logcat
fsck_msdos
bugreport
mke2fs_static
ducati_load.out
lgemuxtest
ovg_unit_test
sdptool
notifyping.out
ping
gateMPApp.out
mkdir
date
logwrapper
route
faultapp.out
recovery
utils_test
utilsApp.out
secureclocktest
sgx_clipblit_test
rcm_daemontest.out
notify
ifx_coredump
schedtest
pand
dumpsys
slpmtest.out
lsmod
mtpd
top
isomounter
lge-signaling-test
smd
mediaserver
insmod
applypatch
tiwlan_plts
renice
scale_dyn.out
surfaceflinger
dexopt
vold
bmgr
syslink_trace_daemon.out
gzip
overlay_test
dmm_daemontest.out
set_gadget_personality
listMPApp.out
HDMI_TEST_SEQ
e2fsck
umount
servicemanager
tc
slpmresources.out
tiler_ptest
ps
system_server
memmgr_test
glgps
dbus-daemon
cat
wpa_supplicant
320x240.nv12
app_process
lge_dataexchange_d
screencaptured
installd
lgospd-hid
dalvikvm
rcm_multitest.out
log
ioctl
bootanimation
iptables
df
id
sgx_render_flip_test
vmstat
heapBufMPApp.out
dumpstate
rcm_multiclienttest.out
Morningcall
netcfg
pm
getevent
emumux
sh
tiap_cu
ionice
nandread
lge-dataexchange-test
hal_server_test
start
sendevent
reboot
dmesg
dvz
lge_usim_test
newfs_msdos
sleep
rild
swap_enable.sh
bluetoothd
sgx_blit_test
monkey
tune2fs
vdc
btipsd_cli
services_test
run-as
tomclient
getprop
memmgrserver.out
instutility.out
racoon
ime
rmmod
swapon
wipe
lge_nvd
immvibed
iftop
setconsole
rmdir
pvrsrvinit
rcm_singletest.out
netd
messageQApp.out
setprop
Click to expand...
Click to collapse
Hope that helps!
Hmmmmm...
Sent from my LG Thrill 4G
The only "flash_image" file found in my o3d is located in rom manager's files.
Sent from my LG-P920 using XDA Premium App
I can't find it anywhere on /system, either.
Code:
$ pwd
/system
$ find . -name "flash_image" -print
$
i have not flash image too in my device
Well thanks for looking...
Sent from my LG Thrill 4G
Questions or Problems Should Not Be Posted in the Development Forum
Please Post in the Correct Forums and Read THIS
Moving to General
So I have been working on rooting for the Nabi XD. Specifically to grab a dd of mmcblk0p1 and p2 so I can extract kernel and ramdisk to build a TWRP.
The 2 options I have tried are 1) Bin4ry root many Android, 2) Build TWRP based off the different Nabi2 kernel to gain access to /system
Bin4ry exploit fails with mount: Permission denied, when attempting to remount rw with busybox. The device is 4.1.1 so they must have patched it or cherry picked a patch. The build was this year.
The TWRP will boot but with a blank screen. Comparing the config.gz for kernel builds explains the blank screen. ADB is however is up and running, but the internal storage is not seen as a block device. cat proc/partitions is blank.
The third thing of interest is that there is a bin in xbin called su2. su2 -v yields an output of 3.3.
Code:
[email protected]:/system/xbin $ su2 -v
su2 -v
3.3
[email protected]:/system/xbin $ su2 -help
su2 -help
Usage: su [options] [--] [-] [LOGIN] [--] [args...]
Options:
-c, --command COMMAND pass COMMAND to the invoked shell
-h, --help display this help message and exit
-, -l, --login pretend the shell to be a login shell
-m, -p,
--preserve-environment do not change environment variables
-s, --shell SHELL use SHELL instead of the default /system/bin/sh
-v, --version display version number and exit
-V display version code and exit,
this is used almost exclusively by Superuser.apk
[email protected]:/system/xbin $ ls -l su2
-rwxr-xr-x root shell 91728 2013-02-02 07:03 su2
How can I put this to use? Just running su2 over adb results in nothing, and through Term.apk as permission denied. I obviously need the associated Superuser.apk to grant access, but it seems hardcoded to look for su. I looked through the source to see if I could recompile to look for su2, but I don't know if it's as simple as that.
Any thoughts?
Strange they left the su binary there.
But first : show me a "ls -l su2", we need to see if it has correct permissions or if it is just there and cannot do anything
Second: just try "su2 -c /system/bin/sh", if you are lucky it starts a rootshell.
Regards
I thought it was weird too that is was left behind, and hopefully an easy way to even gain temp root. If I can just dd the boot partition it's smooth sailing.
[email protected]:/system/xbin $ ls -l su2
-rwxr-xr-x root shell 91728 2013-02-02 07:03 su2
No setuid bit set? Should be -rwsr-sr-x?
I tried the second thing via adb. It just echos the command and prompt stays $. Using something like Term.apk yields permission denied. Tried different quotes for passing -c. Any symlinking tricks?
[email protected]:/system/xbin $ su2 -c /system/bin/sh
su2 -c /system/bin/sh
1|[email protected]:/system/xbin $ su2 -c '/system/bin/sh'
su2 -c '/system/bin/sh'
1|[email protected]:/system/xbin $ su2 -c "/system/bin/sh"
su2 -c "/system/bin/sh"
1|[email protected]:/system/xbin $
here's log
[email protected]:/ # cd /system/bin
cd /system/bin
[email protected]:/system/bin # ls
ls
adb
am
app_process
app_process.orig
applypatch
atrace
bcm4334.hcd
bcm4334_murata.hcd
bcm4334_semcosh.hcd
bintvoutservice
blkid
bmgr
bootanimation
bu
bugreport
cat
chcon
chmod
chown
clatd
clear
cmp
content
corrupt_gdt_free_blocks
cp
dalvikvm
date
dd
debuggerd
dex2oat
dexopt
df
dhcpcd
dmesg
dnsmasq
drmserver
du
dump_image
dumpstate
dumpsys
e2fsck
erase_image
f2fs
flash_image
fsck.exfat
fsck_msdos
gdbserver
getenforce
getevent
getprop
getsebool
gps.cer
gpsd
grep
gzip
hd
hostapd
hostapd_cli
id
ifconfig
iftop
ime
input
insmod
installd
ioctl
ionice
ip
ip6tables
iptables
keystore
keystore_cli
kill
linker
ln
load_policy
log
logcat
logwrapper
lpmkey
ls
lsmod
lsof
macloader
make_ext4fs
md5
mdnsd
media
mediaserver
mkdir
mke2fs
mkfs.exfat
mksh
mkswap
monkey
mount
mount.exfat
mtpd
mv
nandread
ndc
netcfg
netd
netstat
newfs_msdos
notify
oatdump
ping
ping6
playlpm
pm
pngtest
pppd
printenv
ps
r
racoon
radiooptions
readlink
reboot
renice
requestsync
restorecon
rild
rm
rmdir
rmmod
route
run-as
runcon
schedtest
schedtop
screencap
screenrecord
screenshot
sdcard
sendevent
sensorservice
service
servicemanager
set_ext4_err_bit
setconsole
setenforce
setprop
setsebool
settings
setup_fs
sh
showlease
sleep
smd
start
stop
surfaceflinger
svc
swapoff
swapon
sync
sysinit
tc
tinymix
tinyplay
toolbox
top
touch
tune2fs
uiautomator
umount
uptime
vdc
vmstat
vold
watchprops
wipe
wm
wpa_cli
wpa_supplicant
[email protected]:/system/bin # f2fs
f2fs
/system/bin/sh: f2fs: No such file or directory
1|[email protected]:/system/bin # ./f2fs
./f2fs
/system/bin/sh: ./f2fs: No such file or directory
1|[email protected]:/system/bin #
Click to expand...
Click to collapse
GR0S said:
here's log
Click to expand...
Click to collapse
Check the permission/ owner of f2fs binary?
That said, I use the recovery binary from the customer CWM based recovery that DerTeufel1980 has created for his dual boot kernel - while this is not the best way, all I needed was a mk and fsck for f2fs - and the recovery binary includes both.
have you got bored of your one Text colored terminal ?
when you look at the results you always are confused ?
well .. you came into the right thread
I'm here today to show you how to make every busybox command fully functional
I was trying to make this command work but no success
Code:
#ls --color=always
then i ended up making busybox fully functional
Note: you must have rooted device and custom recovery and SDK tools " incase you don't have adb.rar "and your phone developer mode and USB debugging checked .
go to your SDK tools press sheft and right mouse click and open cmd here
________________________________________________________________________
now .. lets get to it shall we ?
1 - reboot into recovery and connect your device in your PC
2 - type in these commands in your PC command prompt you opened in order :
Code:
# adb shell
# mount system
# cp /system/bin/sh /sdcard/Download/sh
#adb reboot
3 - reboot your device
4 - download this busybox app and start it
jrummy.busybox.installer
5 - you'll see in the app's INSTALLER icon a location /system/xbin
change it to /system/bin
6 - open app's settings "upper right corner beside the three dot's" and check all what's in the installer settings
7 - press back and click install " your phone will boot into recovery and install the busybox "
8 - after finishing the process your device will reboot normally but wait a minute !!! SU is not working anymore :crying:
9 - reboot your device again into recovery !! " I'll try to fix it for you "
10 - type in these commands in order :
Code:
#adb shell
#mount system
#cp /sdcard/Download/sh /system/bin/sh
#chmod 755 /system/bin/sh
#adb reboot
and we are done
look at the attachment below this is how your terminal will look like and error free
I'm sorry about this post
apparently I was kinda mistaken
I think what happens that lead to this is
when you write down the applet's name in terminal the device start to search inside bin file first .. if the applet was not found in bin .
the device will start to search on xbin file and maybe the whole storage for that command
so .. since there are some applets in bin are the same one in busybox and I was able to locate them "took me like an hour to do so"
and these applets are :
Code:
[COLOR="blue"]blkid
brctl
cat
chmod
chown
clear
cmp
cp
date
dd
df
dmesg
du
grep
gzip
hd
id
ifconfig
insmod
ionice
ip
kill
ln
ls
lsmod
lsof
mkdir
mke2fs
mknod
mkswap
mount
mv
netstat
nohup
ping
ping6
printenv
ps
readlink
reboot
renice
rm
rmdir
rmmod
route
sh
sleep
swapoff
swapon
sync
top
touch
tune2fs
umount
uptime[/COLOR]
there are a lot of difference in results between the factory applets and the busybox applets
if you want to see the difference install busybox in /system/xbin and in terminal type one of these applets above like this :
for busybox applets result :
Code:
busybox [I][COLOR="blue"]applet[/COLOR][/I]
for system applets result :
Code:
[I][COLOR="Blue"]applet[/COLOR][/I]
it might not be a new thing but for me it is
I just wanted to share that info for the ones who doesn't know
Edit : there is also one applet in system/xbin which is " nc "
thanks .
i can't root Samsung galaxy a02 -- SM-A022F/DS Build No: A022FXXU2BUI3 , android 11 , i dont know what to do for rooting and i dont have firmware file (bootloader unlocked)
To get the superuser access ( AKA root ) to be able to control various aspects of Android OS means you need to perform a certain modification that will root your phone's Android. An unlocked bootloader isn't needed to root Android.
Here is what you have to do to root your device's Android:
Replace Android's Toybox binary - what is a restricted version by default - by unrestricted Toybox v0.8.5.
This e.g. can get achieved by means of a Windows command script making use of ADB coomands.
jwoegerbauer said:
To get the superuser access ( AKA root ) to be able to control various aspects of Android OS means you need to perform a certain modification that will root your phone's Android. An unlocked bootloader isn't needed to root Android.
Here is what you have to do to root your device's Android:
Replace Android's Toybox binary - what is a restricted version by default - by unrestricted Toybox v0.8.5.
This e.g. can get achieved by means of a Windows command script making use of ADB coomands.
Click to expand...
Click to collapse
hi , i dont know what is toybox or i dont know really what to do can you tell me step by step please? i have ADB already
dleaderp said:
hi , i dont know what is toybox or i dont know really what to do
Click to expand...
Click to collapse
Typically people do a Google search like "Android Toybox" ...
To save you this search: Toybox is a suite of Linux commands ported to Android.
The commands supported are
Code:
acpi arch ascii base64 basename blkid blockdev bunzip2 bzcat cal cat
catv chattr chgrp chmod chown chroot chrt chvt cksum clear cmp comm
count cp cpio crc32 cut date devmem df dirname dmesg dnsdomainname
dos2unix du echo egrep eject env expand factor fallocate false fgrep
file find flock fmt free freeramdisk fsfreeze fstype fsync ftpget
ftpput getconf grep groups gunzip halt head help hexedit hostname
hwclock i2cdetect i2cdump i2cget i2cset iconv id ifconfig inotifyd
insmod install ionice iorenice iotop kill killall killall5 link ln
logger login logname losetup ls lsattr lsmod lspci lsusb makedevs
mcookie md5sum microcom mix mkdir mkfifo mknod mkpasswd mkswap mktemp
modinfo mount mountpoint mv nbd-client nc netcat netstat nice nl nohup
nproc nsenter od oneit partprobe passwd paste patch pgrep pidof ping
ping6 pivot_root pkill pmap poweroff printenv printf prlimit ps pwd
pwdx readahead readlink realpath reboot renice reset rev rfkill rm
rmdir rmmod sed seq setfattr setsid sha1sum shred sleep sntp sort
split stat strings su swapoff swapon switch_root sync sysctl tac tail
tar taskset tee test time timeout top touch true truncate tty tunctl
ulimit umount uname uniq unix2dos unlink unshare uptime usleep uudecode
uuencode uuidgen vconfig vmstat w watch wc which who whoami xargs
xxd yes zcat
As you might see su is the ROOT functionality.
dleaderp said:
can you tell me step by step please? i have ADB already
Click to expand...
Click to collapse
Actually I'm working on a Windows command script that makes use of ADB what does the job. I'll publish it here when finished:
[TOOL][ADB]][Windows] A 100% Safe Non-systemless Root Tool - No Soft-bricked Adroid Guaranteed
Grant Root Privileges to Regular Users Using Devices With Android 6 and up by Simply Upgrading Android's Multi-command Applet Toybox.
forum.xda-developers.com
jwoegerbauer said:
Actually I'm working on a Windows command script that makes use of ADB what does the job. I'll publish it here when finished:
Click to expand...
Click to collapse
happy to hear that xd
i got a last question, i think my phone's storage is shrunked after i used firmware is it possible ? if yes how can i fix it. it was 32 gb now its 8gb
i fixed i used another firmware i'll be wait for your ADB