Re: using "at" and ssh
- From: Anonymous <cripto@xxxxxxx>
- Date: Mon, 2 Jan 2006 09:20:45 +0100 (CET)
> Cloud Burst <DoNotReplyViaEmail@xxxxxxxxxxx> wrote:
> This is great stuff. Thanks a lot.
> Almost there, but I still have one problem. I can't seem to get what I
> put in the background to work properly. For example, I have a little
> test script called foo that looks like this:
>
> % cat foo
> ssh myhost ls
>
> Then if I do this:
>
> % ./foo > ls.txt
>
> ...works fine. But:
>
> % ./foo > ls.txt &
>
> ...doesn't. It is immediately stopped by bash. I then have to "fg" it
> and press the Enter key. It then runs.
>
> I tried this with my big script and
>
> What I REALLY want to do is run my job like this: "nohup mybigjob &" but
> it behaves the same way. It runs fine until it gets to the first command
> that uses ssh. It is then stopped by bash, I have to put in foreground
> and hit the Enter key. It then takes off and the command succeeds, as
> well as all the rest of the commands in the script that use ssh.
>
> Is there a way around this?
Try:
ssh -n myhost ls > ls.txt &
.
- Follow-Ups:
- Re: using "at" and ssh
- From: Cloud Burst
- Re: using "at" and ssh
- References:
- Re: using "at" and ssh
- From: Cloud Burst
- Re: using "at" and ssh
- Prev by Date: Re: using "at" and ssh
- Next by Date: Re: using "at" and ssh
- Previous by thread: Re: using "at" and ssh
- Next by thread: Re: using "at" and ssh
- Index(es):
Relevant Pages
|
|