text:
Where is CM's Appollo's favorite playlist stored, can I export it?
I've been using CM's Apollo as music player and it's doing it's work perfectly, but i'd like to export my favorites (play)list to my PC.
With BlueMuze i can export my self made playlists in .m3u format to SD which works great, but the favorites playlist doesn't show up in BlueMuze because of the fact that either it's location is somewhere else-, or it is saved in another format. I think the favorites list is just a playlist like any other playlist, so then the solution would be very simple, duplicate it and place it in the location next to the other playlists. The point is that i have no clue where Apollo stores it playlists.
I have found a file 'favorites.db' in /data/data/com.andrew.apollo/databases
which contains all my favorites, but other playlists are stored somwhere else.
If i know where, it might be the solution to my problem.
I was hoping you guys could help me with this, i'd be very thankful!
Cheers
Edit: there's ample info about how to export playlists, but thats not the case here since a music players favorites list is not a standard playlist. playlist export apps can't find/recognize this list, so please don't mark this as duplicate, thankyou

Apollo doesn't seem to maintain its own private playlist. I don't know what method it uses but the playlist ends up in a database of Media Storage. The database is at /data/data/com.android.providers.media/databases/external.db. You can find the name and id of the playlist under the table "audio_playlists - (View)". In the table  audio_playlists_map would the  content of  all the playlists. The content can be sorted using a particular playlist's ID. // I've never exported a playlist but it should be easy now. I'll try to find an easy way in the mean time.

This app https://play.google.com/store/apps/details?id=org.ssi.playlistbackup&hl=en claims to take backup of system playlist. Try it out.

