hi i install android stdio on Ubuntu 18.0 then i try to start android emulator i got error
/dev/kvm permission denied
i try some stackoverflow question but its not solve my problem those question links are
1.Android Studio: /dev/kvm device permission denied
2.KVM is required to run this AVD. Unknown Error! Please file a bug against Android Studio
3.Ubuntu 14 Android Studio 3 xrdp /dev/kvm permission denied
t tried all this but its not solve my problem and i give chmod 777 permission also
chmod 777 -R /home/halfix/Android/Sdk/emulator/
still i have /de/kvm permission divided
Android studio can't access /dev/kvm directory. To allow access run
sudo chmod 777 -R /dev/kvm
It will ask for your password. After that restart android studio.
I followed these steps to make it work in Ubuntu 18.04
Step 1: Install qemu-kvm
sudo apt install qemu-kvm
Step 2:
Add user to kvm group using:
sudo adduser <username> kvm
Step 3:
If it still showing permission denied:
sudo chown <username> /dev/kvm
No need to give whole permission to the kvm. you can give owner access for the kvm is fine like as follow
sudo chown <username>:<username> /dev/kvm
This is a realistic error message related to permission but mine happened to be the same message when java was not installed and ran the app. Hope this will help if would be my case.
/dev/kvm permission denied android studio
[Motherboard]Set VT(Virtualization Technology) in BIOS and install Virtual Machine
https://www.asus.com/in/support/FAQ/1045141/#A
Ut worked for me:
sudo apt install qemu-kvm
Re-start terminal and execute the following command:
sudo chmod 777 -R /dev/kvm
Related
I am using android studio 3.4.2. When I try to update
the android studio it says
"Studio does not have write access to /app/extra. Please Run it by a privileged user to update"
How to solve it?
I would suggest to set your current user as owner of /usr/bin/android-studio
This will resolve the issue in long term:
sudo chown -R $USER:$USER /usr/bin/android-studio
Navigate to your Android studio folder via terminal then run android studio with administrator privileges, using sudo or su. If you provide more information, like which OS you are using, maybe I'll be able to tell you the exactly command line you should use.
Edit:
Open terminal application, then type de following :
cd ~/android-studio/bin *
Now we must run Android Studio script file studio.sh as administrator:
sudo ./studio.sh
If doesn't work try : sudo sh studio.sh
(Optional) To prevent this problem every time you want update android studio, see https://stackoverflow.com/a/37704528/8513494
And is it.
I'm assuming that your android studio is located on your user folder, if there's a problem with this step, you should check /opt/ directory and look out for android studio installation folder or see https://superuser.com/a/1080329
I would suggest setting up your current user as the owner of Android Studio
Linux
sudo chown -R $USER:$USER /usr/bin/android-studio
Mac
sudo chown -R $USER /Applications/Android\ Studio.app
or if you using android studio portable then you can use custom path like this.
sudo chown -R $USER: pathDirOfYourAndroidStudio/Android\ Studio\ Preview.app
For linux mint 20:
sudo chown -R $USER:$USER /opt/android-studio-4.2/android-studio/
Happens on Mac when you do not have Android studio in /Application directory. Move it there, if it is not resolved, try this answer.
Set access to Read and Write (default is Read only)
I'd suggest changing the owner of the android-studio directory, doing so depends on the path of your android studio. Here is mine
sudo chown -R $USER:$USER /opt/android-studio
But you might have the following path
sudo chown -R $USER:$USER /usr/bin/android-studio
Check well and enjoy
If you are a MAC user and running portable AS then the simple solution is to move the application within Application folder. Check this video. It solves my issue after wasting 3 hrs within the terminal but nothing is wasting of time. I am running MACOS 13(Ventura) & AS Electric Ele.
i developed one project in ionic2
while i am doing ionic build android i am getting this error
my ionic info is
Cordova CLI: 6.3.0
Ionic Framework Version: 2.0.0-beta.10
Ionic CLI Version: 2.0.0-beta.36
Ionic App Lib Version: 2.0.0-beta.19
OS: Distributor ID: Ubuntu Description: Ubuntu 14.04.5 LTS
Node Version: v4.4.7
I searched in google but no solution works for me..
How can i fix this Bug?
This is Permission Error While Building App
You Need to Give Permission Gradle
sudo chmod -R 777 /Applications/Android\ Studio\ 3.0\ Preview.app/Contents/gradle
Enjoy :)
hit this command
sudo chmod -R a+rwx /appfolder
It is caused by permission problem. More info on problem here.
If this does not solve your problem then its probably issue of permission in your user profile directory. Try above command on user directory. It will take some time to apply permission.
Regards.
Use the verbose when you make your cordova build:
cordova build -verbose
It will return to you the path that requires the chmod +x
I was using Cordova to run my Hybrid app on my Android device, and I got this error twice during the unsuccessful build ...
Error: spawn EACCES
#Krunel Vaghela's answer above helped me somewhat ...
This is Permission Error While Building App
You Need to Give Permission Gradle
sudo chmod -R 777 /Applications/Android\ Studio\ 3.0\ Preview.app/Contents/gradle
But I kept having this error:
"chmod: -r: no such file or directory"
I was using this command:
[Sandis-Macbook-Pro:Users sandi$ sudo chmod -R 777 /Applications/Android Studio.app/Contents/gradle/gradle-4.1/bin/gradle
Note that my Android app is named "Android Studio.app" (with a space in the name). Solution is to simply wrap the path in quotes like so:
[Sandis-Macbook-Pro:Users sandi$ sudo chmod -R 777 "/Applications/Android Studio.app/Contents/gradle/gradle-4.1/bin/gradle"
NOTE: In order to find out which folder was having the permissions problem, I had to use this command:
sudo build -verbose
Which yielded the path to the permissions problem folder like this:
ANDROID_HOME=/Users/sandi/Library/Android/sdk
JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.8.0_151.jdk/Contents/Home
Running command: "/Applications/Android Studio.app/Contents/gradle/gradle-4.1/bin/gradle" -p /Users/sandi/Desktop/CORDOVA_NOV16/HHUB_NOV17/hhub_CURRENT/platforms/android wrapper -b /Users/sandi/Desktop/CORDOVA_NOV16/HHUB_NOV17/hhub_CURRENT/platforms/android/wrapper.gradle
Error: spawn EACCES
So take the path after "Running command:" - put that, inside quotes, after the ...
chmod -r 777
And that's what saved my day.
Had the same problem, I got it fixed by giving 777 permissions on my Sdk folder :
chmod -R 777 /YOURINSTALLOFANDROID/Sdk
After upgrading to Android 3.2, gradle version has been changed up to 4.6.
So I had to use this following command to modify gradle file permission in my Mac Terminal.
sudo chmod 755 "/Applications/Android Studio.app/Contents/gradle/gradle-4.6/bin/gradle"
Just Remove "node_modules" folder and re-install it using
sudo npm i
Hope It get works ..Thanks..!
I am running my Android studio on Ubuntu 14.04,its was working fine but suddenly its shows the following error while do build my project.
Error message:
ADB not responding. If you'd like to retry, then please manually kill "adb" and click 'Restart'
I have tried the following in terminal but it also not worked
node#node-Lenovo-G550:~/Android/Sdk/platform-tools$ adb kill-server
The program 'adb' is currently not installed. You can install it by typing:
sudo apt-get install android-tools-adb
but I have adb under platform-tools folder, I do not know why its says "not installed", How I can resolve this?. Please help me.
terminal image
Updated question:
I have added path as following:
export PATH=$PATH:/home/node/Android/Sdk/platform-tools
then executed this: ./adb kill-server
it gives me the following error
bash: ./adb: No such file or directory
if I run as adb kill-server it gives bash: /home/node/Android/Sdk/platform-tools/adb: cannot execute binary file: Exec format error
The directory where add is located, is not in your PATH variable. You could add it to your PATH variable (export PATH=$PATH:~/Android/Sdk/platform-tools I believe). You can also use ./adb kill-server. Note the ./ in front of adb. Because you are executing an executable in your current directory, you need ./
I have done the following steps and its works.
first run following comments to install:
sudo add-apt-repository ppa:nilarimogard/webupd8
sudo apt-get update
sudo apt-get install android-tools-adb android-tools-fastboot
Second step is move the ADB and Fast boot to our SDK location.
cp /usr/bin/adb <path-to-your-adt-sdk-package>/sdk/platform-tools/adb
cp /usr/bin/fastboot <path-to-your-adt-sdk-package>/sdk/platformtools/fastboot
Last run the command:
SDK location/platform-tools/ adb kill-server.
I installed android studio on Ubuntu and tried running an application.
Seems as there are problem with permission, check if you have permission to execute '.../platform-tools/adb'
Install adb using the following comands
sudo apt-get update
sudo apt-get install android-tools-adb android-tools-fastboot
I am using ubuntu 13.04 I have just set up eclipse and android sdk. But whenever i try to run program or even if I am switching DDMS perspective it shows me permission denied error.
How to tackle this issue.
#Manoj,
Try running following
cd /home/manoj/....../platform-tools
adb version
If you get a Permission denied error then
chmod 770 adb
adb version
you should get a response like "Android Debug Bridge Version x.x.xx"
If so the source of your problem was file permission and set the file permission appropriately
Also check if the $PATH includes the path to /home/manoj/....../platform-tools.
Disclaimer: I use Ubuntu 12.04 and adb at command prompt for my work. I hardly use eclipse for my current work.
Let us know your results
Good luck
Another issue might be adb's file permissions themselves, make sure the user you are using to run eclipse is the same as who owns the adb files. Also make sure that adb is actually executable. (These are both unlikely issues, but worth checking if the other solutions given don't fix it)
From the home directory, try 'adb' in terminal:
If 'adb' doesn't find the adb tool, then your path needs adjusted. (edit .bashrc with bash commands to append to the path the /tools directory of the android sdk, is probably the easiest way, then log out and back in to apply the settings)
If 'adb' says it needs root permission, then try 'sudo adb' and see if that works. (this shouldn't happen, but worth testing)
I'm not actually sure what it says for 'non executable' in 13.04, but it should be self explanatory.
I have solved this problem through following steps:
1. copy & unzip eclipse to /opt/android/android-sdk-linux/
2. x86= sudo apt-get install libgl1-mesa-dev
x64(Ubuntu 13.04 and earlier)= sudo apt-get install ia32-libs
x64(Ubuntu 13.10 and above)= sudo apt-get install libgl1-mesa-dev:i386
I use ubuntu 14 and on this version listed packages have multiple dependencies, so if you could not install this package use apt-get -f install (without package) . this statement install dependencies.
3. sudo gedit /etc/environment
:/opt/android/android-sdk-linux/tools
:/opt/android/android-sdk-linux/platform-tools
the same happened for me when i used adb version it showed adb server not installed ,and it showed how to fix it ,and now works fine ,install the adb server using the following code .
The program 'adb' is currently not installed. You can install it by typing:
sudo apt-get install android-tools-adb