Skip to content Skip to sidebar Skip to footer

Adb: Update/rescan Contacts Without Restarting The Android Device

I am trying to load the contacts via db directly using following commands. adb shell rm /data/data/com.android.providers.contacts/databases/contacts2.db adb pull /data/data/com.and

Solution 1:

Finally got the answer.

It's a 4 step process.

# Remove existing contacts from the device
adb shell rm /data/data/com.android.providers.contacts/databases/contacts2.db
# Copy the desired contacts to the device
adb push contacts2.db /data/data/com.android.providers.contacts/databases/
# Kill the contacts app
adb shell kill $(adb shell ps | grep android.process.acore | awk '{ print $2 }')
# Start the contacts app
adb shell am start -W -n CONTACTS_APP_ACTIVITY

Post a Comment for "Adb: Update/rescan Contacts Without Restarting The Android Device"