Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Remote access and control
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Off the Wall
View previous topic :: View next topic  
Author Message
+BroNNoS+
n00b
n00b


Joined: 17 Apr 2002
Posts: 46
Location: Groningen, The Netherlands

PostPosted: Wed May 01, 2002 12:06 pm    Post subject: Remote access and control Reply with quote

Hi all,

Maybe a bit lazy question but I'm just wondering:
When I start a compilation in the morning before I go to my work, can I follow the progress via a remote connection (or inet) and take over control if neccesary? This because an emerge of for instance KDE takes a long time and if it failes 5 min after I left my home it would be nice if I can start it again after the neccesary hacks.

I know you can remotely connect with ssh, but what about the output. That is already going to my terminal. And do I need to do somethings special to get through my freesco router to my Gentoo box.

Any thougts and help will be appreciated
Back to top
View user's profile Send private message
klieber
Administrator
Administrator


Joined: 17 Apr 2002
Posts: 3657
Location: San Francisco, CA

PostPosted: Wed May 01, 2002 12:16 pm    Post subject: Re: Remote access and control Reply with quote

+BroNNoS+ wrote:

Maybe a bit lazy question but I'm just wondering:
When I start a compilation in the morning before I go to my work, can I follow the progress via a remote connection (or inet) and take over control if neccesary? This because an emerge of for instance KDE takes a long time and if it failes 5 min after I left my home it would be nice if I can start it again after the neccesary hacks.


Well, you should be able to output the results of an emerge to a file somewhere -- you could then ssh in and check the results of that file. That's probably the easiest way to do it.

I'm sure you could also get fancy and write a script that checked the exit code of the emerge and, if it wasn't what you wanted, fire off an email to you, but that's a bit more work. :)

If you already have some sort of GUI running, you could use something like VNC to connect remotely to your machine. That would allow you to start an emerge in Konsole and check it remotely using VNC.

+BroNNoS+ wrote:

And do I need to do somethings special to get through my freesco router to my Gentoo box.


Yes, you need to open the appropriate TCP or UDP port so it will accept inbound connections. Which port depends on what remote access solution you end up using. SSH is TCP port 22. VNC is (I think) UDP 5100, but that's a SWAG.

--kurt
_________________
The problem with political jokes is that they get elected
Back to top
View user's profile Send private message
+BroNNoS+
n00b
n00b


Joined: 17 Apr 2002
Posts: 46
Location: Groningen, The Netherlands

PostPosted: Thu May 02, 2002 3:47 pm    Post subject: Reply with quote

Ok, thanks. I worked on it:
Got to the stage that I can ssh to my Gentoo box through my Freesco box with port forwarding on port 22. Should be enough to remotely fire of an emerge. Still got the problem of loosing the output from the emerge when I disconnect. But redirecting output to a file should do the trick.

I tried VNC as well and it does work within my home network. But through my Freesco box it still doesn't. Got port forwarding on 5900 and 5901 (just to be sure) and my vncserver is running on 5901. But if I connect with the vncviewer on 'ipadres':1 it does not connect. Treid fiddeling around with Freesco and vnc via ssh etc but without result so far.

Any suggestions? Is there any logging going on so that I can check somewhere what the return message is from my Freesco box?

Thanks.
Back to top
View user's profile Send private message
klieber
Administrator
Administrator


Joined: 17 Apr 2002
Posts: 3657
Location: San Francisco, CA

PostPosted: Thu May 02, 2002 4:09 pm    Post subject: Reply with quote

+BroNNoS+ wrote:
Any suggestions?


Actually, I should have mentioned this originally -- running VNC over an open network (like the internet) is a Bad Idea. VNC has very little security built into it and is relatively easy to hack.

The good news is that you can run VNC in an ssh tunnel, which gives you the best of both worlds -- a secure connection and a candy-coated interface. :)

You can get more information on how to set this up here. Plus, since you already have ssh working through your freesco box, this should be (hopefully) easier to set up.

--kurt
_________________
The problem with political jokes is that they get elected
Back to top
View user's profile Send private message
+BroNNoS+
n00b
n00b


Joined: 17 Apr 2002
Posts: 46
Location: Groningen, The Netherlands

PostPosted: Thu May 02, 2002 4:24 pm    Post subject: Reply with quote

thanks for the quick reply:

Completely agree, but I've of course been there and read all the stuf:

> vncviewer snoopy:1
>
>you could run:
>
> vncviewer localhost:2
>
> and you get the same effect, but with a secure connection.

(we love the last bit) but either way it does not work. Personally I think it has to do something with Freesco, but I'm not sure because port forwarding is on, and I managed to get ssh running.
Back to top
View user's profile Send private message
klieber
Administrator
Administrator


Joined: 17 Apr 2002
Posts: 3657
Location: San Francisco, CA

PostPosted: Thu May 02, 2002 4:45 pm    Post subject: Reply with quote

+BroNNoS+ wrote:
(we love the last bit) but either way it does not work. Personally I think it has to do something with Freesco, but I'm not sure because port forwarding is on, and I managed to get ssh running.


