1

I have a serial modem connected to a computer running ubuntu. I can access it through ssh and modem is working great, I tested it using minicom.

How can I make a remote connection to this modem for development purposes?. By the way, my development computer is running a MacOS X 10.6.4 and my intention is to test my java classes without having to redeploy with each test.

2
  • You mean that you want to dial from a modem to another modem like in the old times?
    – LatinSuD
    Sep 24, 2010 at 22:24
  • No, I just want to see the input and output from the modem to my development computer and make that my java class, read and write the data.
    – user55238
    Sep 25, 2010 at 6:36

2 Answers 2

0

Instead of exposing the modem to the internet. What you need to do is to sent all commands you want to execute thru ssh.

You can do:

ssh -t USER@SERVER 'sudo minicom'

the t option is required since minicom is a screen-based program.


Developing in Java

If you are doing a java development what I would do instead on caling "Runtime.getRuntime().exec("COMMAND")".
Have a class that understand when is running on the developer machine or the actual computer. That way you can call that class with the command that you want to execute. When the projects runs on the developer you can 'encapsulate' the execution with an ssh program like.

Runtime.getRuntime().exec(ssh USER@SERVER 'COMMAND')


Considerations about remotly executing commands without password

  • Do an ssh connection relaying on a public/private key authentication. That way you dont need to enter the password manually on each command sent.

  • Since you are using Ubuntu, if you need to run commands with the sudo modifier have the user you use to connect ssh in /etc/sudoers declared as so: USER ALL= NOPASSWD:ALL

0

If your Ubuntu is running GNOME, then you can set it up for "Remote Desktop" (a.k.a. VNC server) access and then access it remotely via "Remote Desktop Viewer" (a.k.a. VNC client).

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .