Recently, I needed to run some commands in the background and, like a true terminal veteran, I thought: “Perfect, I’ll just use screen
.” Ah, the innocence. ๐
Turns out, on RHEL 8, screen
is basically ancient, because according to Red Hat, it “uses obsolete code.” Of course! And I’m only finding this out now, when I actually need it? Perfect timing, as always.
After reading it in a RedHat KN, I couldn't believe it.
I reminded myself tmux
. And honestly… it’s not bad at all. Even has more tricks than screen.
Here’s a mini tutorial to get you out of trouble:
Install tmux
Create a new session
-
my_session
→ session name
Detach while keeping everything running
Reattach to a session
Run a command directly in the background
Useful commands inside tmux
-
Create a new window:
Ctrl + b
→c
-
Switch window:
Ctrl + b
→n
(next) /p
(previous) -
Close window:
exit
orCtrl + d
๐ก Tip: If you were using screen -S name -d -m command
, in tmux it’s:
Pretty much the same, but without feeling like you’re using a digital fossil.
Moral of the story: sometimes technology evolves faster than our sysadmin ego. And yes, laughing at yourself is mandatory when you realize your beloved screen
is “retro” and the modern world answers to tmux
. ๐