Occasionally, I request something with sudo, but change my mind after the password prompt has arisen. If the program was executing, I could press Control+C to exit, but this has no effect on the password prompt. If it was gksudo, then I could likewise press Cancel.

So, is there anyway I could cancel sudo's password prompt besides pressing Enter multiple times, waiting for the wrong password dialogue?

  • 1
    This might shed some light.
    – Thecafremo
    Commented Jun 24, 2015 at 9:33

1 Answer 1


I was unable to find acceptable explanation for that. It does not occur with every command. For instance, if you try sudo ls you can usually terminate it using ctrl+c.

You can still press enter immediately followed by ctrl+c, that usually works.

  • True. I can't find now what command was causing the issue with the password prompt. Did you happen to find one? Commented Jul 23, 2015 at 14:56
  • No, I was unable to find any, but I know they exist, because I have encountered same problem sometimes. Commented Jul 23, 2015 at 15:43

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .