(in)stability, crash after camera use etc... - Milestone XT720 General

Hi,
Just want to share my 2 cents
1 cent:
If you have experienced some instability with the xt720 (albeit it is not phone specific, just android specific double (even triple) check permissions.
for example:
./adb shell
and then (in the shell of your phone)
Code:
$ ls -l /system/app/ContactsProvider.apk
-rw-r--r-- app_39 app_39 152194 2010-07-13 16:04 ContactsProvider.apk
$ grep ContactsProvider.apk /data/system/packages.xml
<package name="com.android.providers.contacts" codePath="/system/app/ContactsProvider.apk" system="true" ts="1279026284000" version="7" sharedUserId="10039">
$ ls -l /data/data/com.android.providers.contacts
drwxrwx--x app_39 app_39 2011-01-10 11:39 shared_prefs
drwxr-xr-x system system 2011-01-10 11:38 lib
drwxrwx--x app_39 app_39 2011-01-14 12:34 databases
$ ls -l /data/dalvik-cache/system\AMPapp\AMPContactsProvider.apk\AMPclasses.dex
-rw-r--r-- system app_39 403104 2010-07-13 16:04 systemAMPappAMPContactsProvider.apkAMPclasses.dex
sorry, it seems that i am too new to the forum, so had to change 'the at symbol' with 'AMP'
The goal is that all the 4 has to have the right permission (e.g. the apk (actually this one is not so important), the entry in packages.xml, the corresponding /data/data/ directory, and the dalvik-cache entry )
in the above exmple app_39 and UserId="10039"
of course all can be pretty much simple if running as system or root (instead of shell)
But if You are just stock, it is possible with just shell user.. But You have to type the exact names.
the /data/data entry it is from name="com.android.providers.contacts"
the catch is that there must be something more than just lib, elsewhere You want be able to view the actual permissions/ownership (the lib directory has ownership of system, which is ok)
more tricky is dalvik-cache entry..
it can be determinated from codePath="/system/app/ContactsProvider.apk"
you have to substitute the '/' with the 'at symbol' (sorry i can type it right now) append another one 'AMP' and then classes.dex
If You find some mismatches, do not try to use automatic (e.g. fix_persmission.sh ) tools, better dig around the root cause, and fix by self (i will no go in deep about this for now, but is very easy to run some automated commands, which will do the job
and the 2 cent:
I have experienced phone reboots, after using the camera.
The reboots occur when the screen go in idle, e.g. when the phone gone to sleep, or of course when i put it to sleep (short taping power)
I have do some digging (logcat is your friend), and i have suspect
It turns out, that after using camera and when the phone go to sleep, then the thumbnail service was started, trying to make thumbnails.
I have removed some png files, which actually were broken, that did not help.
Then from the application settings, i have purged cache, data and tap force close on all application/services, in which names i was able to read 'camera' or 'thumb' . I have also removed /sdcard/Android/media folder
Lucky for me, that do the trick so no more reboots after using camera
Please if You have such problems and that do the trick, just let me (even let all of us) know that.
Again, sorry for using 'the at symbol' and 'AMP', but this is actually my first post here, so i am not able to use some special symbols, which are part from some links

Related

[APP] Gscript * Easily launch/save shell scripts from within Android UI *

2013-05-17 ( 1.0.0-alpha3 )
New features:
* Basic terminal emulation ( input handling, color support, cursor control ) etc.
The terminal has 2 gesture modes ( scroll, cursor ) and additional soft-input methods for keys like ctrl, escape etc.
Scroll-mode:
Normal scrolling, auto-scrolling and fast-scrolling (right-edge), double tap on top/bottom to jump.
Cursor-mode:
Edges of the screen will send d-pad (up/down/left/right) keys ( multiple pointers/fingers to control speed of repetition ).
Swipe up/down for page-up, page-down and swipe left/right for home and end keys.
Currently the emulator has no utf-8 support and some other features might be missing.
* The ability to start a terminal/process directly.
* The ability to create aliases directly to a profile.
Enabling an alias will add a shortcut in the launcher directly to the selected profile.
Currently 3 aliases can be set (terminal, su, sh). Sadly android is pretty limited in this area and it only allows enabled/disabling of components so there is no way to change titles, but i guess these 3 are most common. Be aware that you might need to re-start your launcher/phone before changes are visible ( this also depends on the launcher active ).
* Updated icon.
Notice:
Because of major changes happening during the alpha-state it is required to do a reinstall instead of an upgrade ( because of possible database/preference changes ).
2013-04-12 ( 1.0.0-alpha2 )
- Cleanup of list items in the history tab ( date/time added ).
- Basic history view which shows the history transcript and allows to email it.
- Ability to create desktop shortcuts from library items added ( contextual actionbar of an item ).
- If a input dialog (gscript-input) is dismissed it now shows a notification that there is a input request pending and clicking it will bring the user straight back to the dialog.
2013-04-10 ( 1.0.0-alpha1 )
Gscript is currently in an alpha state so features might be missing or broken.
The current progress:
Basics of the new library interface.
Scripts are no longer stored within gscript but instead access is now handled through libraries.
Basically the library decides how to browse through files and get their content and the only thing
that is stored within gscript are the additional item attributes and conditions.
Currently this is limited to a LocalStorage library type, but other options might come later on.
Basic process / history management.
Processes now run in a background service and can be accessed through the 'active'-tab in gscript or
by clicking on their notification (if enabled).
Custom shell profiles ( editable in settings )
Instead of a fixed option for sh / su you can now create Shell Profiles which allow changing of the actual
command including color schemes and additional extras like path appending etc.
Launching scripts directly from most file managers ( if they handle files the way they should... Astro works for me )
Launching scripts from anywhere else (terminal, adb etc) using gscript-exec ( found in /data/data/org.gscript/bin )
First start on the dialog framework to allow graphical user input from shell using gscript-input, which should also work outside gscript.
Very minimal console view ( output only and no input methods yet )
What is WIP:
A lot...
A decent console view which will allow user input
History tab only shows the files that have been executed but no way to see the output, time etc
Additional features to the library interface to edit scripts etc
Additional features to the dialog framework ( to allow file selection etc, numeric input )
Additional item conditions like schedules ( now only has a boot condition )
Desktop shortcuts / widget
Backwards compatibility to android 2.2 ( now 2.3 )
More...
Who should install this?
Users who want to help make this better and can live with the fact that things might not be 100% finished
How to start?
Install
Within Gscript click the + sign in the action bar to add a new library.
Select Local Storage
Give the Library a name
And set the path to a folder you want as the root view ( It does not create the folder so make sure it exists ).
Browse the folder from within Gscript and click an item to execute or long click an item to set attributes/condtions ( shell, boot etc )
In settings new Shell profiles can be created or deleted and a default can be set.
The command-line of a shell profile can have %path% in it. If this is the case it will replace this with the final executable script.
If it does not have a %path% argument the script will be send as input.
The binaries gscript-exec, gscript-input can be found in /data/data/org.gscript/bin ( if everything went right and it is a supported ABI )
Usage
gscript-exec filename
gscript-input types
will list available input types
gscript-input [type]
will list the expected arguments
Sample script which uses gscript-input
Code:
# items are ; seperated key:value pairs
# keys with a * prefix are pre-selected
# in case of radiobuttons only the first
# selected item will actually get selected
RESULT=$(gscript-input \
list \
"Choose" \
"Select multiple" \
"0:The first option;
*1:The second option;
*2:The third option;
*3:The last option;")
gscript-input \
toast \
"Selected items: $RESULT"
echo "Selected: $RESULT"
SELECTED=$(gscript-input \
list \
"Choose" \
"Select single" \
"0:The first option;
*1:The second option;
2:The third option;
3:The last option;" \
radio)
if [ $? -eq 1 ]; then
gscript-input \
toast \
"You selected $SELECTED"
fi
echo "Selected: $SELECTED"
NAME=$(gscript-input \
text-entry \
"Name" \
"Please enter your name")
if [ $? -eq 1 ]; then
gscript-input \
dialog-info \
"Welcome" \
"Welcome back $NAME"
echo "$NAME"
fi
gscript-input \
dialog-message \
"Finished" \
"Finished processing script.. do you want to exit now?" \
yesno
if [ $? -eq 1 ]; then
gscript-input \
toast \
"Goodbye $NAME"
exit
fi
* In case of issues please be clear and give as many details as possible.
* During the alpha-state i will keep multiple versions available for download ( so be sure to check version numbers ).
* During the alpha-state it is required to do a re-install instead of an upgrade ( because of possible breaking changes ).
Fantastic, you got my full support ^^;
Very cool. I was going to make something similar to this for mounting\unmounting debian but I don't need to now.
Already uploaded the source... ill create an apk as soon as I have the time.
Link to source repository
Ok ive created an apk.. Ill update the first post with the zip-file attached.
Please be aware that its still beta and that executing scripts without knowing what they do could harm your system!
I just use it to execute "reboot", "tether start/stop", but you can use it to just execute any shell script either as normal shell or as su.
Let me know if it works and if its usefull for anyone.. thanks.
Exactly what I was trying to find time to write!
Great idea.
Thanks!
awesome
perfect for backing up ALL apps thanks
I must be missing something. I put in the script to launch Debian but it dosent appear to launch. Its just a simple command-
cd /sdcard/debian
su
modprobe ext2
su ./bootdeb
Any suggestions?
you shouldnt need the su commands as you are executing it as su... havent tested multilines a lot other then a few simple calls, but maybe thats where it goes wrong.
Can you try making one .sh file and execute that from within the script field?
That actually how i intended it... that way you can easy backup your larger scripts without having to rely on the database used in my app.
So i just use the commands "tether start" and "tether stop" and leave the actual scripts intact.
Or try it without the su commands and do something like this:
/sdcard/debian/modprobe ext2
/sdcard/debian/bootdeb
Let me know if it works else ill look further into it.
Any chance of adding support for shortcuts to run these commands on the desktop?
Already was thinking about that feature..
I'll try to add an option "Create shortcut" that will create a desktop shortcut to run the selected script.
Ok ive been thinking a bit last night and ill add the following features:
Load from file ( from sdcard .sh files )
Create shortcut ( will create a shortcut to the specified script on the home screen )
Save to file ( will save specified script to sdcard )
Ill also change some things in how things are executed to make it more stable ( im going to save the selected script into a temporary .sh file and execute that one ).
Ok ive made some changes:
* Added ability to create a shortcut to a script from the home screen ( long press home screen -> shortcut -> gscript and then select the script you want to create a shortcut of )
* Added ability to save the selected script to sdcard as .sh file
* Changed the way scripts are executed. The script is now first saved to /sdcard/gscript_tmp.sh and then executed using either sh or su.
Todo:
Load .sh files from sd.
Ill update the first post with a new zip and the latest changes.
New zip file in the first post... and also added some screenshots so people know what it does.
New code is also committed to the source repository.
Let me know if all is working ok.
rogro82 said:
Hi all,
Ive created a small application, for people like me who dont like typing the same thing over and over. I use it for things like tethering and reboot.
Its basically a small database in which you can save your scripts and run them easily from within Android ( either with normal shell or su ).
Ive decided to make it open source ( project can be found on google code, a link is listed below ), so people don't have to be afraid something else is executed as root.
[/URL]
Click to expand...
Click to collapse
Damn you beat me to it! I've been working on this exact same thing but I've not had much free time lately (I have a two month old at home). I think the only thing that I'd planned that I'm not sure if you've integrated is the abaility to import scripts, so a *nix guru could write a script and share it with others, and for other applications to call a script via this application. Still AWSOME!
Damn you beat me to it! I've been working on this exact same thing but I've not had much free time lately (I have a two month old at home). I think the only thing that I'd planned that I'm not sure if you've integrated is the abaility to import scripts, so a *nix guru could write a script and share it with others, and for other applications to call a script via this application. Still AWSOME!
Click to expand...
Click to collapse
Todo:
Load .sh files from sd.
Click to expand...
Click to collapse
Ill add that feature tonight or tomorrow but its coming soon... the shortcut feature took most of my time so didnt had time to complete loading ( although I already started some work on it )
About the calling script from within other applications. I dont know if people would like having other apps running script and as other apps dont know what script a user has its almost impossible to create a solid solution. So yes it is possible, but if its actually workable is another thing.
Glad you like it!
package file
Can someone just upload the package file so we can load this from our android devices?
oops sorry
When I downloaded gscript.zip on my iMac it unpacked it as a folder. Stupid Mac...
Anyway here is the link to the .apk file for people on their androids....
Thanks for posting a link for people to use straight from there mobile. Ill add it to the first post.
Added the ability to load .sh files from the sdcard.
Just put your .sh file in the root of the sdcard and add or edit a script and select "Load file". You will now see the file. Click it and the content of the file will be used as the script.
This way you can easily create .sh files on your pc or share them and eventually execute them as shortcuts
Update is in the first post... About to upload the source to the repository

Workaround for BT ROM/Storage Memory Leak- Requires Root Access

Note: You will be deleting files from your phone so do this at your own risk. To the best of my knowledge these are waste/unreleased files caused by the bluetooth hanging in connecting mode but I take no responsibility if they are actually important and result in any damage(s).
This workaround requires that your root your phone. You will need to have super user access (su) where you see the # sign. We will simply be executing the following commands to list and delete the core.xxxx that we assume are the unreleased/waste files taking up space:
lists:
su
ls -al /data/btips
deletes:
su
rm /data/btips/core*
1. You will also need to install Better Terminal Emulator -Free from the apps store. Note: This app crashes on me when in landscape mode, so you might only be able to use it in portrait.
2. Open up Better Terminal. Press Menu > Preferences
3.(Optional) Turn on Volume Up shortcut and assign: su (enter key) ls -al /data/btips (enter key)
This will give you the ability to quickly list your files in the data/btips directory. Most of them will have 0 - 1002 beside them. This is the size. If you see something significantly larger it is probably an unreleased file waste file. This is only for your reference to view the files and is not really necessary for recovering your space. Next come the part where we actually delete them!
4. Turn on Volume Down shortcut and assign: su (enter key) rm /data/btips/core* (enter key)
5. Try it out. Go to Terminal screen. Press up to activate shortcut to list files(optional). Press down to delete them. If you don't have any unreleased/ waste files it will give you no such file notice obviously. My notice is cut off in portrait mode. These shortcuts will be active when you open the terminal app for quick list and delete. This allows you to manually but quickly recover your storage space.
Thanks to jonnythan for finding the diectory and files:
http://community.sprint.com/baw/thread/23854?tstart=0
I love how these things make the rounds on all the forums!
http://forum.xda-developers.com/showthread.php?t=582823
Tell me about it! I like to keep an eye on all the forums, each one offers something a bit different. My bluetooth thanks you for your help, finally it's no longer sitting in the corner! Now hopefully we get a fix for that pesky connecting issue, it seems to actually be connecting but just hanging somewhere.
elguapo76 said:
Note: This app crashes on me when in landscape mode, so you might only be able to use it in portrait.
Click to expand...
Click to collapse
This only happens to me when I attempt to rotate to landscape mode with the software keyboard already open.
If I close the software keyboard, rotate to landscape, and reopen the keyboard then the application never crashes on me.
Package this up into an app that executes with a button press.
Treefallingquietly said:
Package this up into an app that executes with a button press.
Click to expand...
Click to collapse
Better, package it into a Locale add-on so I can make it run whenever I enable/disable BT!
elguapo76 said:
Note: You will be deleting files from your phone so do this at your own risk. To the best of my knowledge these are waste/unreleased files caused by the bluetooth hanging in connecting mode but I take no responsibility if they are actually important and result in any damage(s).
This workaround requires that your root your phone. You will need to have super user access (su) where you see the # sign. We will simply be executing the following commands to list and delete the core.xxxx that we assume are the unreleased/waste files taking up space:
lists:
su
ls -al /data/btips
deletes:
su
rm /data/btips/core*
1. You will also need to install Better Terminal Emulator -Free from the apps store. Note: This app crashes on me when in landscape mode, so you might only be able to use it in portrait.
2. Open up Better Terminal. Press Menu > Preferences
3.(Optional) Turn on Volume Up shortcut and assign: su (enter key) ls -al /data/btips (enter key)
This will give you the ability to quickly list your files in the data/btips directory. Most of them will have 0 - 1002 beside them. This is the size. If you see something significantly larger it is probably an unreleased file waste file. This is only for your reference to view the files and is not really necessary for recovering your space. Next come the part where we actually delete them!
4. Turn on Volume Down shortcut and assign: su (enter key) rm /data/btips/core* (enter key)
5. Try it out. Go to Terminal screen. Press up to activate shortcut to list files(optional). Press down to delete them. If you don't have any unreleased/ waste files it will give you no such file notice obviously. My notice is cut off in portrait mode. These shortcuts will be active when you open the terminal app for quick list and delete. This allows you to manually but quickly recover your storage space.
Thanks to jonnythan for finding the diectory and files:
http://community.sprint.com/baw/thread/23854?tstart=0
Click to expand...
Click to collapse
This is a life saver. Im the OP from the Sprint forums. Ill give it a try tonight.
I've tried this a couple of times and I keep getting: cannot remove '/data/btips/core*' : No such file or directory. Has this happened to anyone else? I really would like to use the bluetooth on this phone. Any help is appreciated.
ejqr5 said:
I've tried this a couple of times and I keep getting: cannot remove '/data/btips/core*' : No such file or directory. Has this happened to anyone else? I really would like to use the bluetooth on this phone. Any help is appreciated.
Click to expand...
Click to collapse
Not 100 percent sure but I believe that message means there are no waste files created yet. The reason the op instructs to create the shortcut actions in better terminal, is so you can use your Bluetooth and while using it, these files will build up and with the shortcuts it gives you a fast way to delete them, successfully "working around" the memory leak, until a fix is found/released.

[TOOL][ICS][GB][FROYO] Extract contents of Samsung Memo App's Database to CSV File

Many people, including myself, enjoyed using the stock Memo application on Froyo and GB. Unfortunately, it relies on TouchWiz so it is pretty unlikely that it will ever be ported to ICS. There are a plethora of note-taking apps out there to replace it, but how do you get your data back?
You don't need a running version of Memo to do this, just a backup of your Memo.db database.
I've attached a couple of shell scripts that you can run either on your phone or `nix / Mac to help you out. Here is the plan:
extract-memos.sh will take the memo data in a copy of your Memo.db, add a new table with columns for human-readable modified and created dates, as well as color, and write out the result (all memos) in a CSV file. You should be able to read the CSV file in most spreadsheet programs and save the data or transform it as you might need for another use.
Code:
[email protected]:~/Documents/memo-export$ sh extract-memos.sh
Checking database: /sdcard/memo-extract/com.sec.android.app.memo/databases/Memo.db
Checking output directory: /sdcard/memo-extract
You may want to see if there is anything important in
/sdcard/memo-extract/com.sec.android.app.memo/shared_prefs/memo_shared_pref.xml
Data exported to
/sdcard/memo-extract/memo_20120714-100915.txt
Code:
[email protected]:~/Documents/memo-export$ cat /sdcard/memo-extract/memo_20120714-100915.txt
_id,title,content,color,modify_t,create_t,color_text,modify_datetime,create_datetime
1,20120712,"A yellow memo",1,1342138985041,1342138985041,Yellow,"2012-07-12 17:23:05","2012-07-12 17:23:05"
2,20120712,"A tan memo",2,1342139010315,1342139010315,Tan,"2012-07-12 17:23:30","2012-07-12 17:23:30"
3,20120712,"A green memo",3,1342139028326,1342139028326,Green,"2012-07-12 17:23:48","2012-07-12 17:23:48"
4,20120712,"A blue memo",4,1342139045894,1342139045894,Blue,"2012-07-12 17:24:05","2012-07-12 17:24:05"
5,20120712,"A pale blue memo",5,1342139064381,1342139064381,BlueGray,"2012-07-12 17:24:24","2012-07-12 17:24:24"
extract-memos.sh expects to find the database in /sdcard/memo-extract/com.sec.android.app.memo/databases
and will write the output in /sdcard/memo-extract
If you already have a copy of Memo.db (I suggest a copy, as the script adds a new table to the database), you can adjust the input and output directories using the environment variables dbdir and outdir.
If you're not command-line savvy, you might want to try creating a copy of Memo.db using extract-files.sh first. It will try, in order:
The GB location -- /data/data/com.sec.android.app.memo
ClockworkMod backups -- /sdcard/clockworkmod/backups
TitaniumBackup backups (default location only) -- /sdcard/TitaniumBackup
and, if successful, copy/extract into /sdcard/memo-extract
You likely need busybox on your phone to run these scripts on the phone. You will need root if you intend to copy from /data/data
To run them on the phone:
Copy the scripts to your phone; here I am assuming you saved them to /sdcard/
Get a shell started on the phone (adb shell, or a terminal emulator on the phone)
Change directory to where you have the scripts
# cd /sdcard/
Uncompress the files, if you haven't already
# gunzip extract-files.sh.gz
# gunzip extract-memos.sh.gz
Get a copy of Memo.db, either using your own approach, or
# sh extract-files.sh
Assuming that succeed, extract the memos into a CSV file
# sh extract-memos.sh
Thanks to m4xm4n for pushing me to make this available. If you find it helpful, please take the time to poke both our Thanks buttons.
If you have problems, please PM me and I'll try to resolve them.
Latest version is 2012-07-14
What is the warning about memo_shared_pref.xml? I don't even have the file!
I had some reasonably useless information about "check" this and that in my com.sec.android.app.memo/shared_prefs/memo_shared_pref.xml My instance of that file dates back to the first release of the phone. I didn't see it on a fresh GB-created version, so it might be Froyo cruft, or who knows. You probably should check this file to see if there is anything useful to you in it.​
My _id values aren't all there
Missing _id values are from the memos you have deleted.​
What are _id values?
They are an internal number that the Memo app used to keep track of your memos. You probably don't need them to import.​
What are the long numbers for modify_t and create_t?
Internal "unixtime" in milliseconds. If that sounded like gibberish, use the human-readable versions that are in your local timezone.​
The create/modify times seem off by several hours
Strangely, I have some memos that seem around eight hours off in the opposite way I would expect if they were in UTC. I don't know why.​
(reserved for information on importing into other apps)
There are a ton of note-taking apps out there. Right now, I haven't found any that can import the content, the created and modified dates both, and hopefully the color in a reasonable way. If I do, I'll post here how to get the data easily into that app.
Would you be able to post a new link to extract-memos.sh? I just tried clicking on the current one, and both only led to a page that said "410 Gone."

Fun Folders to view on Alcatel One touch Idol 3

/data/system/recent_tasks
/data/system/recent_images
Perhaps I should explain....the recent_tasks folder lists every single activity a user does along with time stamps.
The recent_images folder contains actual (internal) screenshots of your device every time a task or app goes to background and can contain sensitive information.
(When I first looked inside it had a screenshot of my last open contact that contained the persons name and full phone number. It would have also showed the contacts profile pic had I assigned them one)
You can keep these sensitive folders from being written to if you have root by changing the folders ownership with the "chown" command like so: chown root:root /data/system/recent_images
after you remove all the data inside with: rm /data/system/recent_images/*
Do the same for recent_tasks.
(And while your at it you may want to do the same to a folder with the name DROPBOX in the same directory as it contains error messages that could be used to exploit vulnerabilities in your device)

Which app creates these folders ?

Hi,
All days, several empties folders are created in /storage/emulated/0.
All folders are named with dot then numerics (eg ‘.1896745236489’).
Is it possible to know which app create these folders ?
Thanks
My guess it's something like cookies. The dot in front of filename/folder means the files/folders are unvisible to other apps than the one what created these files/folders.
To get the owner of such files/folders you run
Code:
adb devices
adb shell "stat -c '%U' <path_to_your_file>"

Categories

Resources