10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi Team,
I have written the shell script which returns the result of the disk space filesystems which has crossed the threshold limit in HTML Format. Below mentioned is the script which worked perfectly on QA system.
df -h | awk -v host=`hostname` '
BEGIN {
print "<table border="4"... (13 Replies)
Discussion started by: Harihsun
13 Replies
2. Shell Programming and Scripting
There's probably a better way to do what I'm doing and if so, let me know an alternative.
I have a script that runs rsh for every entry in a txt file to go get the file size off the remote server. I then compare the remote size with a local size.
My script worked fine until recently when I... (2 Replies)
Discussion started by: olds97_lss
2 Replies
3. Solaris
i am using solaris 8.
i can access my server through telnet.
but not able to access rsh or rlogin.
i can rsh from this server to another machine but not from other machine to this machine.
How to start rsh service.
i have restarted inetd.
pkill -HUP inetd.
thanks (1 Reply)
Discussion started by: sunnybee
1 Replies
4. Solaris
Hi there
I have a strange scenario whereby I am trying to use the -n flag (or < /dev/null) to the input of between two particular hosts which doesn't seem to work, but is fine if between two other hosts
First test (between myhost 1 and 2) -n doesn't return output
test@myhost1% rsh... (1 Reply)
Discussion started by: rethink
1 Replies
5. AIX
Two boxes we just reloaded to use as a two node HACMP cluster to insure our software is compatible.
Install disks we received at our library on 5/2009 AIX 5.3-ML10
For sake of argument names ibmaix1 and ibmaix2
On both:
ibmaix1# oslevel -r
5300-10
.rhosts files with 600 permissions... (0 Replies)
Discussion started by: DrKillPatient
0 Replies
6. Solaris
rsh is not working
command:rsh targethost -l username command
Error:Connection refused
I checked on the server rshd was not working.
Tried to start by /usr/sbin/in.rshd start
# ./in.rshd start
rshd: getpeername: Socket operation on non-socket
Please help (1 Reply)
Discussion started by: aneita
1 Replies
7. Shell Programming and Scripting
Hi,
root@air01a>SS7Manager -status
This command gives correct output. But when I write this in script and run it on SUNMC (which can connect to air01 and by default login as root). It gives the error "SS7manager not found" or "can not open". Here is the scripts.
#!/bin/sh
rsh air01a... (4 Replies)
Discussion started by: lastkey
4 Replies
8. AIX
Hi all
I have updated my .rhosts file as per the norm, however for some reason on hostA I cannot rsh to hostB.
The entries on /.rhosts on hostA are as follows :-
hostB +
hostB on the other can do rsh without a problem.
Any ideas ? :confused: (1 Reply)
Discussion started by: jhansrod
1 Replies
9. Shell Programming and Scripting
Hi,
From one of the unix servers i want execute an rsh command to 5 different servers.
i want to go to these servers execute a command and come back.
i have a main program which calls a function, where in i use the rsh command.
The server name is passed as a parameter to teh function.
it is... (3 Replies)
Discussion started by: praphul
3 Replies
10. UNIX for Dummies Questions & Answers
Dear all;
I have to Unix servers SUM1 and SUM2 running Reliant Unix 5.45
on both servers i have a system user called "netop".
i want netop on SUM1 to execute rsh from SUM1 to SUM2.
What i did, i put in the .rhosts file in the home directory of netop on SUM2 the following entry:
netop ... (2 Replies)
Discussion started by: bcheaib
2 Replies
rsh(1) General Commands Manual rsh(1)
NAME
rsh - Executes the specified command at the remote host or logs into a remote host
SYNOPSIS
rsh [-dn] [-l user] remote_host [command] [argument...]
The remote shell command (rsh) executes command at the remote_host, or, if no command is specified, logs into remote_host.
OPTIONS
Turns on socket debugging (using setsockopt()) on the TCP sockets used for communication with the remote host. Specifies that rsh is to
log into the remote host as user instead of the local username. If this option is not specified, the local and remote usernames are the
same. Specifies that rsh is to ignore input from STDIN. Use this option if you put rsh in the background without redirecting its input
away from the terminal. If you do not use this option in this situation, rsh blocks even if no reads are posted by the remote command.
DESCRIPTION
The rsh command sends standard input from the local host to the remote command and receives standard output and standard error from the
remote command. If you do not specify a command, rsh executes rlogin instead.
If you do not specify the -l option, the local username is used at the remote host. If -l user is entered, the specified username is used
at the remote host. In either case, the remote host allows access only if at least one of the following conditions is satisfied: The local
user ID is not superuser, and the name of the local host is listed as an equivalent host in the remote /etc/hosts.equiv file. If either
the local user ID is superuser or the check of /etc/hosts.equiv fails, the remote user's home directory must contain a $HOME/.rhosts file
that lists the local host and username.
For security reasons, any $HOME/.rhosts file must be owned by either the remote user or the root user, and should have permissions set to
600 (read and write by owner only).
In addition to the preceding conditions, rsh also allows access to the remote host if the remote user account does not have a password
defined. However, for security reasons, use of a password on all user accounts is recommended.
While the remote command is executing, pressing the Interrupt, Terminate, or Quit key sequences sends the corresponding signal to the
remote process. However, pressing the Stop key sequence stops only the local process. Normally, when the remote command terminates, the
local rsh process terminates.
To have shell metacharacters interpreted on the remote host, place the metacharacters inside (double quotes). Otherwise, the metacharac-
ters are interpreted by the local shell.
RESTRICTIONS
The rsh command is confused by output generated by commands in a file on the remote host. In particular, the messages, where are you? and
stty: Can't assign requested address can result if output is generated by the startup file.
EXAMPLES
In the following examples, the local host host1 is listed in the /etc/hosts.equiv file at the remote host host2. To check the amount of
free disk space on the remote host host2, enter: $ rsh host2 df To append a remote file to another file on the remote host, place the >>
metacharacters in (double quotes): $ rsh host2 cat test1 ">>" test2 To append a remote file at the remote host to a local file, omit the
double quotes: $ rsh host2 cat test2 >> test3 To append a remote file to a local file and use a remote user's permissions at the remote
host, use the -l option: $ rsh host2 -l jane cat test4 >> test5
FILES
Specifies remote hosts from which users can execute commands on the local host (provided these users have an account on the local host).
Specifies remote users that can use a local user account.
SEE ALSO
Commands: rcp(1), rlogin(1), rshd(8), telnet(1)
Functions: rexec(3)
Files: rhosts(4)
rsh(1)