Aug 172012
 

After seeing this blog post, it got me wondering how many people are in the same predicament where they can’t see what they are typing on the console session on the Raspberry Pi from another computer.

For me, I’ve almost always used SSH, unless I misconfigure the network adapter before taking everything down (or kill the WiFi dongle…oops). But for some people, they actually have space, and a TV/Monitor that they can use with the Raspberry Pi, and they can sit at the Pi to type away. But what if you want to see what you’ve done on your Pi on another computer ?

If you SSH in after you’ve done everything, you won’t be able to see the history, or what’s running on the console session.
To get around that, you can add the following line to ~/.bashrc, and it will start a screen session if there isn’t one running already, or attach to one that is running.

screen -R

Putting that into ~/.bashrc will ensure that there will always be a screen session running when you logon ( unless you kill it, in which case it will start another screen session when you login again ). Only downside to that, is that if you kill the screen session that the console login is attached to, you’ll need to either start another screen session from the console, or re-attach to a new screen session on the console.

To get out of screen without killing the session, you need to use the key combo CTRL-A and then D
That will detach the screen session without killing it.

Share

 Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

(required)

(required)