Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying to install Java via the terminal using the guide How to Install Oracle Java JRE on Ubuntu Linux.

Everything went perfectly fine until "Step 11: Save the /etc/profile file and exit":

Enter image description here

I spent maybe 30 minutes figuring out what ^ means (apparently Ctrl), but I cannot understand how that guy called the save command where you can choose yes and no.

I did try ^O, but I didn't get the same result as he did. How can I fix this problem?

share|improve this question
Unrelated to your question, but anyway, you have an error in the script in your screenshot. JAVAJAVA_HOME should be just JAVA_HOME. – Tommy Brunn Jun 7 '14 at 9:32

Ctrl + X will quit the editor and you will be asked if you want to save your changes. If you do, press Y for Yes.

Ctrl + O should also work, since that means to save the file, but you won't be asked "Save modifier buffer ? " because you already told nano to save.

share|improve this answer

He save the changes made through Ctrl+O which actually means Write Out while editing a file through nano.


Where ^ means Ctrl.

Note : You'll also have to press Enter to overwrite the existing file if it exists.

share|improve this answer
correct...and one has to press Enter to save it after pressing Ctrl+o,then press Ctrl+x to exit – VenkiPhy6 Jun 6 '14 at 11:11

With the image shown right now you can save just pressing "Y" for yes. To know what key combinations you need to do just check the White square besides the action, which are as follow:

  • Y: yes
  • N: no
  • Ctrl + C: Cancel
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.