• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Where are call logs kept on Android 7.1.1 phones?

coffent

Newbie
Older answers have said they are in

/data/data/com.android.providers.contacts/databases/contacts2.db

but there is no such folder or file that I can find on my phone.
 
Thanks to you both. I didn't realize the phone had to be rooted in order to see what's on it. Bummer! I'll use SMS B&R.
 
It's android's security model. An app can view it's own internal data (obviously), but needs administrator privileges in order to access those of other apps. So a file explorer (an app) needs to be granted administrator privileges to see the volume in which these data are stored.

If an app stores information in the publicly accessible area, /sdcard, then there's no problem. But if they were there any app could read your call logs, so that wouldn't be good for privacy.
 
Thanks for the info. It makes sense. I have a file explorer app, namely ES File Explorer, to which I granted access to everything it asked for - Storage and Phone. Yet it doesn't show /data/data. Out of curiosity, is there a way to grant it (or any other file explorer app) administrative privileges?
 
OK. Still, I'm puzzled. The 'SMS Backup & Restore' app apparently gets access to the log files without the phone being rooted, so why can't a file explorer app also get access?
 
The SMS B&R app is just reading the file (... and then allowing you to copy and save the contents to a file), it is not altering it any way, that is editing, adding, deleting, etc. the contents. A file manager app however, if given the necessary permissions would allow one to not only edit the content of any system files but rename or delete the actual file, a potentially bad thing for most people as they would just be doing any number of things to render their devices inoperable. File permissions (read/write/execute) can be set for different users, which may/may not be part of different groups (user/group/other):
https://www.linux.com/learn/understanding-linux-file-permissions
 
The message database is also intended to be readable by multiple apps. It's not owned by the message app but by a separate message storage app, and any apps that have the necessary permissions can access the data (I don't know whether they get direct access or via the message storage app, but I'd not be surprised if it's the latter).

If you want to restore from the sms backup and restore app it needs to be made the default message app in order to have write access to the messages (it will prompt you). Then open your regular app afterwards and make it the default again.
 
Back
Top Bottom