Find the answer to your Linux question:
Results 1 to 8 of 8
Hi All, I have two machines in different location, lets say machine A and machine B. Machine A: - Linux Red Hat OS. - Has internet connection (no proxy). - ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Jan 2009
    Posts
    5

    How to connect Linux machine and Windows machine using ssh?



    Hi All,

    I have two machines in different location, lets say machine A and machine B.

    Machine A:
    - Linux Red Hat OS.
    - Has internet connection (no proxy).
    - Has public IP.

    Machine B:
    - Windows XP OS.
    - Has internet connection (with HTTP proxy).
    - Has connection to machine C and machine D. Machine C and D don't have internet connection, but machine B can connect to those machines because machine B, C, and D are located in the same network.

    I need to connect machine C and D via machine A. I heard it can be done using ssh between A and B, but I don't know the details.
    Is there anyone can help me?

    Thanks


  2. #2
    Linux Engineer rcgreen's Avatar
    Join Date
    May 2006
    Location
    the hills
    Posts
    1,134
    Machine A:
    - Linux Red Hat OS.
    - Has internet connection (no proxy).
    - Has public IP.

    Machine B:
    - Windows XP OS.
    - Has internet connection (with HTTP proxy).
    - Has connection to machine C and machine D. Machine C and D don't have internet connection, but machine B can connect to those machines because machine B, C, and D are located in the same network.

    I need to connect machine C and D via machine A. I heard it can be done using ssh between A and B, but I don't know the details.
    Is there anyone can help me?
    If you set up internet connection sharing on Machine B, it becomes the default gateway for machines C and D.

    Then, assuming that machine A has its ssh server exposed to the
    internet, C and D can ssh to it with no problem.

    How to configure Internet Connection Sharing in Windows XP

  3. #3
    Just Joined!
    Join Date
    Jan 2009
    Posts
    5
    Hi rcgreen,

    Thanks for the answer.
    But my requirement is using machine A to telnet/ssh to the machine C and D, not the other way.

    Machine A:
    - Linux Red Hat OS.
    - Has internet connection (no proxy).
    - Has public IP.

    Machine B:
    - Windows XP OS.
    - Has internet connection (with HTTP proxy).
    - Has connection to machine C and machine D. Machine C and D don't have internet connection, but machine B can connect to those machines because machine B, C, and D are located in the same network.


    Machine C and D:
    - Linux Red Hat OS.
    - Don't have internet connection.
    - Has connection to machine B, because located in the same network.

    Any suggestion, so I can use machine A to connect to the machine C or D?

    Thanks

  4. #4
    Linux Engineer rcgreen's Avatar
    Join Date
    May 2006
    Location
    the hills
    Posts
    1,134
    my requirement is using machine A to telnet/ssh to the machine C and D, not the other way
    In that case, set up port forwarding on machine B, to allow
    incoming traffic to C and D

    Server Publishing, sometimes referred to as reverse NAT or port forwarding, is actually the reverse of the NAT that ICS performs for internal network clients. When you publish an internal network server, you’re actually publishing a particular service on that server. You tell ICS to listen on a particular port on the external interface of the ICS machine and forward any messages that are sent to that port to a designated port on the internal network server.
    Windows XP's Internet Connection Sharing opens up client connectivity options with Server Publishing

  5. #5
    Just Joined!
    Join Date
    Jan 2009
    Posts
    5
    Hi rcgreen,

    Sorry, but I'm not clear with your suggestion. Could you help to explain further?

    Btw, machine C and D is a live server, so I can't do any configuration there. I just have machine A and B (with above explanation) as my tools. Basically the final goal is to access (telnet/ssh) server C and D from anywhere.
    For example: I use my laptop from home, access server A (with the public IP), and then access server B (with ssh), and finally I can telnet to server C or D.

    Is it possible to be done? I heard there is ssh method to do this, but I don't know the steps and details. Maybe you can help me?

    Thanks and warm regards.

  6. #6
    Linux Engineer rcgreen's Avatar
    Join Date
    May 2006
    Location
    the hills
    Posts
    1,134
    The last time I did this I was running Win98, so I
    am a little rusty. You need administrative access
    to B at the very least. the link I posted
    explains how to set up ICS on it so that
    it becomes gateway for D and C.

    Since you cannot configure D and C, you
    may wind up frustrated, because, the way it is
    supposed to work, when the servers boot, they
    get their IP addresses from the DHCP server on
    B, and are then able to access the internet.

    Inbound access to the servers can be configured
    with port forwarding. Apparently, Microsoft calls
    this Server Publishing. All of this can be
    configured on machine B, but if the servers
    do not look to B as their gateway, you will
    not get access. If you are not permitted to configure
    them, maybe it is a lost cause.

  7. #7
    Just Joined!
    Join Date
    Jan 2009
    Posts
    5
    I see.
    Anyway thanks a lot for ur suggestion . I will try to search another method

  8. #8
    Just Joined!
    Join Date
    Apr 2008
    Posts
    36
    Here's what I did. Don't know if it will help you because I connected Ubuntu to windows over a LAN.
    I installed putty (that's an ssh client) on my windows XP computer.
    Then I installed the ssh server package in ubuntu.

    Then, all you have to do is run putty from the windows computer and enter the IP adress of the linux computer and you can connect.
    You can also get graphical interfaces using X over ssh.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •