There are stopped jobs
message is far, far away to be an error. It's just a notification telling you that you attempt to exit from the shell, but you have one or more suspended jobs/programs (in your case emacs
which you putted in background using &
at the end of your command). The system doesn't let you to exit from the shell and kill the jobs unless you mean to. You can do a couple of things in response to this message:
- use
jobs
command to tell you what job(s) you have suspended
- you can choose to add the job(s) in the foreground using
fg
command
- if you don't care if the job(s) will terminate, you can just type
exit
again; typing exit
a second time with or without an intervening jobs
command will result in the termination of all suspended jobs.
To answer the second question, I will tell you that not Ubuntu or emacs behaving like this. This is a normal behavior when you put an application to run in background. In this case sudo
is asking for password, but is asking in background, so you can't see this fact. To see it, you should bring back the job in foreground using fg
command:
radu@Radu: ~ $ sudo emacs tet.c &
[1] 7732
radu@Radu: ~ $ # now sudo emacs run in background so you can't see nothing about what's happening
radu@Radu: ~ $ fg
[sudo] password for radu:
After this you can type Ctrl+Z to put again the job in background if you want. Then you can run again 'fg' command to bring back the job in foreground and so on.