3

I am going type the below command to get the information of keytool

keytool -list -v -keystore “C:\Users\key\.android\debug.keystore” -alias androiddebugkey -   storepass android -keypass android

however, it said my key file is not exist.

    at sun.security.tools.KeyTool.doCommands(KeyTool.java:738)
    at sun.security.tools.KeyTool.run(KeyTool.java:340)
    at sun.security.tools.KeyTool.main(KeyTool.java:333)

Btw I am using key in my user name, I dont know it is related or not. Please help me if You know what happen. Thanks.

I have used the highest premission to run cmd but it is the same result.

Here are the snap shot about the path of keytool and androiddebugkey

http://postimg.org/image/xew43joon/ http://postimg.org/image/hwbrj0d5h/

user3423149
  • 159
  • 1
  • 1
  • 16
  • Which operating system you are using ? – Lucifer Mar 18 '14 at 06:16
  • then I think the path `C:\Users\key\.android\debug.keystore` is not proper path, there should be a username in that path. First of all open your c:\ and check where is your debug.keystore file is and the n put that path in this syntax. – Lucifer Mar 18 '14 at 06:17
  • 1
    'key' is my username in my computer. – user3423149 Mar 18 '14 at 06:18
  • Yes. I checked. It is there which in the same path – user3423149 Mar 18 '14 at 06:20
  • As I read from above (not sure if it is a copy & paste issue), the double quote used is incorrect, and it should be `-storepass` (remove those space) – Raptor Mar 18 '14 at 06:20
  • @user3423149, Yes I agree with Raptor, `- storepass` this should not contain any space, it should be `-storepass` like this. – Lucifer Mar 18 '14 at 06:22
  • possible duplicate of [Android: keytool error on the command line when locating debug.keystore](http://stackoverflow.com/questions/2639275/android-keytool-error-on-the-command-line-when-locating-debug-keystore) – i.n.e.f Mar 18 '14 at 06:22
  • I guess it is a copy and paste problem. I have double check there is no space there. – user3423149 Mar 18 '14 at 06:27
  • post your snapshot where your debug.keystore file exist. i will create it for you. – i.n.e.f Mar 18 '14 at 06:29
  • Hi @i.n.e.f Do you mean I need to run the problem before going keytool? But I have to say I have not complete the application. – user3423149 Mar 18 '14 at 06:30
  • I have taken the snapshot and post it in the main content. Thanks. – user3423149 Mar 18 '14 at 06:39
  • in your first snapshot window follow steps of my answer.In First snapshot window press `ctrl+shift+right click` you will get `option open command window here` open that no need of writing whole path & then just copy past this line of code `keytool -list -v keystore debug.keystore` & press enter you will require password put `android` as password & that's it all done. – i.n.e.f Mar 18 '14 at 06:43
  • hope you will get it what i am saying :) – i.n.e.f Mar 18 '14 at 06:47
  • I am sorry I just finished of my dinner I will try it now thanks – user3423149 Mar 18 '14 at 07:15
  • @i.n.e.f I have tried but I dont think there is key tool in that folder So It appear an error to show that keytool is not a correct command – user3423149 Mar 18 '14 at 07:21

2 Answers2

1

Its Simple.Try replacing your double quotes “ and ” with ". They are different in command prompt.

Antony
  • 603
  • 6
  • 14
1

i have one more solution to this problem. Simple press Ctrl+shift+Right Click you will get option Open command window here open Command Window . Do all this where your debug.keystore file exist & paste this line keytool -list -v keystore debug.keystore and it will ask for password Enter android as default Password. Imean to say follow this steps You will surely get rid of your problem.Its working From myside.Hope this will solve your problem.

i.n.e.f
  • 1,773
  • 13
  • 22