[General] screen command or a replacement

Abdulaziz AL-Asfour aasfour at gmail.com
Mon Dec 25 20:54:12 +03 2006


Salam Alaykom all..

Thanks to Bashar and Sabah..

I don't know why I thought losing a connection before pressing ^AD would cuz
also losing that session... maybe i did something wrong in the past... or
maybe there was a network problem causing both the screen and command
running beneath to stop as brother Sabah mentioned.

I just tested the following

   - screen commandhere

and

   - screen
   - Enter
   - command

All allowed me to resume the connection after manually closing the
terminal...

After having several tests..

I just tested it on a production server (which has a screen running the appz
) .... I have to admit it, I was kinda scared to lose the session .. but
al7amdollah the screen is back after "screen -r"....    :)

I also found the script command interesting :)

Thanks all for the feedback....

And it's nice to see the start of "technical questions" with quick
feedback..... I think it is much faster than linuxforum.com..

Lazim asawee da3ayah :)

See ya guyz tomorrow inshallah

On 12/25/06, Eng. Sabah Al-Sabah <sabah at techsys.net> wrote:
>
>  Hi,
>
> I agree with Bashar,
>
> If you create a screen and then run your command and after that if you
> loose you connection to your host, you can alway login again and attach to
> your previous screen session. you process that was launched during the last
> connection should still continue to run.
>
> However it is possible that the same network problem that make you lose
> the screen connection may also be responsible for the interruption of the
> commad (ie wget) !!!
>
> I never tried passing the commad as an argument to screen!
>
>
>
>
>
>
>
> Best Regards,
>
> ============================
>
> Eng. Sabah Al-Sabah
>
> General Manager
>
> Technical Systems Est.
>
> sabah at techsys.net
>
> www.techsys.net
>
> ============================
>
>  -----Original Message-----
> *From:* general-bounces at oskw.org [mailto:general-bounces at oskw.org] *On
> Behalf Of *Bashar Al-Abdulhadi
> *Sent:* Monday, December 25, 2006 5:33 PM
> *To:* General OpenSource Discussion
> *Subject:* Re: [General] screen command or a replacement
>
> W'salaam Abdulaziz,
>
> although your session shouldn't be lost if your terminal dies before
> pressing ^AD but i noticed "some" applications (not copy or wget) dies if
> you dont press ^AD before your terminal dies, anyhow what i thought of is:
>
> # screen
>
> # script -t 0 monitor.txt
>
> # ^AD
>
> # tail -f monitor.txt
>
> man script for more flags
>
>
> and for dying maybe cause you are running `screen commandgoeshere` not
> running `screen` then hitting enter then `commandgoeshere` ?
>
>
>
> Abdulaziz AL-Asfour wrote:
>
> Salamu Alaykom...
>
> To all *nix experts:
>
> For example you want to download or copy a big file ... or you want to
> start any command using the terminal (from a remote PC):
>
>
>    - You want to see the output of this command
>    - While seeing the output, if the session gets disconnected, you do
>    not want to interrupt the operation (Coping or viewing the output of the
>    command)
>
> If i do:
>
>    - screen /opt/application/bin/server
>
> or
>
>    - screen wget url.tar
>
> If there is a network problem and your terminal gets disconnected before
> pressing (Ctrl-A-D), you will lose your session (Correct me if I am wrong)
>
> I do not want that to happen.... and I want at the same time to view the
> output of the executed command (Maybe putting it in the background won't do
> the trick also)....
>
> Any tips, shabab? :)
>
> ------------------------------
>
> _______________________________________________
> General mailing list
> General at oskw.orghttp://mail.oskw.org/mailman/listinfo/general_oskw.org
>
>
> _______________________________________________
> General mailing list
> General at oskw.org
> http://mail.oskw.org/mailman/listinfo/general_oskw.org
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://oskw.org/pipermail/general_oskw.org/attachments/20061225/4a18e167/attachment.html>


More information about the General mailing list