Based on:
Terminal output scrolling is gone (Headless 11.10 Server, Upgraded from 10.10)
and
https://superuser.com/questions/1331658/why-cant-i-scroll-in-the-terminal
and my own dire situation right now.
What I did before the problem occurred?
I'm running this tor
relay on a VPS, and I'm monitoring it using nyx
tor monitor. I'm connecting to this VPS from my home based laptop, running Ubuntu 22.04, totally updated version.
For the first time I was trying the nohup
command run against nyx
tor monitor.
I just wanted nyx
to survive terminal disconnect (from my local Ubuntu 22.04 laptop), and be able to close the laptop, turn it back on again, ssh into my tor
and nyx
running VPS and bring back nyx
from the background, instead of turning it on after the VPS login.
I've run nohup nyx &
and then my problems started.
I've got the nohup
output:
rafal@debian:~$ nohup nyx &
[1] 4532
rafal@debian:~$ nohup: ignoring input and appending output to 'nohup.out'
Why ignoring input
??
I need to pass the nyx
password. How am I to do this without the input or while input is ignored.
How am I supposed to check if nyx
even launched without a password or not??
I've typed fg
and now I can type the nyx
password.
So I type the password and press Enter but nothing happens. I can see no input.
When I use jobs
command, I get no output in return.
What's wrong?
- Shift+PgUp writes
2~
on the command line instead of scrolling, - Ctrl+Shift+↑ writes
A
on the command line instead of scrolling, - Terminal on my home laptop shows only 24 rows, no matter what command I'll throw at it:
history
shows only 24 rows;cat -n /home/rafal/nohup.out
or another command with a long output,px -aux
shows only 24 rows;
- The scrollbar on the right fills the entire vertical height of the window, indicating that there's nothing to scroll back to, while there are actually hundreds of lines above;
- Turning the mouse wheel cycles the current line through my command history (same as UP key) instead of scrolling.
- Of course I have 10 000 lines set in my
gnome_terminal
settings.
The question
Can you please tell me what exactly happened and what ignoring input
means and why nohup
ignores input by default??
rafal@debian:~$ nohup nyx &
[1] 4532
rafal@debian:~$ nohup: ignoring input and appending output to 'nohup.out'
I'm not using tmux
.
In order to reinitialize the terminal, I've used reset
to fix this.
And it did fix terminal.
Now after I use px -aux
command I get full window height of lines like so:
Can you please explain to me, what am I doing wrong with this nohup nyx &
command, that it's not working the way I expect it to??
nohup.out
in the current working directory and you should be able to read it as it's added with something liketail -f nohup.out
vim
switch the terminal to use an alternate screen buffer, so that you get your original screen back when it exits — but if it aborts/crashes without restoring the original buffer, the terminal can behave strangely. (One workaround is simply to start and then exitvim
.)