Bind a remote server's port to a local port

If you have a remote server (say in Amazon EC2) you might want to access a particular port of that server. But there can be situations where it is not that port is not globally open. If you do not want to bother making it globally open you can use it by binding it to a local port of your workstation via ssh. Following command will bind port 9000 of remote machine to your local port 8000.  As an example if it is web server you can easily access it by typing localhost:8000 in your web browser.

ssh -L 8000:localhost:9000 username@host

Comments

Popular posts from this blog

Fixing Error "Failed to load VMMR0.r0 (VERR_SUPLIB_WORLD_WRITABLE)" in Virtualbox

Create new Java Class files at runtime

Using iReport plugin for Jasper Reports in Netbeans