Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Hallo, I'm trying to setup a network that is required to run a program (OpenFOAM), following a described procedure inthe manual, but I have some problems.
The first step is:
OpenFOAM requires a basic level of networking to be set up. Firstly,
the host name must be set - to test, type 'uname -a'. The running
shell must be tcsh, csh, bash or ksh - to test type 'echo $SHELL'
The user must be able to 'ping' the host machine itself (<host>) - to
test, type 'ping -c 1 <host>'
If the ping fails then it is possible that that the entry for the host
machine is missing, incorrect or duplicated in the /etc/hosts
file. The user can check this by typing 'grep <host> /etc/hosts' which
should return a single line, typically of the form:
<IPaddress> <host>.<domain> <host>
The first line should already be there. The second one needs to be added; all you have to do is make up a hostname (MyBox in the example) and a domain name(athome.net, again only an example). If your computer is in a network, you should probably use the same domain name as the one used for the other computers.
As soon as your computer has a hostname, you can ping it:
ping -c3 MyBox
It should send 3 packets and then report that 3 have been received. You can then also test, say, ssh:
The machine must have one of (or both) remote (rsh) and secure shell
(ssh) running on his/her account. To check whether rsh is running
correctly, the user should type 'rsh <host> ls'. Alternatively the
user can check if ssh is running correctly by typing 'ssh <host> ls'.
In either case, the output to the command should produce a
file/directory listing for the current directory and no other text. If
neither command works, we recommend the user set up rsh for their use
Check the rsh executable actually exists, e.g. the path to the
executable should be returned when typing 'which rsh'. Check with the
system administrator that rsh is enabled on the user's account; if
not, request that it is enabled. Create a '.rhosts' file in the $HOME
directory containing entries to access any machines they need to
access, i.e. their own machine and, if different, the licence host
machine. The entries are of the form: '<host> <user>'.
Remote shell accesses the .bashrc (or .cshrc) file and will not run
correctly if there is a problem with this file. In particular the user
should be careful with the following:
The .cshrc (or .bashrc) file should not contain errors that prevent it
from executing fully at startup; all error messages during execution
of the .bashrc (or .cshrc) file should be investigated and acted upon
to eliminate them. echo (print to screen) statements within .bashrc
(or .cshrc) must not be executed during the running of rsh. This does
not mean that echo statements are forbidden from the .cshrc (or
.bashrc) file, but they must be enclosed in a control structure,
e.g. an if statement, that ensures they are not executed when rsh is
executed, e.g. for .bashrc:
if [ "$PS1" ]; then
echo "..."; fi
and, for .cshrc:
if ($?prompt) then ; echo "..." ; endif
When I type 'rsh <host> ls' , I have this message : Connection refused.
What can I do? Is a problem of permission I have to set from the root account?
You need to create an .rhosts file in your home directory that specifies the machines that are allowed to connect to your box through rsh. It should contain their fully qualified domain name (i.e. hostname and domain, as you used it in your /etc/hosts file) - one per line - and optionally, on the same line, the name of the user(s) on each machine who should be allowed in (e.g. root). And have you verified yet that your rsh server is actually running?