@Firelord yeah i came across that location, so that means multiple playlist would be merged into one external.db file unfortunately. I have some low-level basic knowledge about databases and sql but i have no idea how to extract a list of songs to create a playlist from.. :(  would be awesome if you could help me with that! I have tried the app you mentioned, aswell as BlueMuze which does the same, but it can't find/recognize the favorites list

Don't worry about going into low level. The link for the app I posted in my second comment would do the job. That app will find the playlist and will give you the option to save them.

@Firelord it indeed does the job well for self created playlists, but the favorites list doesn't appear among those playlists. Maybe i could merge the favorites.db with the that external.db to make it a regular playlist, but i doubt if i can manage that. Do you think that's possible?


text:
I can't restore apps with titanium back up
I got various problems.
Sometimes I get parse error. Sometimes it just stuck at 0%
I did everything
http://www.guidingtech.com/37632/fix-titanium-backup-errors/
My SuperSU is updated.
This is my ONLY backup.
I used to do xiaomi back up using settings. However,
I have no way to move the back up to the PC because I don't know where xiaomi stored the back up. When I flash the new ROM it seems that the back up is gone too.
Xiaomi pc suite cannot back up
ADB back up fail.
The only back up I have is that titanium back up.
Now I tried to restore and I got the back up stuck at 0%. I tried everything.
I tried upgrading to pro.
I change app processing mode from auto direct to auto indirect. The parse error is gone but still stuck at 0%.
I reselect /TitaniumBackup as backup directory.
No avail.
What sort of back up titanium back up make anyway? Do they just store the apk? Are titanium back up apps the only way to restore titanium back up backups?

I'm confused - have you made a backup with TitaniumBackup and can't restore it?  It would help to know which phone make and model you have, and which Android OS version it's running.  Also please get some screenshots of the errors.

xiaomi. It's working now.

If your problem is solved, please answer with how you solved it (and accept that answer) or consider removing the question.

I added an answer but the answer is deleted due to using too many paragraph. I have fixed that but can't undelete it.

Some websites noted that the user should update su binary. The thing is, I thought my su is up to date. There is no easy way to update su binary. I couldn't uninstall supersu. If I press and hold there is no option to delete because supersu is a system app. When I opened Play Store it read "open". No uninstall option either. So I upgraded my SuperSU to pro version. Still, Titanium Backup failed.
I later browsed into settings of SuperSU. There was an option to clean up super su for reinstall. I selected that option, rebooted the phone and noticed that SuperSU was gone. I later reinstalled SuperSU, launched it and sure enough, SuperSU complained about binary in need of an update. I updated su normally and ran titanium backup again. This time it worked.
I am not sure if this step is also necessary but Titanium Backup warned me about some name space option in SuperSU. I changed that setting. (nope i do not think it's necessary but I would mention it just in case).
Note: I did it again the second time. My xiaomi then have many bugs. It seems that after some flash we should only restore user apps and not system apps.
Then I used xiaomi own backup mechanism, upload the back up to my computer, reflash, and then restore from xiaomi own backup mechanism and it works. Things are working fine now. I can fully enscrypt my phone, which is impossible on MIUI 7.0. I have root. And Everything is working flawlessly.

source: Stack Exchange

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/

sort: votes


text:
What is MTK Logger?
At the moment I am using an alcatel One Touch Pixi. I'm currently deleting apps that I don't use and found MTK Logger.
What is the MTK Logger app and what it is used for?

If it's a system app and doesn't come from Google, please don't delete it, no matter how insignificant it is, unless you've made a [tag:nandroid] backup.

MTK Logger saves all events (from other apps or hardware like connecting to charge) to SD card files as text. It takes a lot of space.
To turn it off, find a file configuration mtklog-config.prop in /etc folder and edit the value from true to false.

MTK Logger only records the user actions performed. For example, if you've opened the camera, a text file will be saved in MTKLogger having information about that particular action.
The MTKLogger file size in my Lenovo K8 was exactly 11.35GB. I just performed the clean operation using SHAREit's CLEANit option and it is safe to delete as this doesn't affect any of your data.

To delete MTKLogger:

Run file manager app, file directory will be shown
Search through the tablet directory for the mtklog directory
Highlight mtklog
Delete by selecting the dustbin icon

It steals your information. Should be removed

Could you add some sources or other justification for why people should believe your answer? We expect answers here to be backed up, not just wild accusations.

It does log a lot of information about your device, and contains security holes through which other apps may obtain this (search for "Kryptowire BLU MTKLogger", for instance), and there is no good justification for why it should remain on your phone. Remove it, or better yet: get a ROM without it.

@RolKau, you should add this as an answer instead of a comment (assuming it's true and you can provide some reliable references to the claims).

@RolKau I've unprotected the question in case you want to post an answer.

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/


text:
How to power-off Motorola phone without screen
How would one power down an Android phone (Moto X 2nd gen - Android 5.1) without the ability to interact with the screen? USB debugging not enabled, nor is custom recovery.
I know how to reboot it, that is not the question.  The question is about turning off, not restarting, the device.
The phone has a broken screen (black screen, blank screen, cracked screen) and also does not respond to touch, so the answer should not include any screen interaction.
Is there a series of button presses, timings, and preconditions (if applicable) if executed will leave the phone in a true power off state?

Many (all?) devices without a removable battery will turn off if you press and hold the Power button for 10 seconds.

@Chahk I just tried on Motorola Nexus 6. It restarted the device at around 6th second. I tested it twice.

Not all.  The device just restarts.

If you're comfortable getting into the hardware, you could always open it up and disconnect the battery: https://www.ifixit.com/Guide/Motorola+Moto+X+2nd+Generation+Battery+Replacement/40717 (watch until 1:15)

I can't be sure that this is the optimal way to power-off the phone, but it seems to work.

Press and hold power until it buzzes or about 15 seconds, then
release.
Press and hold volume-down and the power button for 20
seconds, then release.
Press and release the power button once.

This procedure is demonstrated in a you tube video https://youtu.be/x_jx5u7dXK4
Tip: Even though the broken phone has no display functionality, if you view the phone with another camera, you can check activity of this phone by looking at the infrared emitters at the four corners of the device.  Before power-down, these dots will be flickering.  Afterwards, no flickering.

Came upon this when I was looking for a way to shut down my Moto Z with a broken screen and the method described by Dale (thank you) almost worked, but then I figured out it required one extra step. I probably won't be the only one in this predicament, so allow me to contribute. The procedure described above works by opening the fastboot menu and selecting the "power off" option using the power button. Problem is it would seem newer phones have "start" as the default option instead of "power off". The solution is simply to scroll down to "power off" by pressing the volume down key THREE TIMES and then push the power button.
In summary, to shut the phone down without being able to see what's on screen:

Hold power button for about 15 seconds until it vibrates. This will initiate a restart.
While phone is restarting, hold both the power and volume down button for 20 seconds. This will make the phone load up the fastboot menu.
For Moto X, skip this step. For Moto Z, Z2, and possibly other models, press the volume down button exactly three times. For Moto E 2020, press the volume down button two times. This should scroll it down to "power off".
Press power button to select "power off".

As mentioned before, if you're unsure if the phone's off or not, you can check the infrared emitters for glowing using another camera. Hope this helps anyone else who comes across here.

If you can, just take the battery out

Just found this solution which seems to have worked on my Sony Xperia XZ1. I know it's not a Motorola, but it seems less obnoxious than the other solutions:

Plug the phone into a wall charger and verify it is charging.
Hold the power and volume buttons simultaneously until the phone responds and shuts off.

https://www.ifixit.com/Answers/View/459021/Broken+screen+can't+deactivate

If you do not have custom recovery installed, then try rebooting into the bootloader or the stock recovery itself, and use your volume(up and down) keys and navigate to the Shut Down option.
If this doesn't work, then send it back to Motorola customer service center and let them do their thing.

"use your volume(up and down) keys and navigate to the Shut Down option." -- OP wrote "The phone has a broken screen (black screen, blank screen, cracked screen)". I also checked a YouTube video showing the UI of that device's bootloader and it doesn't offer power off.

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
Frustrating Android Autocorrects - OK, CE, SE
My Android MotoX frustratingly auto corrects in the following ways...
some -> SE
come -> CE
ok -> OK

I've had a look through my Settings > Languate & input > Personal dictionary both English (United States and For all languages and have not found ANY entries for these.
I've tried creating an auto-correct entry so that 'ok' would be autocorrected to 'ok' (lowercase to lowercase) but that didn't work.
These terms are so generic that google searches are near useless.
Does anyone know how to fix this? I've heard that Clear Data in Google Keyboard's App info would do it, but I have my doubts and would rather not lose all the legitimate auto-corrects I've stored.

What happens if you tap and hold on the CE box (at the top of the keyboard, not where you're typing)?

I'm actually having trouble duplicating the issue consistently where SE and CE are concerned. I've noticed that I'll type 'some' hit space and it auto-corrects to 'SE' for some unknown reason. But not always. Here's what I get with 'ok' though screenshot

You could get another free keyboard app. The default app is quite limited.


text:
WiFi only working while charging the phone
I am being experiencing this very strange issue in the last couple days. I have a Samsung Galaxy S3 Mini with an (unofficial) build of Cyanogenmod 11. Is has been working fine for the last year with this ROM. However, since yesterday, the WiFi is not working very well.
Basically, when I turn it on, it doesn't find all the networks I expect. When I connect to my home network, it shows a very weak signal and often disconnects completely.
Another issue that I think could be related to, is the battery. It discharges very quickly, I need to charge the phone twice a day (it's not a big problem though). Sometimes if I reboot the phone, I loose up to 30% of charge.
After various test, I found out that when the battery is very low, the WiFi scans but doesn't find any network, hence I can't use it. When the battery is half charged, I can connect to my network, but the connection is very unstable. When it's fully charged, I can connect to my network and browse the web normally.
Now the weird part is, if I plug my phone to AC power, the connection is (almost) perfect. WiFi works, it finds all the networks, and the signal is great.
If I try pinging 8.8.8.8 from the phone on half battery, I get several packet drops with time ranging from 200ms to 10000ms. On AC power, it is mostly stable on 40ms. All this problems are identical with another network.
I would like to know if the battery and the WiFi issues are related?

WiFi consumes battery. With this in mind, the operating system is designed to restrict or lower the strength of using the WiFi, with the basic goal of saving battery juice, to extend the battery life a bit.
In your case, the most likely culprit is your battery. Replace it, and all should be well.

For instance, there's this discussion: https://www.quora.com/Does-battery-power-impact-Wi-Fi-connection-strength-stability


text:
HTC One won't stop vibrating!
I need help trying to turn off the vibration on my HTC One.
I have done a ton of research, called customer support, and asked questions of people familiar with cell phones, and nothing has worked:

I went to "Sound & Notification" and unchecked "Vibrate" and "Vibrate on Touch".
Then I went to "Accessibility" and made sure "Notification Reminder" was off (it was).
I even turned off the feature that sends notifications to my screen, and that didn't work either.

Everything everyone suggests isn't working and my phone keeps vibrating when notifications come in (not just for games or Facebook, but even for missed calls or voice messages and text messages). It's really loud when it vibrates because it reverberates through whatever it's leaning against, such as my desk or purse.
I have to put my phone on silent to avoid the vibrating, otherwise it can be heard in the next room.
I'd like to have it on a really low volume so I'm the only one who can hear it when it's sitting beside me at work, but the vibrating makes that impossible.
How do I get it to stop vibrating when all the settings for that feature are turned off?

Which Android version are you using? Go to Settings app -> About, if you don't know it yet.

Weird that none of those settings worked. I would recommend lowering the vibration intensity, since it is a stock option on most HTC One devices now.

Go to Settings – Sound – Vibration intensity. Then slide the bars
  left or right to change the intensity.

Referenced here
Other places to check: Settings - Sound & notification - Other sounds - Vibration intensity
If your device does not have that option, I have used FauxClock on my HTC One M7 to adjust it via root: Faux123 Kernel Enhancement - Google Play

If you have the M8, ElementalX Kernel is a good option: XDA thread It has vibration intensity controls, along with a load of other tweaks for saving battery, improving performance, etc.
If you're a fan of Xposed framework, there is an Xposed module available, but I'm not sure of the device compatibility.
If you don't want to root at all, there is an app called Vybe that records custom vibration patterns without root, see a description here. You'd likely be able to record an "empty" vibration pattern so that your phone doesn't vibrate at all. Can't find it on Google Play, here's another app that has the same function, with good reviews: Vibration Control - Google Play
Hope one of these suits your needs


text:
Ability to monitor sound volume when headphones are used?
I am curious if there is a way to log sound volume when headphones are used to play music.
I am doing a research project to quantify hearing loss resulting from listening to music on phones and need a way for people to provide stats about how loud and how long people are listening to music with their headphones on an android phone.
Is this something I would need to root the phone to do?

No, you do not need root to monitor the volume.
If you're looking to develop an app for this project, you're in the lucky place because you do not need to know Android programming to deploy this.
There's an app called Tasker, which allows you to automate your device, but also allows you to export apk's (Android applications)!
Screenshot:

With Tasker, you can set up a profile to detect "volume changed" and send it to your webserver (or store it locally).
The navigation is Profiles Tab > "+" on bottom right > Event > Variable Set > Media Volume: %VOLM and create a new task to send it to your webserver via Action > Net > HTTP Post.
After that, download Tasker App Factory (separate app), and move your profile into a new project by long-pressing on the home icon, clicking "New Project", and naming it. You'll have to drag your profile and task to the new project, and set an icon for your project. Finally, you'll be able to long-press on your project, hit Export, and hit "As App".
Good luck with your project!

awesome thank you this is even better than the answer I was hoping for!! (incidentally is there an equivalent app for iphone?...or at least, do you know if it is possible to do this sort of monitoring on iphone). thanks again!!!

This sounds insufficient for the OP's needs because it records only what the volume slider is set to, not how loud the sound really is. For example, you might be listening to loud music at low volume or quiet music at full volume, and they would produce the same sound level.

@leeroid no problem! You're in the wrong place for iPhone advice, but from what I know there is no way to tell what the volume level is from a sandboxed iPhone app. Automation apps are also limited in the iPhone world, because they don't have access to system resources. I may be wrong though, volume level may be accessible from a global variable in Swift/Xcode. I do acknowledge Dan Hulme's concern, if iPhone support is a must, an idea would be to wire up a Raspberry Pi between the headphone/jack to measure dB levels.


text:
HTC One (M8) blinking red notification light
So after replacing the battery in my One (M8) with a new one from eBay, the notification light just blinks orange when charging. When swapping back to the battery before replacement, it, at least, shows a battery charging screen. What am I doing wrong? I've heard something about 'deep discharge' where it needs to be on the flashing light for 15 to 30 minutes to actually start charging or something like that.
Is this new battery a dud? Should I keep charging it? Really don't know what to do at this point...
Update! I reseating the battery connector on the motherboard and now it's a solid red light when plugged in! Hooray! When pressing the power button, though, nothing is shown on the screen. It's still all black. I just now replaced the screen, since I broke the LCD below the glass last time I tried to take it apart.

Hi, it's been a while, but looks like you've found the solution by yourself, which is great. Consider posting it as a proper answer since self-answering is not only allowed but even encouraged. Thanks.

Make sure the snap on the bottom of the battery connector is seated properly. Hold your finger on the connector while you set the screws.

Also happened to me. Also reseated the battery but then it still blinked. After a  while when I almost gave up the screen came up all by itself with a battery symbol and it started charging. Then the screen went off and the led turned solid orange. By that time I could also switch it on again normally.


text:
Unknown device on Play Store
Something very strange happened, I was trying to install the Steam app and my LG device disappeared, a different device I never seen took it's place: Telstra Samsung SM-G900F. The first device is my tablet, but the second one is completely alien - Telstra is Australian and I'm in Brazil.
Has anyone seen something like this, how can I make my phone appear back in the list?

Could be a caching issue.  Try logging in from a different browser or a private browsing session and tell us if you still see it.

no, same issue on private browsing .-.

Are you using BlueStacks or any Android emulator? (similar issue:  Phantom device showing on Google Play)

It's strange that the date is unknown of that device. It's a Galaxy S5. Did you get any mails that you signed in on a new device?

When you select that device in Android device manager, can you get a location?

Did you change your build.prop file recently? You, or a root application, may have changed your device's "identity" for compatibility reasons (eg. installing incompatible apps, or Xposed framework)


text:
Get package name of an app given its displayed name using ADB commands
I'm trying to:

Get the package names of all apps on my device (none of them are mine so sadly I can't get it from the Manifest) and put it into a file to save for a class project.
I also want to get the package names of only a select number of apps that I choose that I have on my phone. I was hoping there is a way to do that so that I don't have to manually look and copy over from all the different phones I have

Is it possible to get the package name of an Android app by its name using ADB when testing my app on my phone? Maybe by using aapt?
E.g. "ColorDraw" will return com.package.name.drawcolors.

This is for an installed app?  Do you know the path to the APK, or only the "friendly name"?

Hmm I guess I could find the path of the APK. When I install an APK on the Phone it goes to some directory right :/ if I did know the location of the APK using some command lines is it possible to get the Package Name of the app? Say I only know its name.... or maybe I could just find the package name based on the LAST installed app :)

Related, or dupe? Obtain package name AND common name of apps via ADB

Sadly no, I've seen that post but they don't seem to answer what I want. I want to be able to 1.) Either get the last installed apps package name oe 2.) get the package name of the app based on it's name like "DrawColor"  or something simple like youtube

I incorporated your comment since it gives the background of the issue. For  the first part, if you want only to list the package without its displayed name, you can use adb shell pm list packages. For the second part, I somewhat believe the link I mentioned before could help, but something need to be added (sadly, I'm not good at writing shell script)

Thank you, yea for the first I could use: ($adb shell pm list packages) but now I need to get the Apps name from the package name? An for the second I'm trying to get a package FROM an apps name haha. sorry it's a bit confusing here

@Vel that's exactly what the linked question (mine) was about. It's not possible to obtain the app name without additional installations (aapt) either on-device or on-PC. As Andrew suggested, your can use adb shell "pm list packages" to get the package list, strip the package: prefix from each line, then retrieve the corresponding page from Google Play and parse for its <TITLE> ;) Take a look at the code of my little tool Adebar, which does something like that to generate a device documentation.

Thank you for commenting Izzy, I actually wanted to get a hold of you. Please correct me, looking at your link I do want the COMMON NAME and the ICON. 1.) GET COMMON NAME ---> After making an ADB connection I run this command [$for pkg in $(adb shell pm list -3); do echo "- $(adb <whatever_the_command_is> $pkg) ($pkg)"; done] ..... But I don't fully understand since I thought you said you didn't get it to work? an what are the commands? Could you clarify 2.) GET ICON ---> No idea hot to get Icon from package name .... I read your Adebar too :) [MY DEVICE IS ROOTED]


