Mailing List Archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [tlug] ssh tunnel in background requires nohup? - take two



Al Hoang wrote:
>     So my questions to TLUG are:
> 1. If you try something similar do you have the same issues?
>   

Yes.

> 2. Is this distro-specific?  I've tested this on Debian Sarge, Ubuntu Feisty 
>    and Ubuntu Dapper so perhaps it is something that is Debian-specific but
>    I don't have enough linux distros available right now to test this thoroughly.
>   

No.

> 3. Why is this happening?  My guess is that the sshd or shell process tied to
>    the machine you are trying to run the ssh tunnel from is waiting for some signal
>    from the ssh tunnel process before it exits.

do the following.

# ssh -f -n -N -L 8080:localhost:80 example@example.com
# lsof |grep [the pid of ssh tunnel]

notice the /dev/pts*.  kill the previous process and do

# ssh -f -n -N -L 8080:localhost:80 example@example.com </dev/null
>/dev/null 2>&1
# exit

Edward


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links