0

I am very new to Ubuntu but im picking up the coding relatively quickly --- I have Matlab/arduino experience...

While attempting to set up a VPN, my brother decided to type ctrl-z while I was editing the /etc/passwd file and now I cant seem to find it.

With that said, I do not have a password on my ubuntu log in..

If there should be a /passwd in my /etc directory, how can I get in back?

Ive never had a problem like this --- I would appreciate any insight or advice.

Thanks

  • 1
    Do you still have the shell open from which you had run the editor to edit /etc/passwd? If so, the editor is still running, and fugitive's answer explains how to bring it back. If not, then I recommend you [edit] your question add more information. – Eliah Kagan Jan 11 '17 at 00:50

1 Answers1

3

Typing Ctrl + Z will stop the active process and put it in the background.

[1]+  Stopped                 top

To view jobs that are in background, go with jobs command it will list processes that are in background:

jobs
[1]+  Stopped                 top

To 'pull' that job in front, use fg command, in this case fg 1. Using stortcuts like Ctrl +Z , Ctrl +C etc means send adequate signal to the current process.

In this case it is SIGTSTP. You can read more with man signal.

fugitive
  • 1,246