text:
Xiaomi becomes buggy after I restore tons of apps from titanium backup?
Should I just restore user apps instead of systems apps and data? I also want to restore the grouping of my icons.
What files I can just delete from titanium back up?
What would be the solution for the problem in the title?
This may be related though not the same
Titanium Backup: How to restore user apps and data without system apps and data?
I didn't restore to the new MIUI version. I upgraded MIUI from 7.0.x to 7.1.8

Restore the data of your launcher app to restore grouping of icons. // Did you restore on the same MIUI version or not? Did you do a reboot?  If you upgraded MIUI then it shouldn't come as a surprise the OS becomes buggy after restoring system apps and data from its predecessor.

I have 3 solutions.
1. Compelement with Xiaomi own back up feature
First, the one I actually used. This will also be useful if you use titanium backup for moving to another ROM. Just restore completely. And then uses your ROM normal back up feature.A
For no matter what, everything is backed up. That is all I care. So I created xiaomi backup. I found out that I can see the back up files at MIUI/backup/all backups
You can see more explanation here http://en.miui.com/forum.php?mod=viewthread&tid=237526&page=2#pid4417978
In general, when in doubt, uses some file explorer that allows you to find large file. I think I am using ES File Explorer but I forget.
Now that I know the location of the "local" backup that will be reflashed when I flash the ROM, I simply copy that to my computer and copy it back after reflash.
2. Backup only apps and not system apps
You can do this too. But then you will not have that security settings and icon placements, and accounts restored. So you can do that and try to figure out latter what exactly you should restore .
The thing is, until today I have no idea, which titanium backup restore settings I want (like security settings, account settings, and icon settings). I also do not know which titanium settings causes those bugs. Perhaps they intersect. Perhaps security settings will cause bugs if you restore but is necessary to restore those settings. This is not the solution I used. So you can ask around.
3. Install only apps. Then tweak your own settings
Settings are easy to reproduce. You can also rearrange icons yourself after backing up your apps.
4. Uses Xiaomi own back up feature from beginning
The reason I used titanium back up is because I have no idea how to move xiaomi backup from my phone to computer. Look solution 1 to solve it. It seems that helium and titanium backup is useful only if you want totally different rom. If you just want to upgrade from MIUI 7.0.x to MIUI 7.1.8 it would make sense to uses xiaomi own backup feature.
Notice that the back up WILL be deleted when you reflash (I didn't know that. I thought it's in some safe partition. Which is why I am left with titanium back up as my only backup). Also notice that xiaomi didn't tell in what directory the back up is. So I got to ask around here. http://en.miui.com/forum.php?mod=viewthread&tid=237526&page=2#pid4417978
Actually xiaomi also have MI PC suites to back up your data to computer. My problem is that the MI PC suites is buggy and I cannot connect my phone there. That is even though I can easily moves xiaomi backup using regular file explorer in windows.


text:
Micro SD Card Suddenly not Recognized in Phone Slot Only
This has been bothering me for weeks. I have an android phone (Moto X Pure) that allows for an external storage card to be added. I have one SD card that I was using for a while but I got a new one that I wanted to switch to. The first time I put this card in my phone, it saw it and was happily ready to format it and everything. I accidentally formatted it as a media transfer card instead of an addition to internal storage so I took it out to format it on my computer (with fat32) but when I put the card back in the phone, it wasn't detected. At all. All of my computers seem to like it just fine, a friend's phone was even okay with it. It is literally only my phone that seems to have issues with it. My other micro SD cards are fine in my phone as well. If I connect the SD card through the USB port, the phone recognizes it, but only as a file transfer drive.
I've tried rebooting the device, formatting the card, formatting the card from another phone, and trying to find the card with a file manager from both the phone and a computer with the phone hooked up to it. It seems as though that one SD card just refuses to work with that one slot!
Any help getting the micro SD card to work in my phone would be greatly appreciated!

There are chances that mobile formatting created a hidden partition, so you better perform through format and delete any hidden partition. That should help.

What process exactly did you follow to format it?

You may be experiencing some specific partitioning incompatibility. Try to compare the partition table of cards mountable in your phone with the unmountable card.
Here are some things you might want to take note of:

File systems (exFAT, FAT32, ext4, etc).
GPT vs. MBR.
Hidden partitions or unused spaces preceding the main data partition.


text:
Backup all apks from device using adb: why this loop in bash script doesn't work?
You can do adb shell pm list packages, and after reading through the list, do an adb shell pm path "com.yourpackage" to get the full path and do a simply adb pull.
Fact is: I want to automate this. I thought about a really simple bash script:
for apk in $(adb shell pm list packages | sed 's/package://g' | sort); do
    # If you just do an echo, IT WORKS
    # echo $apk
    # But here it doesn't work
    adb shell pm path $apk
done

But that simply doesn't work. It seems that "$apk" becomes lost or something and nothing is shown in that snippet. I don't know if it's a subshell problem, or some peculiarity when using variables that got through an adb shell.
Should I create a script apks.sh just using pm list, for and such, push it to my device, run adb shell only once and execute apks.sh?

Try enclosing the parameters in quotes: adb shell "pm path $apk" and see if that works. Quoting it such makes clear the entire thing should be passed to adb shell. Without the quotes, it's not clear whether the $apk is 2nd param to pm or 5th param to adb ;)

The culprit is that pm list packages, just as pm path [PACKAGE], results in the output being preceded by the "package:" string. A way to circumvent this would be to iterate through the pm list packages with something like the following: for i in $(pm list packages); do. Then, inside the loop, you'll define a variable var with the content of i, such as in: var=$i. Next, you'll trim the "package:" with var="${var#p*:}", which will return the package name. After that, pass var through pm path, as in: pm path $var, and trim "package:" once more.

Regarding your question, I guess that the variable apk belongs to the Linux terminal only. At line 4, you're trying to pass apk to the pm as if it were an Android shell variable.

It doesn't work because adb  adds carriage return in the output. You can read Gilles' answer for more info on that.
All of you've to do is remove the carriage return. Here's the tweaked script of yours:

#!/bin/bash

for package in $(adb shell pm list packages | tr -d '\r' | sed 's/package://g'); do
    apk=$(adb shell pm path $package | tr -d '\r' | sed 's/package://g');
    echo "Pulling $apk";
    adb pull -p "$apk";
done

You can use -p with adb pull if only you've version 1.0.32 or above of adb. sort is not needed, as I see it.

I derived a one liner bash command from Firelord's awesome answer:
for package in $(adb shell pm list packages -3 | tr -d '\r' | sed 's/package://g'); do apk=$(adb shell pm path $package | tr -d '\r' | sed 's/package://g'); echo "Pulling $apk"; adb pull -p $apk "$package".apk; done

Changes/Improvements from original version:

Backups only 3rd party apps, coz I don't see the point of backing up built-in apps. However, if you wanna backup system apps too, just skip the -3 flag.
Renames all apks to their package names instead of overwriting the same base.apk package in Android 6.0 "Marshmallow" and above.

This solution was failing to account for apk bundles where multiple APKs were returned per package, and I wireless debugging kept disconnecting for me (Galaxy Watch6) so I wanted to skip files that were already downloaded. ChatGPT to the rescue. https://chat.openai.com/share/cdf380e0-cd73-4630-8b3e-7233cec7c2cb. Pretty incredible, it did the job perfectly.


text:
It seems my device doesn't have init.d support, but I have a bunch of init.* files. Can I use the same approach somehow?
-rwxr-x---    1 root     root          3265 Jan  1  1970 init.class_main.sh
-rwxr-x---    1 root     root          1730 Jan  1  1970 init.mdm.sh
-rwxr-x---    1 root     root          3347 Jan  1  1970 init.mmi.boot.sh
-rwxr-x---    1 root     root           325 Jan  1  1970 init.mmi.dtv.sh
-rwxr-x---    1 root     root           562 Jan  1  1970 init.mmi.early_boot.sh
-rwxr-x---    1 root     root          6341 Jan  1  1970 init.mmi.touch.sh
-rwxr-x---    1 root     root          8592 Jan  1  1970 init.mmi.usb.sh
-rwxr-x---    1 root     root          7054 Jan  1  1970 init.qcom.class_core.sh
-rwxr-x---    1 root     root          6920 Jan  1  1970 init.qcom.early_boot.sh
-rwxr-x---    1 root     root          6987 Jan  1  1970 init.qcom.sh
-rwxr-x---    1 root     root          2962 Jan  1  1970 init.qcom.syspart_fixup.sh
-rwxr-x---    1 root     root          2844 Jan  1  1970 init.rc
-rwxr-x---    1 root     root          1327 Jan  1  1970 init.recovery.usb.rc
-rwxr-x---    1 root     root           683 Jan  1  1970 init.surnia.sh

These are all the files that begin with init.* in my /partition. In /system/etc I have some as well:
-rw-r--r--    1 root     root          2767 Mar 26  2015 init.ath3k.bt.sh
-rw-r--r--    1 root     root          1773 Mar 26  2015 init.crda.sh
-rw-r--r--    1 root     root          4987 Mar 26  2015 init.qcom.audio.sh
-rw-r--r--    1 root     root          9938 Mar 26  2015 init.qcom.bt.sh
-rw-r--r--    1 root     root          3651 Mar 26  2015 init.qcom.coex.sh
-rw-r--r--    1 root     root          3791 Mar 26  2015 init.qcom.debug.sh
-rw-r--r--    1 root     root          1725 Mar 26  2015 init.qcom.efs.sync.sh
-rw-r--r--    1 root     root          3083 Mar 26  2015 init.qcom.fm.sh
-rw-r--r--    1 root     root          4023 Mar 26  2015 init.qcom.modem_links.sh
-rw-r--r--    1 root     root         54877 Mar 26  2015 init.qcom.post_boot.sh
-rw-r--r--    1 root     root          2767 Mar 26  2015 init.qcom.sdio.sh
-rw-r--r--    1 root     root         19105 Mar 26  2015 init.qcom.wifi.sh

Are these similar to the init.d feature? How can I check if these init.* are run at boot? If so, how can I use this structure to add a custom script to run at boot?