Well, you should be able to narrow down the cause of the problem by doing (on your Gentoo box):

Code:
netstat --numeric-ports -l


which will show you what ports are listening. If everything seems fine there (which it probably is because you said it works fine locally) then yes, I'd agree that your freesco box is suspect. Never touched freesco before, so I can't be of much help, but there should be some way to monitor incoming/outgoing connections so you can see what is being allowed in/out. My guess is it isn't configured correctly to allow inbound 59xx.

You could also try launching VNC on port 22 and seeing if you can then connect since you know inbound port 22 is working.

And, finally, there's always the VNC FAQ:

Quote:

Q20 My viewer failed to connect to my server!
VNC relies on a correctly-configured and operational TCP/IP network, so please make 100% sure that your TCP/IP setup is right before you start asking questions on the mailing list. Here are some things you should check before assuming it's a VNC problem; consult your local expert if you don't know how to check them:

Can you ping the server machine from the client?
Is the VNC server definitely running on the server machine?
The server listens on port 5900+displaynumber. Can you telnet to this port from the client machine?
Have you specified the address correctly to the viewer? If you're using a display number other than zero for the server, (usually the case on Unix machines), did you remember to specify it?
Is the server name known to the DNS? Try using an explicit IP address instead of a name (eg. 123.456.78.9:0 instead of snoopy:0).
Do you have any firewalls or proxies in the way that could be blocking acess?
If using the java client, did you remember to specify the correct port as part of the URL? (eg. http://snoopy:5800)?
Can you try running either the server, or the client, or both, on different machines on your network to find whether the problem is at one end or the other?
Can you try running the software on a different architecture? eg., if you are having problems viewing a PC from another PC, can you try connecting from a Unix machine?


--kurt
_________________
The problem with political jokes is that they get elected
Back to top
View user's profile Send private message
+BroNNoS+
n00b
n00b


Joined: 17 Apr 2002
Posts: 46
Location: Groningen, The Netherlands

PostPosted: Thu May 02, 2002 8:40 pm    Post subject: Reply with quote

Solved! :-)
What I did wrong with the tunneling is that I thought you had to do ssh forwarding from the freesco box but actually you have to use the ip from you box behind the firewall. Afterwards it always seems logical. I've connected with ssh through the firewall directly to my Gentoo box. So in that environment the port forwarding takes place and not on the freesco box. So those ports can be closed again (except for the ssh one of course). And now I completely understand the power of this method :-).

For anyone who is interested, this was the website I got it from, and it was damn hard to find (but is was fun!).

http://drvandv.com/freesco/VNC
_________________
Box said "Requires Windows 98 or better". So I installed Linux...
Back to top
View user's profile Send private message
zom
Guest





PostPosted: Fri May 10, 2002 7:49 pm    Post subject: Reply with quote

You could always just screen the emerge, that way you can ssh in and connect to the screen...
Back to top
DArtagnan
l33t
l33t


Joined: 30 Apr 2002
Posts: 942
Location: Israel, Jerusalem

PostPosted: Tue May 21, 2002 10:00 am    Post subject: Reply with quote

Nice, but what is happening if the target computer is behind a firewall?
I mean, at home my computer is connected via adsl to some crazy ISP that just hides the clients...:-(
_________________
All for one and one for All
--

MACPRO machine...
Back to top
View user's profile Send private message
klieber
Administrator
Administrator


Joined: 17 Apr 2002
Posts: 3657
Location: San Francisco, CA

PostPosted: Tue May 21, 2002 11:27 am    Post subject: Reply with quote

pacman wrote:
Nice, but what is happening if the target computer is behind a firewall?


If you have access to that firewall, you can punch a hole through it to allow whatever traffic you want. If you don't have access to the firewall, you can run whatever service you want (ssh, vnc, etc.) over a different port that is open on the firewall (tcp 80 is generally a safe one)

--kurt
_________________
The problem with political jokes is that they get elected
Back to top
View user's profile Send private message
DArtagnan
l33t
l33t


Joined: 30 Apr 2002
Posts: 942
Location: Israel, Jerusalem

PostPosted: Tue May 21, 2002 12:18 pm    Post subject: Reply with quote

The problem is that my coputer from home is realy hidden!!!
It does not respond even for ping...
I don't know, maybe u know some way to pass it?
_________________
All for one and one for All
--

MACPRO machine...
Back to top
View user's profile Send private message
klieber
Administrator
Administrator


Joined: 17 Apr 2002
Posts: 3657
Location: San Francisco, CA

PostPosted: Tue May 21, 2002 12:42 pm    Post subject: Reply with quote

pacman wrote:
The problem is that my coputer from home is realy hidden!!!
It does not respond even for ping...


It could be any number of things and there could be any number of ways to bypass it. You need to provide a bit more information about the way your ISP has their network configured. Are they using NAT? Is there a firewall involved? What have you tried so far?


--kurt
_________________
The problem with political jokes is that they get elected
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Off the Wall 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