logging to remote server


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting logging to remote server
# 1  
Old 02-21-2006
logging to remote server

Hi,

I want to log-in to a remote server using shell script.

The server requires the following while allowing a connection:

username
password
one - letter authorisation.

How can i implement this in my script?

thanks,

abey
# 2  
Old 02-21-2006
try man page for ftp or rlogin.

for ftp use syntax as
export FTP_HOST=
export FTP_UID=
export FTP_PWD=
export FTP_DIR=

ftp -n << EOF!
open ${FTP_HOST}
user ${FTP_UID} ${FTP_PWD}

commands
quit
EOF!


Regards,
Manish Jha
# 3  
Old 02-21-2006
Thanks for replying..

The reason i need to log in to the server is to run a script in it. so ftp wont work rite. please let me know if there is any other way.


thanks

abey
# 4  
Old 02-21-2006
Quote:
Originally Posted by abey
The reason i need to log in to the server is to run a script in it.
abey
to run a script in remote server,

you can check for
rsh,
ssh
# 5  
Old 02-21-2006
Many thanks..

I'm using HP-UX 11, it seems like this doesn't support rsh and ssh. I didn't find a man entry for these commands. Hope there is some other way for running scripts in a remote machine.


thanks
abey
# 6  
Old 03-21-2006
Running jobs remotely

If you're using HP-UX you should have remsh available. The "remsh" allows you to access remote machines, assuming you have authority to do so, and
execute programs, commands et al. You should examine the man page for remsh, you should find it useful.

Good luck!
Smilie
# 7  
Old 03-21-2006
As mr-synapse told you
HP-UX has the remsh command.
Albeit, I would advise you to use SSH instead.
Nowadays no r* commands should be used anymore
becuase passwords are transmitted in clear text.
You can download the HP-UX SSH port as ready bundeled depot from here
http://h20293.www2.hp.com/portal/swd...Number=T1471AA
and simply install it via swinstall
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Script connect to remote server, not find files and exit only from remote server, but not from scrip

I have a script, which connecting to remote server and first checks, if the files are there by timestamp. If not I want the script exit without error. Below is a code TARFILE=${NAME}.tar TARGZFILE=${NAME}.tar.gz ssh ${DESTSERVNAME} 'cd /export/home/iciprod/download/let/monthly;... (3 Replies)
Discussion started by: digioleg54
3 Replies

2. Shell Programming and Scripting

Sudo connect to a remote server and execute scripts in remote server

Hello Every one!! I am trying to write a shell script which will connect to a remote server and execute scripts which are at a certain path in the remote server. Before this I am using a sudo command to change the user. The place where I am stuck is, I am able to connect to the... (6 Replies)
Discussion started by: masubram
6 Replies

3. Linux

Syslog not logging successful logging while unlocking server's console

When unlocking a Linux server's console there's no event indicating successful logging Is there a way I can fix this ? I have the following in my rsyslog.conf auth.info /var/log/secure authpriv.info /var/log/secure (1 Reply)
Discussion started by: walterthered
1 Replies

4. Shell Programming and Scripting

How to login with other set of credentials while remote logging?

Below is the code. I need to login into the router if the 1st set of credentials are correct.. if wrong... then it has to check with 2nd set of credentials.. => if the credentials are correct... then it should continue.. => if the credentials are wrong(should not check for 2nd time... then... (0 Replies)
Discussion started by: scriptscript
0 Replies

5. AIX

Remote Script command logging question

I've noticed that when running a script that connects to a number of our servers (to essentially run batch commands) that the commands aren't logged in the user's .sh_history or .bash_history files. Is there a place where this is logged (assuming the script itself isn't doing the logging and I'm... (3 Replies)
Discussion started by: kneemoe
3 Replies

6. SCO

sco remote logging problem

Hello, I am trying to write log from sco box to a remote host. We already have that setting working for linux server using syslog. With this setting(on LINUX) *.* @remote-host for sco I have this *.debug /usr/adm/syslog *.* ... (3 Replies)
Discussion started by: polestar
3 Replies

7. Solaris

Logging remote telnet sessions via script

Hi, My requirement - for security purpose - I want all root logins to my solaris servers are done by a script kept in a separate unix box. This script will telnet into remote solaris server with root user and log every session via log file. Now my purpose is to log every telnet session... (3 Replies)
Discussion started by: rahul_jain250
3 Replies

8. AIX

how to configure ssh2 for not asking password when logging from remote

Hi gurus, I am trying to configure ssh2 for not asking passwords when logging in from a remote machine, but it is failing. I ran the command based on the oracle documentation. down below are the steps, please do let me know how to get this solved. the steps followed $ /usr/bin/ssh-keygen2 -t dsa... (1 Reply)
Discussion started by: arunrao_oradba
1 Replies

9. Shell Programming and Scripting

Problem with logging into remote host

Hi All, I am using a script for remotely logging into a rhost using telnet and shutdown a server. The script is as follows. IP = 10.24.12.23; export IP UNAME = username ; export UNAME PWD = password; export PWD CRDIR = /etc/rc.d/init.d ; export CRDIR echo "logging into remote... (4 Replies)
Discussion started by: patil_reddy
4 Replies

10. UNIX for Dummies Questions & Answers

Delay when logging in remote

Hello again! When I log in to my computer (Ultra 5 running Solaris 8) from a pc (FTP or Telnet) I have to wait forever (about 30 seconds) before I can log in. Is this some kind of security thing? Can I turn it of? How? Anders (8 Replies)
Discussion started by: alfabetman
8 Replies
Login or Register to Ask a Question