You probably can't. Just because the files carry init in their names doesn't mean the device supports init.d – if it would, they'd rather be in /system/etc/init.d and not have the init in their names. If you want init.d support on a device not having it, check my list of init.d apps :)

If I recall correctly, only the init.rc is executed at boot. I believe that, by further investigating the syntax, you could create a similar file, in the same location, that will have to be included by the init.rc. Please keep in mind that I never tested what I said.

I did a quick test. What I did, was to create a little file (init.dms.rc), which was meant to create a blank text file on /data by using touch. I then included the file into the main init.rc, with the syntax /include /init.dms.rc. After the reboot, not only had the blank file not been created, but all of my modifications (inclusion into init.rc and the whole init.dms.rc) were reverted.

There's no "easy way" in my scenario. My search found so far plenty of options:
Related: How can I run a script on boot?
http://forum.xda-developers.com/showthread.php?t=2287540
http://iamcmotc.blogspot.com.br/2015/04/android-how-to-run-script-or-system.html
Repacking boot images to add custom scripts: http://forum.xda-developers.com/showthread.php?t=443994
Boot process: http://bootloader.wikidot.com/linux:boot:android
The simpler way is to use an APK to emulate init.d: https://github.com/Androguide/Universal-init.d or https://github.com/Grarak/KernelAdiutor


text:
How to restart a system app from the command line?
After deploying a new APK for a system app, is there a way to restart the app process without rebooting the device?
Non-system apps are managed with the Activity Manager through the am command. There are options like start, restart, force-stop, as well as commands against services, like startservice or stopservice.
I have mainly read and tried around the Activity Manager, and I am missing something. Right now, I just rely on the time-consuming brutal reboot command. Posts on installing system apps also use reboot only, as far as I found.
Great and timely feedback mention the very commands I tried, but when they work, they are in "force" mode. I did not check the source code, but it usually means something akin to kill -s SIGKILL, and I wonder whether that is really necessary to go that far.

Some sample outputs (thanks everyone for comments!):
(note, I have indented the command output for readability)
Restarting with restart
$:/ # am start com.android.email
    Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] pkg=com.android.email }
$:/ # ps | grep email
    u0_a30    1436  117   705400 32128 ffffffff 4006b954 S com.android.email
$:/ # am restart com.android.email
    Restart the system...
    android.os.DeadObjectException
    at android.os.BinderProxy.transact(Native Method)
    at android.app.ActivityManagerProxy.restart(ActivityManagerNative.java:4647)
    at com.android.commands.am.Am.runRestart(Am.java:1410)
    at com.android.commands.am.Am.onRun(Am.java:308)
    at com.android.internal.os.BaseCommand.run(BaseCommand.java:47)
    at com.android.commands.am.Am.main(Am.java:78)
    at com.android.internal.os.RuntimeInit.nativeFinishInit(Native Method)
    at com.android.internal.os.RuntimeInit.main(RuntimeInit.java:243)
    at dalvik.system.NativeStart.main(Native Method)
$:/ # ps | grep email
$:/ # #=> Process was killed anyway
$:/ # am start com.android.email #=> Works again, but the previous error...

Restarting with force-stop
$:/ # am start com.android.email
$:/ # ps | grep email
    u0_a30    2680  1506  706404 31668 ffffffff 40059954 S com.android.email
$:/ # am force-stop com.android.email
$:/ # ps | grep email
$:/ # #=> Process killed
$:/ # am start com.android.email #=> Works again, but it was *forced* kill!

Some context and idiosyncrasies: My particular case is a custom system app (in /system/priv-app) that exposes a service, no activity. I am used to rely on am startservice and am stopservice to manage non-system processes. It does not work properly for system apps (read: "I don't know how to do it" :-) ). All this is on Android 4.4.2, API level 19.

Not really an answer, but faster than a complete reboot it should be to do a soft reboot (i.e. kill the system server). Though I don't know how to do that from the command line (I've normally used the boot menu for that ;) my guess is you simply use the kill command on its process once you've identified that (ps | grep system_server should help you find its PID): kill $(ps | grep system_server | awk '{print $2}'). That said: if you can identify the PID of that app, it should work the same way (but might have side effects).

@Izzy Isn't it something like busybox killall system_server. I used that command before in an app I made.

@SuperThomasLab As I wrote, I didn't try that myself – so you could be right. Still, consider busybox is not a given on all devices – while kill usually is (IMHO; with no busybox it often points to toolbox or the like), as are ps and grep. Admittedly, awk again might depend on busybox, so one might have to do the kill manually in two steps then.

Doesn't the above just restart userland, similar to am restart?  (Related.)  In any case: Eric, could you clarify what the problem is using am start?  It works fine on my device for system apps.

Thank you all. @Matthew Read, the problem is to have a custom system app restart completely. am restart does not work for me, but I may be using it wrong. I cite it, although I do not believe that is right. @all, it would be great to restart without external tooling, if possible. I guess that should be possible properly on such a fully-fledged OS !

Yeah I didn't expected am restart to work, but am force-stop & am start should.  What happens when you try it?

@EricPlaton : I can give my assurance that a system app can be force-stopped completely  and one of its component can be started from scratch again. My answer here can show you that (hint: com.android.vending is a system app). // Can you precisely tell us what in that app are you trying to restart? am start -S COMPONENT would force-stop the app and then start your app's component. am force-stop PACKAGE and then am start or am startservice can help you as well.

Thank you all, again! I have updated the question to address most of your feedback. I see that there are solutions, but don't you feel weird that you have to force stop a process to restart? That's one of the motivation for the question, and I should clarify it.

I'll have to take a peek around the source code and see whether the Android system itself does a kill when updating an app.


text:
Android Wear "Google" app only shows weather info
I have been using my Sony SWR50 smart watch for about a week now and all is working just fine, everything syncs up as you'd expect.
However when I use the "swipe up" gesture to bring up the Google app, it only ever shows weather info (local, work and current location). I then swipe left to see more options and hit "More from Google" and it never actually gives me anything else, just the same 3 weather items again.
In contrast, on my phone (OnePlus 2) the google app shows the weather and a whole bunch of other stuff such as news articles, youtube feeds, traffic warnings etc.
On the watch there doesn't seem to be any way to configure what is shown.
How can I add more interesting stuff to the watch's google app content?

I never get articles on my watch, but I do get things like "time to home" or "time to work". On an LG Watch running 6.0.1.

I did get an amazon delivery notification appear on the google app on the watch but I would really like to have the same list of items as appears on the phone.  The phone does have a lot more items and I am able to customise them to a decent extent..

Don't think that is supported yet on Android Wear.

Google Now on Android Wear can not be customised. It will get all cards from the phone that are "compatible". Here is a list of compatible cards on Android Wear:

Stocks
Weather
Reminders
Sports
Traffic
Flights
Boarding pass
Shipping confirmation for packages
Public transit info on nearby trains & buses
Friends’ birthdays
Public alerts
Reminders to leave on time for upcoming appointments
Hotel & restaurant reservations

For more details: https://support.google.com/androidwear/answer/6056898?hl=en

Thank you for that link.  I guess I will have to wait for future releases of the apps to enrich my experience :)  I do like the Google Now launcher (which I installed on my phone just now).  It does a much better job than the chaotic, disjointed OnePlus launcher that I've had unknowingly (and subconsciously) loathing for about 3 months now.  Thanks for the information.  I'll try to remember to update this thread in the coming months to reflect any new developments.  Cheers!


text:
Can I transfer WhatsApp messages from Iphone to S5 when the WhatsApp software is already activated?
Every one tells me to activate the WhatsApp account only after the transfer of the file have been done. In my case I have already activated the WhatsApp account.
How can I still transfer the file in?
Thanks

Raw guess: Delete the app's data (from Settings › Apps) and then let it restore from that backup? I'm not using WA, but according to what I've read about that's the way it should work. Also see: Merging WhatsApp chat histories from different devices but same account


text:
How to play speakers sound in microphone
My question is simple but i haven't really found answers via google : How to use the sound played via speakers as microphone input ? (like Stereo Mix in Windows : for example, when you decide to put "Stereo Mix" for Microphone Device on Skype)

What are you trying to achieve by asking this? Is this what you're looking to do: Direct Music Player audio to Caller?

I'm not trying to do jokes, just to put some music on my answering machine when people want to let a vocal message after a missed call. To put music on answering machine is not free. It's also for general knowledge

Use a 3.5mm male to male between your computer audio output and your phones headphone jack and then download an app that turns your headphone jack into a mic input. Can definitely be done on Android not sure about IOS


text:
How do i root Android x86_64?
I installed android x86_64 and now I want to root it but all the root scripts are for 32-bit versions of Android.
I am using console os lollipop that is not rooted.
What are my options?
Thanks

Exactly which Android version are you using? I don't see any 5.0 based image here: http://www.android-x86.org/download

Additionally, on which device?

If you are using an x86_64 build from http://www.android-x86.org/download, such as android-x86_64-5.1-rc1.img, it is already rooted.  There's no need to run a root script.
If that's not where you're getting your image from, please update your answer to add that important detail.


text:
Google Play Games profile fails to change my game profile to public
I've been experiencing a problem with the 'Play Games' app from Google on my tablet.
When I go to my profile, I see a message showing me

Your Game Profile is hidden
  Touch to change this setting

In order to make it public, I touch the option,
and press the Make Public button. Then, I see a popup saying that my profile is being updated and then a toast appears telling that my profile has been updated.
However, when I go back and re-visit my profile, the message still persists meaning that my profile is still hidden.
Also, my friend told me that he can't see me in his 'Players' list even though he follows me on Google+. This means that my profile is not public.
So, How do I make my profile public?
My tablet is running Android Kitkat 4.4.2 and has all the apps (Including Google Play Games) updated.

My Google Play App is now the latest version and now I'm not facing this problem.

Sounds like a permission issue, where unless you have root it reverts regardless of what you have set

In the About me section of your google profile is where you can make your profile public or private.


