Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Connect server France from vps Singapore
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

Connect server France from vps Singapore

I have server A, I have VPS B,

I want all traffic from custom port at server A will redirect to my VPS B

How to make my vps B connect to my server A ?

VPN ?

and how client can connect to vps B?

Comments

  • Sounds like a fitting job for a proxy? Try something simple like Caddy for the start.

  • rm_rm_ IPv6 Advocate, Veteran

    mrlongshen said: How to make my vps B connect to my server A ?

    Using TCP/IP is an option.

  • Redirect with a 301/302 http status?

  • WSSWSS Member

    @rm_ said:

    mrlongshen said: How to make my vps B connect to my server A ?

    Using TCP/IP is an option.

    Witchcraft.

  • The answer of your question is hidden in your 2nd sentence. And nothing else matters.

  • freerangecloudfreerangecloud Member, Patron Provider

    You could make a dstnat rule in iptables to redirect the traffic.

  • @erkin said:
    The answer of your question is hidden in your 2nd sentence. And nothing else matters.

    Can show some?

  • Are you setting this up to get better routing?

  • @freerangecloud said:
    You could make a dstnat rule in iptables to redirect the traffic.

    Any other method?

  • @dahartigan said:
    Are you setting this up to get better routing?

    Yeah. True. Since vps to vps connection much faster. So i can reduce the latency. Imagine 1gbps connect with 1gbps. Sure fast. Hehe. I dont mind using my singapore traffic. I got 1tera traffic.

  • I think a SSH reverse proxy is what you're wanting here. Someone connects to server A on a port, and it will tunnel from server A to server B (using their network) via SSH to server B's port.

    Does that sound right?

  • @dahartigan said:
    I think a SSH reverse proxy is what you're wanting here. Someone connects to server A on a port, and it will tunnel from server A to server B (using their network) via SSH to server B's port.

    Does that sound right?

    @freerangecloud said:
    You could make a dstnat rule in iptables to redirect the traffic.

    How ya? I believe like freeorange method.

  • ssh -nNT -R PORT:VPSA:PORT VPS2

    Example

    ssh -nNT -R 1111:11.22.33.44:2222 44.33.22.11

    That would mean you go to 11.22.33.44:1111 and it would tunnel to 44.33.22.11:2222

  • @dahartigan said:
    ssh -nNT -R PORT:VPSA:PORT VPS2

    Example

    ssh -nNT -R 1111:11.22.33.44:2222 44.33.22.11

    That would mean you go to 11.22.33.44:1111 and it would tunnel to 44.33.22.11:2222

    Where should I do this ?

  • Cannot. I try this. connection refused.
    my vps have port 22 ssh
    my dedicated have port 33 ssh

  • gxc434gxc434 Member
    edited March 2018

    I recommend you to use very powerful tool socat. For example if your server has ip 10.100.0.1 and your vps has 10.200.0.1 and you want to access server's ssh service via vps, run this command on vps:

    socat TCP4-LISTEN:2222,fork,su=nobody TCP4:10.100.0.1:22

    Now you can connect to 10.200.0.1:2222 and socat will proxify your traffic to 10.100.0.1:22

    Thanked by 1dahartigan
Sign In or Register to comment.