?
Solved

Running command in remote machine

Posted on 2003-03-13
7
Medium Priority
?
249 Views
Last Modified: 2013-12-23
I am writing a script to run a command in a remote machine. I tried "rsh" but found out that it was not useful enough for my purpose. Then I tried "rexec" but it didnt work at all, everytime it shows the error "Connection Refused" is there any other method ? or can someone please suggest how to make rexec work ?
0
Comment
Question by:gopubhaskar
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
7 Comments
 
LVL 8

Expert Comment

by:heskyttberg
ID: 8128207
Hi!

I'm not sure if there is an easier way, but with openssh you can do this. But rsh would be easier, I don't understand why you can't use rsh.

http://www.openssh.com/

Regards
/Hans - Erik Skyttberg
0
 
LVL 21

Expert Comment

by:tfewster
ID: 8129369
rexec should prompt you for a password, but that's about the only difference from rsh...
0
 
LVL 38

Accepted Solution

by:
yuzh earned 200 total points
ID: 8132908
To make rsh work, you need to put a .rhosts your home dir (at least in the remote box).

let'say you do it from box1 to box2, the both machine has the same login name. you put a .rhosts under you home dir, the format looks like:

box1-name your-login-name

please check your /etc/inetd.conf file to have in.rshd enable.

Use rsh, rpc is not secure ! I strongly recommended you to set up secure shell (ssh), openssh can be download from the web for your version of OS

http://www.openssh.org/

Cheers!
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 1

Expert Comment

by:Dreamn3d
ID: 8153383
OpenSSH (ssh in general) allows you to you hostbased auth with pre-setup keys.  Kind of tricky the first couple of setups but works great once you learn it.


Jess
0
 
LVL 38

Expert Comment

by:yuzh
ID: 8157397
why a C ?
0
 

Expert Comment

by:modulo
ID: 8159488
Hi gopubhaskar

Please take a moment to read:
http://www.experts-exchange.com/Operating_Systems/WinNT/cmtyQuestAnswer.jsp#3

We value our experts who are investing their time and effort to solve Q's for others. That's why I kindly ask you to read the grading text and add a comment or the grade given fits the description or that I have to make a change.

When no comment has been added within 72 hrs I'll change the grade to an "A"

Thanks !

modulo

Community Support Moderator
Experts Exchange
0
 

Expert Comment

by:modulo
ID: 8182456
changed the grade to an "A"

modulo

Community Support Moderator
Experts Exchange
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article, I am going to show you how to simulate a multi-site Lab environment on a single Hyper-V host. I use this method successfully in my own lab to simulate three fully routed global AD Sites on a Windows 10 Hyper-V host.
This article will inform Clients about common and important expectations from the freelancers (Experts) who are looking at your Gig.
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…
Suggested Courses

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question