text:
Block calls without ringing
I've a rooted phone (Samsung Grand Prime, without CM, just the STOCK Rom), and what I want to know if it's possible with Android 5.0 phone or newer to block calls without ringing. By default, the Call Rejection List just wait 1 ring before reject the call... All blocking applications has to wait 1 ring too before blocking the call, which is logical. But the main drawback of this is that people could suppose if they're blocked.
I've tried two applications : RBC & Call Master that do this stuff (they need root permissions) but each shutdown the mobile network and don't seem to work well witht Lolipop or newer.
I've read somewhere that since Gingerbread, Google don't allow applications to get the MODIFY_PHONE_STATE, so just only apps that need root could do it.

Which device is it?

You could try my app search by permissions to find call blockers requesting MODIFY_PHONE_STATE (category Office › Various Contact and Phone Tools is where they're in), turns up a few. You'll need to install your candidate as a system app, though, and might need to pm grant it the permission manually afterwards.

If you wish to not be annoyed by unknown callers, try the following (Android phone) solution.

Open Settings
Select Sounds and vibration
Select Ringtone
Select Silent (this will set your default ringtone to silent all incoming calls)
Go to Phone app
Select Contacts
For each Contact that you DO want to receive calls from do the following:

Select the individual
Select the “i” info
Select “Edit” at bottom of screen
Scroll down until you see and select “View more”
Scroll down until you see and select “Ringtone”
Choose a ringtone other than “Default ringtone”
Press the Back button to return to previous Edit screen
Select Save at bottom of screen
Return to Contacts, repeat a thru h for each contact for whom you DO want to receive calls
If you add New Contacts, remember to follow 1 thru 8 to set their ringtone to something other than the default.

This method will allow all callers to leave a voicemail and not know they have basically been screened.  You can always review your calls using steps 1 thru 8 you can those callers you may have inadvertently missed.

The app TrueCaller as well as a bunch of others have a block feature where it will instantly answer and hangup the call. I personally don't like TrueCaller. You can also check the setting "send to voicemail" in the contact you'd like to block. This sends them to voicemail every time.
On the other hand, if you want them to know they're blocked, why not send them a text saying that, then block them using the above techniques.


text:
Where are the Downloads stored on an LG Nexus 5x?
I'm trying to transfer the contacts from my old phone to my new Nexus 5X.  I exported the contacts to a .vcf file and used adb push to copy the file to the Nexus 5X in the /sdcard/Download/ directory.
Unfortunately, when I use the "Import from .vcf file" option in the contacts list and look at the Downloads section all I see is a PDF I downloaded from Lego.com.  This .pdf is not visible in /sdcard/Download, and I can not find that .pdf anywhere in the filesystem using find / -name '*.pdf' -print 2> /dev/null from an adb shell.
Where should I put the .vcf file so it is visible in the list of Downloads used by the contacts activity?

Are you not able to do this: go into your File manager -> Downloads -> tap once on the file and choose "Open With" -> "Contacts"?

Can you see the file if you open the left panel and chose 'Internal Storage' then open the 'Downloads' folder?

Firelord, that procedure appears to have accomplished my original mission, although it does not answer this question.

Okay, so can you try moving that file in the root of your sdcard and then try to import and see if Contacts app finds it?

Moving the .vcf file from /sdcard/Download/ into /sdcard/ does not make it visible to the Contacts' import activity.  I suspect that I would have to move it into the same (as-yet-unknown) directory as the .pdf file for it to appear on the list.


text:
HTC Desire keeps restarting every 30 seconds
My HTC Desire is 2 years old. I have had numerous issues over the last 2 years between random freezing, unmounted SD card etc.. But now my phone will start, stay on for 30 seconds, and then shut down. It does this over and over. I have tried the safe mode. It does the same thing.  I tried Recovery Mode, to no avail. I have tried removing the battery for hours, no effect.  I did not recently update any apps.  I did not recently add any apps.  It literally began doing this out of nowhere in the middle of my day. I can access anything on the phone as long as it is within 30 seconds, then the phone restarts.

What did you try in recovery mode or does it restart even when in recovery mode? How good is your battery? Did you have the device plugged in when you tried out those solutions?


text:
If Wi-Fi connection drops internet, can device failover to network connection?
Once in awhile the internet will drop on the network that my phone is connected to via Wi-Fi. It's pretty rare, but in instances when it happens, my phone remains connected to the network but won't receive notifications. I won't know that it's not connected unless I'm intentionally attempting to do something that requires internet access at which point I can just disable Wi-Fi.
I imagine that my phone should be able to figure out it no longer has internet access even if it's connected to a network. Is there a way to have it failover to the provider's 4G/LTE connection when this happens?
My device is a Galaxy S6 Edge+ running Android 5.1.1

That's odd... Every Android phone I have ever had (Nexus 4, Nexus 5, LG G2, HTC One M7, and others) including my current Moto G 2015 do this automatically, in fact it happens occasionally at a hotel I stay at frequently. It does take a few minutes sometimes, but I will pull the phone out of my pocket and the WiFi indicator is still there but with an Exclamation Mark on it, and the LTE is connected again... when the WiFi fixes it self then after a little while it stops using mobile data. Although I don't see an option in mine, check your WiFi settings Advanced area and see if there is an option

In the Wi-Fi settings, there's a feature called "Smart Network Switch" which is described as:

If Smart network swich is on, your device will be connected to a mobile network automatically when the Wi-Fi connection is unstable.

So I had this off, which I assume is by default on my phone. Turning it on I assume resolves the issue.


text:
Google password compromised?
A few days ago I noticed my phone notify me about my Google play account as if I had changed my password. Yesterday I found out I had been infected with a rootkit and a packet sniffer. I was able to access my Google account. Found no weird logins to my account. So I checked "Devices" and it said "Unable to connect to phone, last time connected April the 6th". So it means someone did something to my account? I mean it's not that easy to log out of my account on my phone is it? I  changed my password and my password rest email, so I should be safe?

Packet sniffer on your laptop? Or the phone? You can easily remove Google accounts from your phone under Settings > Accounts & Sync. Your phone should have asked for your new password when you changed it (you didn't mention it explicitly.) If it didn't ask, then your phone truly cannot connect to the Internet (Google), or the rootkit prevented the password change. Beware!

For an optimal security, I'll recommend you to enable the two-factors authentication.

You should immediately factory reset your phone, then go to Google and go through the Google Security Check-up and verify EVERYTHING (don't skip any checks), and I would also recommend enabling 2-Step Authentication.
After that, setup your phone again and make sure to enable a lockscreen password, and possibly device encryption as well. Do not enable "Unknown Sources" without somekind of quality security package installed.
I would also go through everything on the Sign In & Security page and look for any anomalies.

Yeah I thought about resetting my phone, too.

Personally, I would factory default then change my password again. Better safe than sorry, but a factory reset is essential IMHO.


text:
Executing script on device shutdown
For custom scripts at boot, we have init.d. I want to know if there's a possibility of executing a custom script when shutting down, something similar to init.d or by using an APK?

You could make an app that receives the SHUTDOWN intent.

I think you can create a xposed framework module for that purpose.

Our default answer on questions like this is tasker – whenever it comes to automation, this is the most powerful tool to be mentioned. Tasker combines Contexts (Events, states, location, time) with Tasks to be fired when such a context is met. For your case, there's an event called Device Shutdown – which you could combine with the task Code › Run Shell to execute your shutdown scripts.
For further reading, I strongly recommend you visiting our tasker tag-wiki, which also links to additional resources like the tasker user-guide or my collection of tasker resources.

This is not easy. especially for scripts that have to run after zygote was stopped. Try to digg /*.rc scripts. may be attaching to the swapoff action help you. There are some mod projects at xda too https://forum.xda-developers.com/showthread.php?t=1387692


text:
Restart touch screen without rebooting phone
Occasionally my screen becomes completely unresponsive to any touch event. Possibly some lower level touch screen driver crashed (?).
Is it possible to only restart the touch screen system without rebooting the entire OS?
I am using a Nexus 6P and have root access.

You're running a Cyanogenmod nightly? It's maybe better to check on their forum.

Please take note that the community is in progress to discourage a problem pertaining to a specific nightly build. Unless you can clarify that the issue is not specific to nightly, the question might be closed (since we don't have better answer than CM devs). Finally, consider to post the bug on their bug tracker for nightlies.

My question is not specific to a nightly build. I removed it as it seems to be confusing. All I wanted to know is if it is possible to restart the touchscreen driver without a full system reboot. I have seen this issue with other phones/ROMs in the past. This is unrelated to any specific ROM.

Can you try adb shell su -c 'am restart' from PC the next time the device freezes and see if the issue persists or resolves? How did you conclude that it is a driver that is causing the freeze? How did you conclude that it is the driver in other ROMs that you've seen having the same issue?

@Firelord Thanks, I will try this the next time the device freezes and report back here.


text:
Android 5.1.1 shortcuts
I have a new tablet with Android 5.1.1. I am trying to create a shortcut on the home screen by copying a Web page from the Internet Bookmarks.  This was a simple procedure in 4.1, but there is no "Create Shortcut" option in 5.1.1. How do you do this?

I guess that it depends from your system browser.

Which browser are you using?

Isn't there a bookmark widget anymore in the app drawer with LP?


text:
Require fingerprint to answer call?
A friend has a problem with other people answering their phone and thereby intercepting their calls. Is anybody aware of an app, setting, or Android distro that requires a fingerprint swipe to answer an ordinary phonecall?
Google has not been helpful (or my google-fu is insufficient level, below 9000).

Simple Google Fu: "android protect incoming calls" turns up a bunch of apps to protect incoming calls. Most of them use PIN or pattern, though. So: android protect incoming calls finger-print → Hit #1 = AppLock 2:

Android 5.1 supported, Samsung Fingerprint unlock supported
[…]
☆ Lock Incoming Calls

(My Google-Fu must be beyond level 9000 then :))
Hit #3 from that search might be worth reading as well: How to Lock Any App with Fingerprint Security on Your Galaxy S5. Not sure if all this is restricted to Samsung devices, though (and you didn't name yours).


text:
How to assign the volume key for clicking pic in Samsung Galaxy Tab 3
Please help, i have a samsung galaxy tab 3 and i want to assign my volume keys for clicking pics when the camera is switched on and thank you in advance

Which Android version and camera app are you using? It already seems to do that in Lollipop and Marshmallow, but maybe it is the feature of camera app in particular. Is the Android rooted?

Related: How to use volume key to take picture in Samsung S3 (with android 4.2) and  Camera app that can use hardware buttons for making photo

Default behavior on a Galaxy S4 (likely the same on a Tab 3) is to use the volume as zoom, but you can change that in settings for the camera app.  Open the camera app, tap the gear icon, then tap gear again, and finally select the gear tab (this is the order in my Lollipop S4; may differ in detail on Kit-Kat or Marshmallow).  One entry is "Volume Key" and you have the option to select "zoom" or "take picture".


text:
MTP selected but PC doesn't show contents of external SD card
I have a Motorola G2. I'm unable to to access contents of external SD from PC. I chose  MTP option for USB configuration. I can access the internal storage but not the external storage. The latter is shown as blank, nothing to display in SD card – but it displays the size of SD card.
I already checked solutions available for SD card not showing files when connected to pc to no avail.
I also tried to clear the cache of media storage and external storage app from Settings › Apps.

Appears to be the same question: Unable to view SD card files on my computer

You still haven't said what your device is, or what type of storage (adopted or portable) ... It would be helpful

The simple way (for Lollipop and older versions): power down the Android device, remove the micro-SD, and connect it to the computer via a memory card reader.  Once you're done with whatever you're doing (copying music/photos, for instance), put the card back into the device and power back up.
As noted in comments, however, on Marshmallow, this only works if the storage is being used as "external"; if it's been "adopted" as internal storage, its contents can't be read except by the adopting device.

This will only work if it is setup as portable storage (external), if the card is setup as adopted storage (internal) it can't be read in a PC or other device, ever.

@acejavelin Thanks, that must be a new ability for Marshmallow; I don't see any way to do that with my Kit-Kat tablet or my Lollipop phone.

@ZeissIkon it is, Marshmallow can adopt external storage as internal storage,  but part of doing so encrypts it to that specific device

Good to know.  I'll edit my answer accordingly.

@ZeissIkon "The simple way (for Lollipop and older versions)" – doesn't match the question, as OP explicitly asked for "android 6.0" (also see the tag), which is neither Lollipop nor older ;) Apart from that it of course should still work on MM, as long as the card was not "adopted" as internal storage (see: adoptable-storage tag-wiki). Unfortunately, OP didn't leave information on how the card is used.

What about PTP ? Will the combined memories camera "merged" folder still accessible through a Windows or Linux file explorer ? (When the SD card is in adoptable storage mode)

@X.LINK Comments are not for extended or off-topic discussion, if you are having issues please research the topic and ask a new question if you have a specific question or issue.

@acejavelin my SD card is portable means external use only.


text:
Aggregating two 4G/3G data links from 2 different sims?
Having two 4G capable sims -from truely two different operators (no virtual carriers at all)- and a Dual Active sim phone (Zenfone 2 Laser), I want to do true load balancing with a 1 sim + 1 sim 4G/3G data links configuration.
However, all I can find when googling is about Dual-Carrier -or Dual-Band (HSDPA++, LTE)-, which is clearly not what I'm trying to do since it's just combining two same operator frequencies to boost speeds.
The approach is like the "speedify" tool, but instead of mixing 4G and WiFi, I only want to mix the 3G/4G sims.
So, the question is: Do someone know how to achieve that on Android ?
By the way, is this automatically managed in Android, or is it driver/kernel/modem (e.g. Qualcomm X10, X12 hardware/firmware, etc) dependant or do I have to enable something manually ?
Any information about that is ok too :)
If possible, the best scenario would be having twice the Dual-Band enabled. This means a Dual Carrier + Dual Carrier configuration, for a total of 4 bands from two totally different operators.

What are you trying to accomplish with this setup? Enhanced download speeds? I can't say for sure, but I would assume Android was never build for load sharing between SIMs, only that is allows you to choose an active one, but I've never owned a dual-sim. Can you get a phone call from both numbers simultaneously?

I'm trying to get better coverage and speed in massively crowded situations, where I often got Denial of Service and can't work at all. You can have two sims working at the same time (call, data, etc), which is Dual Active Sims; or have only one active sim when activity (call, 4G on one of the two sims, etc) is detected by the phone, which is Dual Stand-By Sims. I have a Dual Active sims phone, but I feel that the two sims aren't aggregated since I don't see the two data links working at the same time for the same task (or it looks like it isn't).

I would bet that it would require some serious packet management to loadbalance between two separate chips - not a feature that would warrant being made for a mid-tier mobile device.

You may be right, but do you know if it has already been done in the past by software means ? (custom ROM, custom kernel, "speedify Dual Active sims only", etc)

Dual Active Sim is a pretty niche market. I do not know.

You have to choose the sim  for data in the settings so you can not access both sim's data at a time

Dual Active Sim is a pretty niche market. I do not know there are markets where it is very popular and I disagree that it is niche

As far as i know, the modem only exist one 4G.
You can use it in both SIM (switch it) but you can't use both at the same time.
Even if you're thinking using the first one is 4G and the last one is 3G, it won't work. It's dual-band not dual channel, and beside it will make your phone a lot thirstier than before and i'm pretty sure you don't want that.


text:
Disable touchscreen in Android x86?
I'm running a triple-boot between Android, Ubuntu, and Windows. My computer has a bad touchscreen that is randomly clicking certain areas of the screen, and I want to know if it's possible to disable the touchscreen driver. I have Android set up to boot via grub2. (Note that I never attempted to install Android on the machine itself, I installed it to a USB drive on virtualbox then copied the android system folder to Ubuntu's partition, then modified my 40_custom file so I can boot Android.)
The Android version I'm running is 5.1. I installed this because Android 6 didn't seem to boot in Virtualbox so I thought it probably wouldn't boot on my PC. (Apparently it seemed to softlock on boot inside Virtualbox.)

Sounds like your original problem is not specific to Android, and you're making this an XY problem.
What you should really do is unhook the touchscreen cable, and that solves it for all 3 operating systems.
On the laptops I've worked on, the ribbon cables for the screen are detachable from both ends: behind the LCD panel, and on the motherboard. Find out which is easiest to get to on your laptop by searching for disassembly videos, or just by removing screws until you get to it.
If this is an Android-specific problem for you, you'll want to take a look at /dev/input/event0 and event1 and event2 and so on.
Figure out which event corresponds to your touchscreen by using the getevent -i command from a shell terminal to read the descriptions, and getevent without the -i to track all inputs, touches, accelerometer movements, etc. in live action to narrow down which event is touchscreen. I have not verified this, but you might be able to disable the culprit driver by changing permissions on the eventXXXXX file to read-only with a root file browser.
I also just found an app that seems promising: Touch Blocker - Google PlayBut I'm 99% sure that will prevent using the mouse as well.

The question doesn't assume it is Android specific. The question asks how to fix it for Android. For example in Windows disabling the touchscreen in devmgmt.msc will fix it there, and an entry in /usr/share/X11/xorg.conf.d will disable it in Linux. No messing around with hardware required. In the example of something like a Surface Pro you REALLY don't want to be opening that up to pull a cable if you don't have to.


text:
Fail to install CM13 on Oppo Find 7a
I would like to install Cyanogenmod 13 on my Oppo Find 7a.
I am following the instructions from CM wiki. I am using a laptop with Linux (LMDE2).
I fail to install a TWRP recovery. Fastboot seems to succeed (it does not print any error message). But then, when I try to boot in recovery mode, I still have the original recovery from ColorOS.
I also tried CM recovery, but then I can't even boot in recovery mode (I get stuck on the "Oppo" logo).
I tried anyway to install CM13 using the original recovery. But I get a message "Installation failed".
Do you have any idea of why it fails?

EDIT : I add details on what is happening.

When I run fastboot boot twrp.img, the fastboot screen gets brighter. But then nothing happens, it stays as is, with "fastboot" written on the screen. Then, I hard reboot my phone and hold the keys to get into recovery mode. I get the stock recovery.
When I run fastboot flash recovery twrp.img and then fastboot reboot (holding the key to get into recovery mode), the phone reboot, I get the screen with "Oppo" written, then the phone reboot a second time. For this second time, it boots in normal mode (although I was holding the special key for recovery mode).

Once I booted in normal mode, if I try to boot in recovery mode, I get the stock recovery. It seems to be expected, according to TWRP website, since some devices automatically replace the recovery mode by their own recovery mode.

I recently went through this on my Find 7 so hopefully I can help.  Here's what I've found to be foolproof.

Download the latest ColorOS software and copy it to the device's SD card (either internal or external is fine if your partitions are not unified; external otherwise).  You can also save CM13 there at this point.
Download and flash the latest stock recovery.

Extract that zip file to your current working directory on your PC, put the device into Fastboot mode (hold Power + Volume Up), and run:
fastboot flash recovery ./find7_recovery_4_4.img

Hold Power + Volume Down, releasing the former when the device vibrates and the latter after the recovery screen comes up, to boot the device straight into that recovery.
From recovery, flash ColorOS 2.1.5i and then select the option to reboot; let the device do so.
Download and flash the latest TWRP 3.x recovery: https://dl.twrp.me/find7/

Similar to (2), different filename.

Repeat (3), and you should be in TWRP and can flash CyanogenMod!


text:
Make Titanium Backup work across multiple user accounts
I'm using CyanogenMod 12.0. I have installed Titanium Backup in primary user account.  I have an another user. I tend to let the other user have apps like Facebook, WhatsApp, some games, etc., while letting the owner for maintenance of the device.
The owner has root access while the other user doesn't, so I can't use Titanium Backup as the other but I need to make backups of the other user's apps.  Titanium Backup only lists the apps installed under the primary user account.
So, how to make backup of apps installed in a secondary user account, using Titanium Backup?
Note
I know there exists other backup options but I want to use Titanium Backup (one day or another I'll have to).
If there are other ways besides "using SuperSU instead" I'd appreciate it.

Can CM's root option not be enabled for secondary accounts?

@MatthewRead sorry But I didn't find anything like that in the settings, All what I found is Developer Options -> Root access where I can disable it completely or allow only ADB or allow only apps or both.


text:
All processes crashing suddenly
So, for the 5th time, my Moto G2 (2014) started crashing all android core processes: acore, gapps, etc; over and over again, you press the "OK" button, it crashes again immediately.
Resetting the phone won't fix it.
The last 4 times I always had to make a factory reset, EVERY 3 MONTHS. I can't find any info regardless that issue, and no I don't download anything other than the Google Play Store. I do, however, use my phone as a debugging device for apps I create, since I'm a developer.
These crashes always happen after updating apps on google play. If I could take SS I would, but my phone won't work at all. There's infinite popups saying "com.android.acore has stopped", "com.google.process.gapps has stopped", and it never ends;  and then it start crashing the rest of the apps (Instagram, Facebook, Whatsapp, etc).
Note: I am not running lollipop since they didn't make a proper update for lollipop on the xt1063; they only made a rom with memory leak that needs to be reseted every 6 hours. I'm running 4.4.4.
Please I beg for some help, I am already tired of factory reseting my phone every 5 times.

Did you consider the idea of switching to a custom ROM? This may really be your best choice, if you're unable to update to Lollipop due to the poor quality of the stock firmware.

Time to load CM and let go of this miserable situation. Anyhow. Have you observed, after which particular app update does the system go haywire? I mean, it could be that a system app (possibly a Google app) is always updated by Play Store which triggers  this series of crashes. // What does logcat say?


text:
What does the phone do when it runs out of battery but it has an alarm scheduled?
Does it power off completely or go into a deep sleep state?

Isn't this a self-testable question? A little experimentation, maybe? Then come back and supply your own answer?

No matter what, if there is no battery, there is no power to do anything, it is dead. But android saves the state of these even if you pull the battery. If power is restored before the scheduled alarm, it will still fire. (Assuming you are talking about the actual alarm app. It is feasible, but unlikely, that a poorly written app's alarm scheduling could fail with a power failure.)
However, if you restore power after the alarm has passed, the alarm will not fire.
TLDR: It can't be in a low power state, if there is no power. But it saves scheduled alarms, etc, to memory, so they are not lost.

But apparently some hardware manufacturers have built this feature into their phones, particularly the oppo one plus one : https://forums.oneplus.net/threads/power-off-alarm.300539/


text:
Once you use “Free up space” in Google Photos, how do you keep some photos for offline?
Once you use “free up space” in Google Photos, how do you keep some photos for offline?
I selected some photos and tried to share them to Gmail, but it created a link to the photos in online form.

Good point. But I find I don't have to select any photos for offline use after "freeing up space", because I see all the photos getting downloaded from the online storage shortly after freeing up space. So much for freeing up space, it doesn't.
My solution is to start looking for photo apps that aren't the Google one. Perhaps some of those can use the online part of google photos still. But the Google Photo app has countless of bugs that go unaddressed for years.

I selected the photos, and uploaded them to Google Drive.
I then made them available offline.

If you share them to Google Keep, you don't have to wait for them to be uploaded like in Google Drive.
The photos get downloaded straight from Google Photos to Google Keep.
You can use folders in Google Drive to organize the photos, and you have labels in Google Keep.

Another way to avoid uploading is to use Google Photos on desktop.
Download the photos on desktop Google Photos, then transfer them to your device through USB.

Open the photo using Google Photos, touch the three dots on the top-right and touch "Download". This will download the photo to a Download folder in Gallery. This "Download" option will not be shown if the photo already exists on your device. Also, there seems to be no way at the moment to select multiple photos for downloading.


text:
Why 'am start PACKAGE' cannot launch some apps and shows an error?
I keep having an error trying to start some apps using am start command. It works for many, but for some apps I get the same error mentioned below:

#adb shell am start com.amazon.venezia
Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] pkg=com.amazon.venezia }
Error: Activity not started, unable to resolve Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10000000 pkg=com.amazon.venezia }

#adb shell am start com.whatsapp
Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] pkg=com.whatsapp }
Error: Activity not started, unable to resolve Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10000000 pkg=com.whatsapp }

Just to add on. I can manually tap on the apps and turn them on but in using $ adb shell am start _____ gives that same error for many apps. It seems to give the error when the Package Name is COM.____ but if it is something else the ADB START works

I thought it had to do if the Package Name started with COM. but that doesn't seem to be related. Same error for many apps

In case you need to start an app  using only its package name, you can use this alternative: monkey -p PACKAGE 1

So the command would be something like $adb monkey -p com.whatsapp   ?? I tried also $adb start monkey -p com.whatsapp  .....I can't seem to get that command right :/ (syntax wise). Thank you for your reply :)

The command would be adb shell monkey -p PACKAGE 1.  This trick used to work well. Now it is acting funny in Android 6.0.1 for some reason.

IT WORKED! Your the best...  but it opens the app but gives this output (what does it mean):  Events injected: 1
Network stats: elapsed time=118ms (0ms mobile, 0ms wifi, 118ms not connected)

You can read about monkey here: http://developer.android.com/tools/help/monkey.html. It is  a trick I learned from some answer on [so] sometime ago.

Interesting stuff, thank you for sharing it was educational. Do you why the orignal error above was even appearing and why this command is needed instead? It's just wierd it isn't for all apps but only about half of them experience this.

I do not know. I would have provided a formal answer if I knew the reason. Time doesn't permit me to find out the reason either. Sorry!

No worries was just wondering and really appriciate your help. If you don't mind me asking? I read the link but don't fully under the "event-count". You showed above that I should use "1. "I guess the -p allows it to run one package name but what does the "1" mean and increasing it by more do anything? I can't seem to see any difference when testing.

am start isn't working for those apps because they don't have a "default" Activity that handles action.MAIN.  You could try to inspect their manifest file (inside the APK) to determine a specific activity to start.

use this:
adb shell am start -n com.whatsapp/.HomeActivity

While this might answer the question "How to start WA via ADB", that was not what the OP asked (though it might be implicated). Could you please [edit] your answer and add some explanation?


text:
Why I need swipe screen before enter pattern?
I use Android 6.0.1 (Samsung S7).
Phone locked by pattern. But to unlock it I need swipe screen first, and enter pattern code after that.
I don't have this problem(features) on s4 Android 5.0.1.
How disable this swipe ?
Thnx

See http://android.stackexchange.com/q/30709/1465

I found solution for me - it is use finger sensor. To unlock phone - click home button and leave finger on it. (Sensor integrated in home button). And no need to enter pattern, but if want unlock with pattern need swipe.(If phone use somebody else)


text:
What's this option in the AOSPA stock email app?
On my Paranoid Android ROM, that I installed because the old CM ROM I was using is dead link and I needed a ROM to run, I am configuring the Email app, but I can't understand what is the meaning of this setting:

(It's the fourth option of the notifications settings, for non-French speakers)
I have not seen it in any other screenshots, it isn't in the translation files and isn't documented anywhere.
I think it is for having a notification for each email instead than a global "2 new messages" one, but it is only an assumption.
What does this setting mean? How will the modification of this setting will change the behavior of the app?

I believe your assumption is exactly correct.
Google has laid out these settings the same way as they have in Gmail, which has better translations. The bottom one is indeed the per-message notification toggle.
Click to enlarge

You could also try temporarily changing your language to English to see if the description is any better thay way. Or, of course, you could send yourself a couple e-mails with and without the setting checked and see how the notifications behave.

My assumption was correct. I changed my phone to English and it said "Notify for every message". Thanks for the help, the translation was a bit confusing.


text:
When will my device get the Android 7.0 update (Nougat)?
Android Nougat was officially released on August 22, 2016.  It adds features such as multi-window support.
You can review the high-level changes at the Android developer website.
Of course, not all devices will get this update right away, even at release; others won't get it at all. Manufacturers and carriers often choose to add their own custom modifications, which tend to delay the official release.
When will each device get Nougat, either officially or unofficially, if ever?
See also:

When will my device get the Android 5.1 update (Lollipop)?
When will my device get the Android 6.0 update (Marshmallow)?
When will my device get the Android 8.0 update (Oreo)?

This community wiki will list all of the known and rumored dates for devices. If you have an update make sure to follow the format that's been established, and the following guidelines:

Keep devices in alphabetical order, listing the manufacturer and model.
Specify if the date is confirmed or rumored, and link to the source.
If there is an unofficial release, link to the site where it can be downloaded

Phones
Huawei

Nexus 6P:  2016-08-22 (confirmed)
Mate 8: Q1 2017 (source)
P9: Q1 2017 (source)
P9 Plus: Q1 2017 (source)
P9 Lite: Q1 2017 (source)
Nova: Q1 2017 (source)
Nova Plus: Q1 2017 (source)

HTC

10 - H1 2017 (depending on regional variant) - (confirmed)
One A9 - H1 2017 (depending on regional variant) - (confirmed)
One M9 - H1 2017 (depending on regional variant) - (confirmed)

LG

Nexus 5:  Never (confirmed)
Nexus 5X:  2016-08-22 (confirmed)

Motorola

Nexus 6:  2016-08-22 (confirmed)
Moto Z: by the end of 2016 (confirmed)
Moto Z Force: by the end of 2016 (confirmed)
Moto Z Play: by the end of 2016 (confirmed)
Moto G4: by the end of 2016 (confirmed)
Moto G4 Plus: by the end of 2016 (confirmed)
Moto X Pure Edition (3rd Gen): announced (source)
Moto X Style: announced (source)
Moto X Play: announced (source)
Moto X Force: announced (source)
Droid Turbo 2: announced (source)
Droid Maxx 2: announced (source)

Wileyfox

According to Wileyfox, ALL of their devices will be updated to 7.1.1 nougat. At time of writing (2017-05-02), the rollout is well underway. (source)

OnePlus
None yet.
Samsung
None yet.
Sony

Xperia Z3+: announced (source)
Xperia Z5: announced (source)
Xperia Z5 Compact: announced (source)
Xperia Z5 Premium: announced (source)
Xperia X: announced (source)
Xperia XA: announced (source)
Xperia XA Ultra: announced (source)
Xperia X Performance: announced (source)

Tablets
Asus

Nexus 7 (2013): Never (confirmed)

HTC

Nexus 9: 2016-08-22 (confirmed)

Sony

Xperia Z4 tablet: announced (source)

Other

Nexus Player: 2016-08-22 (confirmed)
Pixel C:  2016-08-22 (confirmed)


text:
Why does my Xiaomi phone have a "Skip Lockscreen" developer setting?
I am using an unrooted Xiaomi phone running Android 4.4, and activated developer mode.  The development options include "Skip Lockscreen". What is this?  Will it this cause any functional problems for my device?

Typically, Android devices default to having no lock screen.  Apparently Xiaomi didn't like this; it is a pretty terrible idea to leave your phone unprotected from others, after all, unless you don't care about theft or its contents.  As such, the option to disable the lockscreen is "hidden" in the developer options.  Presumably this is to help developers who need to go through the load → test → modify → reload cycle often and don't want to be constantly unlocking their devices.
A lock screen is also required to make use of Factory Reset Protection; see this answer for more details.  Otherwise, there is no other functional issues.  The lock screen is purely for security and privacy purposes.

I have provided PIN for security while unlocking. It performs the same operations while I were in Lock screen mode and Skip Lock screen mode.


text:
Can I use the adb shell to know that the phone support OTG or not?
Can I use adb shell command to detect the phone support OTG to transmission the files with an USB Flash Drive with OTG function?

Yes.  All you need to do is test for the presence of the file that enables it.  On devices that do:
# adb shell ls /system/etc/permissions/android.hardware.usb.host.xml
/system/etc/permissions/android.hardware.usb.host.xml

And otherwise:
# adb shell ls /system/etc/permissions/android.hardware.usb.host.xml
/system/etc/permissions/android.hardware.usb.host.xml: No such file or directory

Of course, it's possible for a device to be misconfigured — but you have to actually physcially test OTG to determine that.

If the OTG drive is plugged in at the time of the command, you can also detect OTG by querying these directories:
/storage/UsbDriveA     (Samsung devices)
/storage/USBstorage1   (LG G4, V10, G3, G2, LG devices)
/storage/usbdisk       (Moto Maxx, Turbo 2, Moto X Pure, Motorola devices)
/storage/usbotg        (Sony Xperia devices, Lenovo Tabs)
/storage/UDiskA        (Oppo devices)
/storage/usb-storage   (Acer Iconia Tabs)
/storage/usbcard       (Dell Venue -- Vanilla Android 4.3 tablet)
/storage/usb           (HTC One M7, some Vanilla Android tablets)

Tested on my collection of devices and a quick trip to Bestbuy for testing the latest flagships listed above. Edited to add input from other members here.

On my cheap Android tablet, it is mounted on \usb. But itis nice that you assembled this list. I had no idea it changed that much!


text:
How to restore Line messages from Titanium Backup?
It seems that Line (a messaging app like WhatsApp) is one that I cannot easily restore app data (messages) through Titanium Backup.
There is a whole thread on XDA, highlighting one post:

[...]

Restore Line with Titanium Backup (app+data) (DON'T OPEN THE LINE APP YET!)

Log into a root shell and delete the previous settings:
sqlite3 /data/data/jp.naver.line.android/databases/naver_line
delete from setting;
.quit

[...]

It looks quite difficult and I am not even sure it's correct.
Can anyone confirm before I try? Also, what is a root shell? Is that some form of an app?

See What does "to root a phone" mean? & https://en.wikipedia.org/wiki/Shell_(computing)

I rooted my phone

Possible duplicate of Transfer LINE account from a phone to another without losing friends and chat history

Log into a root shell

It's a mix up of multiple things. It simply means, login into a shell and then switch to root user or alternatively, directly login as the root user. For Android, you can login from a  remote shell using adb shell command. It automatically logins as user 2000. Alternatively, use a terminal emulator app and it would automatically login using its own UID. In both the cases, don't bother about the term "log in".
Switch to root user using su.

sqlite3 /data/data/jp.naver.line.android/databases/naver_line

sqlite3 is a command-line tool to interface with SQLite databases. Stock Android doesn't come with it.
That command does nothing more than attaching the database naver_line located under /data/data/jp.naver.line.android/databases/ to sqlite3 so that latter can do its work on it.

delete from setting;

I don't have that app or its backup but the command indicates that there is a table named setting in the said database. That command would delete all the data available in that table.

.quit

It would disconnect the database and exit from the sqlite3 tool.

I don't know whether those commands would achieve anything or not, so take this solution as a partial answer only.

What is CM? And stock android doesn't have command sqlite3. So how can I do it?

I don't know. You should ask the user who wrote that post. I posted this answer to translate those commands for you. :)


text:
Recover pending text messages deleted before sent
Last night I got a number from a girl, I tried to send her a message, but it hung on "message sending".
I decided to delete the message without saving the number to my phone, and the whole thread disappeared. Now I want the number back.
I have tried to access it from my carrier but they don't have it on there because the message wasn't sent in the first place.
Any ideas on how to recover it? I am using a Motorola Atrix 4G.

See: Is there a way to recover a deleted SMS? / Recover deleted content from userdata partition?

It is extremely unlikely that you can recover the text message itself, but you can try following something like this.
If you haven't rebooted your phone, you could also try running this from your PC while your phone is connected:
adb shell "logcat | grep handleSmsReceived"

The output will look like:
D/Mms/Txn ( 9092): handleSmsReceived messageUri: content://sms/789, address: +15551234567, body: this is a text message

If you don't have ADB installed, you can get it from the Android SDK Tools.

If the device is rooted, there's still the chance to get the deleted entries from the SQLite database (as long as there was no VACUUM run), see my answer.

There's a chance to recover deleted SMS if your device is rooted – but you'll have to act fast (before deleted entries are purged out):

Get the messages database (/data/data/com.android.providers.telephony/databases/mmssms.* files) from your device
Make multiple copies of that (so in case something goes wrong, you can start fresh)
Try one of the available tools to recover deleted rows from SQLite databases
Analyse what you've got

For item #3, here are a few options:

Python Parser to Recover Deleted SQLite Database Data (page includes howto and download); seems to be the same as SQLite-Deleted-Records-Parser, but the latter (Github) has an example that seems to deal with exactly our smsmms.db
Undark (the example on that page even is about recovering deleted SMS – though the database used there doesn't seem to come from an Android device)
Recovering deleted records from an SQLite database (very technical forensics article – think of it as a fallback in case the other methods fail)
Find more with a Google search for "sqlite recover deleted rows"

For item #4 I can recommend SQLiteman (documentation here), which I'm using myself every now and then. Hasn't been updated for a while, but it's simple and easy to work with.


text:
Is it normal for a USB OTG converter to show in lsusb
When running lsusb (not as root) with an OTG adapter plugged in without anything plugged into it I get :
u0_a83@flounder:/ $ lsusb
Bus 001 Device 001: ID 1d6b:0002
Bus 002 Device 001: ID 1d6b:0002
Bus 003 Device 001: ID 1d6b:0002

Is this normal with USB OTG adapters.
Also a USB hub is recognized as another device in lsusb when plugged using OTG

Why wouldn't it be?  Are you encountering an issue?

Aren't they just converters?

Yes, that is absolutely normal.  The host controller can detect the presence of the cable since pins 4 & 5 are bridged.
On my device I ran lsusb with a USB key connected via OTG, then with only the OTG cable connected, then with nothing:
$ lsusb
Bus 001 Device 002: ID 1221:3234
Bus 001 Device 001: ID 1d6b:0002
Bus 002 Device 001: ID 1d6b:0003
$ lsusb
Bus 001 Device 001: ID 1d6b:0002
Bus 002 Device 001: ID 1d6b:0003
$ lsusb

Exactly as expected.  Your device appears to have one more bus compared to mine.

My device has two buses when nothing is plugged in (not even the OTG , NOTHING)

@SuiciDoga There's no hard requirement that they need to be disabled; it doesn't matter.

My device is a Nexus 9


text:
How can I stop facebook's notification about continuous contact uploads?
Every day I receive something along the lines of this (often it's just "1 new notification"):

Seem pretty exciting, maybe I should see what it is. But it turns out it's just facebook pestering me to fork over my contacts list and takes me straight to this page:

There seems to be no way to say "no". Either I turn this feature on or I have a daily notification from facebook. Is there a workaround?
If I can't stop it, I guess I'll just uninstall the app. The only reason I have it is to get infrequent notifications and if most of the time it's spam it's not useful to me.
Some people have suggested accepting the contacts upload and then disabling the feature. However the notification comes straight back. Also, this isn't a solution for the people who don't want facebook to have their contacts at all.
Not sure if this is the right place to ask. If not, where's appropriate?

Go to the downward pointing arrow on desktop and then go to settings and then go to notifications you should be able to turn it off or tweak it there. Hope it helps you.

Edit your post to include screenshots (annotated or cropped) to give detail to your answer, it's always difficult to navigate menus without visuals to go by.

I've been through all the notifications settings I can find in both android's and facebook's but can't see anything relevant.


text:
Where is the layout file for the Sony Xperia launcher?
Due to unrelated reasons my homescreen may reset sometimes. I do not seek help with that, and in fact I am already sure it cannot be fixed right now. However it is annoying to put everything back all the time.
So here's my idea: to work around this, I need to make a backup of the layout file whenever I change it, and when it resets, restore the backup. This way, I won't have to put everything back myself, just restore the file, restart the launcher, and everything is back to normal.
However, I cannot find this file. Where is it?

[tag:backup] your launcher app. That's where your custom layout is. Most likely stored in a database. Related: Where I can find factory home screen layout file?

I couldn't backup system apps using the stock backup app, but I found it. Thanks for pointing me at database files.

You will need root permission to do this.
The files for the stock launcher are in /data/data/com.sonyericsson.home/databases. You need to back up the database AND the journal. If it ever resets, just restore the files. After that, you need to restart the launcher for the backup to take effect. You can do this by temporarily switching launchers and then going back. You could also do this by using a task killer (note - there is no need to have a task killer, refer here)
Note that the location for the layout file is almost always in /data/data/<app package>/database. <app package> usually looks like com.company.launcher.


text:
Android Beta Program: verification failed
I'm trying to install the Android N preview on my Nexus 9 (volantis). I enrolled for the beta program, and immediately got a notification on the device. After the 1GB download, however, the Android Beta Program updater informs me that validation failed.
I tried several times, also on a different WiFi at work. What gives?

It turns out that my Nexus 9 was still running the latest Android M preview.
After snagging the latest Android Marshmallow (6.0.1) build for volantis and flashing it manually (see the instructions here), the OTA update came in again and the Android N preview downloaded, validated and installed correctly.
If you don't get offered the OTA update, make sure that you've enrolled your device for the Android Beta Program here.