I have a script which connects to different database servers using sqlplus. Is there a way by which I can run a shell command on that host from sqlplus?
I know about 'host' command but it runs script on the local machine where the original script is running. Is there a way to run command on the remote host to which I am connection thru sqlplus.
I have a script that connects to different databases using sqlplus. It basically pulls rows from all the different servers and creates a repository in a single table on host machine.
Apart from pulling information from each database, I also want a script to get executed on the OS where the database reside.
If rsh and remsh are "turned off" then, no. Not without privilege.
You do realize that you can access all of the remote Oracle servers without physically running your sql code on those servers. In other words, you can write a block of code on boxa, that runs on boxa, that accesses, in turn, all of the remote Oracle instances that you need to query. You never leave boxa, where you have to run your script.
Ask your DBA to set up tnsnames and make a few other other changes so you can do that. This is standard Oracle. You may already be able to do that now, so ask your DBA "how to"
Without remsh or rexec or whatever, you have to login to each box and run the shell command. You do know there are DBMS packages that do a lot things. What does your the script on each remote box do?
...and Oracle can be configured to execute external procedures from a PL/SQL procedure call. The calls can be made from sqlplus, Java, a windows GUI, etc.