I met an Android emulator from Android Studio did not working. I got '/dev/kvm device: permission denied.' error when i tried to run it.
kvm is required to run this avd. /dev/kvm device: permission denied.
Grant current user access to /dev/kvmThe problem is that my user can't get access to the "/dev/kvm". i fixed it to add my user to the group of "/dev/kvm" file.
Problem
When you install qemu-kvm and see permissions of "/dev/kvm" file, the group is set to "kvm".
sudo apt install qemu-kvm
$ ls -al /dev/kvm
crw-rw---- 1 root kvm 10, 232 6월 1 07:51 /dev/kvmSo, if your user is added to the kvm group, it will be fixed.
Solution
You can see if your user is added to the kvm group or not by below command.
$ grep kvm /etc/group
kvm:x:105:You can add your user name to kvm group and make sure it is in like below.
$ sudo adduser username kvm
$ grep kvm /etc/group
kvm:x:105:usernameLet's start Android emulator. it will work.
Related Posts
- How to download and build Android 13, AOSP
- Notification permission request, pop up notification in Android 13
- Resolve `Access blocked: ComponentInfo` error on Android 13
- Fix error "android gradle plugin requires java 11 to run. you are currently using java 1.8."
- Android - Vibration, Vibrator, VibrationEffect example
- How to get phone number in Android
- How to create Bugreports and Logcat with ADB in Android
- Clear application user data with ADB in Android
- How to disable/enable apps with ADB in Android
- How to find PID of a package with adb in Android
- How to grant/revoke permissions with adb in Android
- How to install an apk(app) with adb in Android
- How to kill a process/package from ADB in Android
- How to transfer files using adb push/pull command in Android
- How to capture the screen from adb in Android
- How to uninstall/install system apps from adb in Android
- How to change Settings values from adb in Android
- How to Factory reset with ADB in Android
- How to get logcat from ADB command in Android
- How to capture Heap Dump from app with ADB in Android
- How to force stop an app with adb in Android
- How to start/stop a service from adb in Android
- How to send/broadcast an intent from adb command in Android
- How to start an activity from adb in Android
- How to generate input from adb in Android
- How to check SQLite DB table in Android Studio
- How to get memory info and thread list from adb in Android
- Android - Uri, Scheme and SSP(Scheme Specific Part)
- How to parse a xml file with XmlResourceParser in Android
- Android - Signing an apk with Platfom key
- How to fix "Cleartext HTTP ... not permitted" for Android development
- How to fix "kvm permission denied" for Android Emulator
- Using ADB over Wifi for Android development