what are the commands to save and exit?

September 10, 2014 8.6k views


I'm installing the Firewall with UFW on Ubuntu. When I run the command to set IPv6, I can not save and close the file. Please what is the key on the keyboard to save and exit?

I'm trying with ctrl+O and ctrl+X but it does not work.

Thak you!

1 comment
  • You may need to be root if you are editing a config file in /etc you will need to be root.

    Try sudo command ...

2 Answers

I can not close the editor. Help please!

What Editor are you using (vi, nano, etc..)

If you are on vi you can try:
:wq to exit and write
:q! to exit without saving
:w to write and continue editing.

Have another answer? Share your knowledge.