Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
SSH: keep login active/Login to a previously started session
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
WarMachine
Apprentice
Apprentice


Joined: 15 Jul 2002
Posts: 181

PostPosted: Fri Jul 19, 2002 6:36 am    Post subject: SSH: keep login active/Login to a previously started session Reply with quote

What I'm looking to do is (over ssh) keep my login active even if I close off the connection from the client comptuer (it's windows, so this will most likely be used for reboots). I'd like to log back in and have my processes stilll running and windows, whatnot where they were when I left them before. I hope I'm not asking for a miracle, but anything is possible with *nix.
If it helps I run sshd from openssh's package on the host machine, and ssh.com's free trial client on my client machine.
Back to top
View user's profile Send private message
msteller
n00b
n00b


Joined: 10 May 2002
Posts: 6
Location: Out There Somewhere

PostPosted: Fri Jul 19, 2002 7:41 am    Post subject: Reply with quote

emerge screen

Screen is an application that allows you to create virtual screens in a single terminal session. You can disconnect and re-attach to the previous sreen session later from any new terminal session.

Notes:
screen (starts screen)
ctrl-a c create new virtual screen
ctrl-a ctrl-a swap to previous screen
ctrl-a n swap to next screen
ctrl-a esc arrow up or down thru virtual buffer. esc to exit scrolling.

screen -r (re-attach to disconnected session)
screen -rd (re-attach to session and disconnect connected terminal)
useful if you left your session connected on a remote pc
Back to top
View user's profile Send private message
rizzo
Retired Dev
Retired Dev


Joined: 30 Apr 2002
Posts: 1067
Location: Manitowoc, WI, USA

PostPosted: Fri Jul 19, 2002 2:17 pm    Post subject: Reply with quote

Yes screen is the answer. It has saved me because when I'm at home and my VPN connection disconnects I can just log back in and view my oracle queries in progress.

Just another vote for screen.
Back to top
View user's profile Send private message
WarMachine
Apprentice
Apprentice


Joined: 15 Jul 2002
Posts: 181

PostPosted: Sat Jul 20, 2002 11:56 pm    Post subject: Reply with quote

screen rules, thanks guys :mrgreen:
Back to top
View user's profile Send private message
Riveri
n00b
n00b


Joined: 20 Feb 2004
Posts: 65
Location: Tampere, Finland

PostPosted: Wed Aug 25, 2004 3:38 pm    Post subject: Reply with quote

can i use screen somehow to X programs...

i just keep getting this when i put screen -r

konqueror: Fatal IO error: client killed
ICE default IO error handler doing an exit(), pid = 7323, errno = 32

in that case i was trying to open session where i had konqueror open...


or is there some better prog for this ?
Back to top
View user's profile Send private message
aleks04
n00b
n00b


Joined: 11 Feb 2003
Posts: 13

PostPosted: Wed Aug 25, 2004 6:08 pm    Post subject: Reply with quote

VNC would be my choice for X stuff. For that, instead of running stuff in an X server, you run it in a VNC server, to which you can connect any time and even share connection. Though ofcourse it's not as fast as an X server, it still works pretty well.

One of the versions of VNC out there is TightVNC: http://www.tightvnc.org/
or `emerge tightvnc` .
Back to top
View user's profile Send private message
Riveri
n00b
n00b


Joined: 20 Feb 2004
Posts: 65
Location: Tampere, Finland

PostPosted: Wed Aug 25, 2004 8:40 pm    Post subject: Reply with quote

Thanks!

It works just like i wanted it to work...
Back to top
View user's profile Send private message
wers
n00b
n00b


Joined: 14 May 2007
Posts: 40

PostPosted: Mon Jan 07, 2008 10:16 am    Post subject: Reply with quote

Good day. I wonder what happens when i occasionally close the ssh session which was without screen support? It has 107 packages in recompiling. Is gentoo still working on this task or not? I've already read the putty's faq but couldn't find the answer...
Back to top
View user's profile Send private message
Bio
Apprentice
Apprentice


Joined: 17 Mar 2003
Posts: 197
Location: Geneva which should be in Switzerland...

PostPosted: Mon Jan 07, 2008 7:52 pm    Post subject: Reply with quote

wers wrote:
Good day. I wonder what happens when i occasionally close the ssh session which was without screen support? It has 107 packages in recompiling. Is gentoo still working on this task or not? I've already read the putty's faq but couldn't find the answer...


No your task will end when putty ends.

To avoid that you can launch a task with the nohup (no hang up) tag. iie nohup emerge mypackage

This will ensure your task keeps running even if your ssh session ends abruptly.

The output of the command is logged to a nohup.out file so you can monitor the progress
_________________
I'm all in !
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum