Connecting from UNIX

I need to connect to oracle from UNIX by a script. I need the script to prompt for a variable and that variable to be used for dml in sql statment but not able to do so..
Script 1 will be something like this
#!/bin/bash
USER=$1
PASSWD=$2
DB=$3
exec >output/$DB$USER.out 2>&1
sqlplus ${USER}/${PASSWD}@${DB} << THEEND
set serveroutput on;
set pages 0;
set lines 32000;
start $4
quit
THEENDdone
wait
The parameter $4 will be calling a sql script (.sql) where i want to prompt and accept few variables
PROMPT Tracking ID of product to be ended
ACCEPT v_ti NUMBER PROMPT "Tracking ID: "
SELECT *
FROM products
WHERE tracking_id = &v_ti ;
But this is not working as script comes out without prompting for variable..
Any help ?

Just did a quick test and it only seems to have the issue when getting the script from STDIN. If you pass it a file "sqlplus user/pass@db @myscript.sql" then it will wait for the input. So if it's going to be a wrapper for scripts you should have no problems, otherwise you will have to cat your script into a temp file and then call sqlplus.
Hope that helps

Similar Messages

  • SAP DB Connection from SAP BI on HP UNIX to MS SQL External Database

    Dear All,
    Greetings!
    I have a scenario to configure a SAP DB Connection from SAP BI System on HP UNIX 11i to the external legacy system MS SQL 2000 Enterprise for data upload. I am interested in connecting the SQL server as a Source System to the BI System.
    I read through documents mentioning about installation of a Client driver in the SAP BI System, I also downloaded the JDBC client software and tried installing the same, but the steps as mentioned Setting the CLASSPATH or connecting to the server did not work.
    Please help me in connecting the SQL Server as Source System, I would like to know in detail about the same - so kindly help me with the links to documents and guides about the same.
    Thank you
    Regards,
    Vineeth Damodar

    Short answer: this does not work.
    Long answer: To connect directly to the database you need
    - a database client for the source system
    - a database interface library for the source system
    Both of them are not available for HP-UX if the target database is SQL server --> doesn't work.
    What you can do is: add a Windows application server to your  BI system (heterogeneous installations work and are supported) and add there the database client and the database interface library.
    Markus

  • How to connect to oracle9i database from Unix

    Hi All,
    How can i connect to remote oracle9i database(windows based) from Unix. I have following server information Server IP, Username , Userpassword , DataBase name.Do i need any other information to connect to server?
    How can i connect database from Putty?
    Do i need to install SQL on the Unix to connect to oracle server?
    and which C/C++ API i have to use to access tables from the remote oracle server?
    please help me i am new to oracle .
    Thanks in advance.

    Oracle generally uses a special set of software, commonly called the SQLNet or Oracle Networking, as a layer to provide a connection between the client and the database server.
    In general terms,
    - the client software (perhaps sqlplus, an application, ODBC) calls Oracle Networking on the client computer and says "please connect to database known as 'x'";
    - Oracle Networking translates the request, often by looking up 'x' in the TNSNAMES.ORA file at the client side, to get the host name, the port the Oracle listener is waiting on, and the name of the database service to access;
    - Oracle Networking contacts the computer on the required port. If the listener is there, the Oracle Networking client asks for a connection to the database service;
    - The Listener (if it recognizes it) asks the database service for a 'server process';
    - The database starts up a server process which grabs a network port and tells the listener which port was obtained;
    - The listener tells Oracle Networking on the client which port to use;
    - The client disconnects from the Listener, and reconnects at that port;
    - The server process starts authentication and session initialization, after which we are good to go.
    In answer to your questions:
    1) How can i connect database from Putty?
    That implies you want to telnet to the Windows box and run the client stuff locally on the Windows box. So that means you need to look at telnet or ssh documentation - this has nothing to do with Oracle.
    2) Do i need to install SQL on the Unix to connect to oracle server?
    Not really. It does mean you might want to install an Oracle CLIENT (see the download section of http://otn.oracle.com) which will initiate the sequence as above.
    A different sort of client is SQL Developer, a Java-based GUI with it's own built-in Oracle Networking, that displays database stuff. That is also offered by Oracle at the same download page.
    3) and which C/C++ API i have to use to access tables from the remote oracle server?
    Oracle provides a C/C++ API as a pre-processor, called Pro*C. I suspect this si way beyond what you want right now.
    4) please help me i am new to oracle .
    Please, please, please, please, please ..... please .... purchase and read http://www.oreilly.com/catalog/oressentials3/

  • How to connect to UNIX OS from oracle stored procedure

    Hi,
    I need to connect to UNIX OS from oracle stored procedure.
    Curently working in Oracle9i.
    I tried in google but I could'nt get any.
    Can you send me pointers on how to do this.
    Thanks,
    Kavitha.

    Can use Java Stored Proc, or an External Proc.
    Java method:
    create or replace and compile Java Source named "OSCommand" as
    -- java:        OS COMMAND
    -- descr:       Executes an Operating System Command using the JAVA RTS
    -- IN parameter:        os command to execute (including fully qualified path names)
    -- OUT parameter:       returncode [\nstring]
    --                      where string a max of 32000 chars of the output of the command
    --                      (note that \n is used as separators in the string)
    --                      returncode=-1   Java RTS error occurred (e.g. command does not exist)
    --                      returncode=255  o/s command failed (e.g. invalid command params)
    import java.io.*;
    import java.lang.*;
    public class OSCommand{
            public static String Run(String Command){
                    Runtime rt = Runtime.getRuntime();
                    int     rc = -1;
                    try{
                            Process p = rt.exec( Command );
                            int bufSize = 32000;
                            int len = 0;
                            byte buffer[] = new byte[bufSize];
                            String s = null;
                            BufferedInputStream bis = new BufferedInputStream( p.getInputStream(), bufSize );
                            len = bis.read( buffer, 0, bufSize );
                            rc = p.waitFor();
                            if ( len != -1 ){
                                    s = new String( buffer, 0, len );
                                    return( s );
                            return( rc+"" );
                    catch (Exception e){
                            e.printStackTrace();
                            return(  "-1\ncommand[" + Command + "]\n" + e.getMessage() );
    show errors
    create or replace function osexec( cCommand IN string ) return varchar2 is
    -- function:    OS EXEC
    -- descr:       Executes an Operating System Command
    language        JAVA
    name            'OSCommand.Run(java.lang.String) return java.lang.String';
    show errors===
    This can then be used from PL/SQL and even SQL. e.g.
    SQL> select osexec( '/bin/date' ) from dual;
    OSEXEC('/BIN/DATE')
    Wed Nov  9 13:30:13 SAST 2005
    SQL>Note the Java permissions required - replace FOO with the name of applicable Oracle schema
    ==begin
            dbms_java.grant_permission(
                    'FOO',
                    'SYS:java.io.FilePermission',
                    '<<ALL FILES>>',
                    'execute'
            dbms_java.grant_permission(
                    'FOO',
                    'SYS:java.lang.RuntimePermission',
                    'writeFileDescriptor',
            dbms_java.grant_permission(
                    'FOO',
                    'SYS:java.lang.RuntimePermission',
                    'readFileDescriptor',
            commit;
    end;
    /==
    Last thing... note that opens a potential giant size security hole into the Oracle Server Platform. So implement it properly using a proper Oracle security model.

  • Connecting to Windows SQL server from Unix Oracle Server

    How can I connect to Windows MS SQL server from Unix Oracle Server? What installation or package will I need?

    Two options:
    1) Do a search on "Oracle Transparent Gateways" and/or "Heterogenous Services". These are products that are designed solely to connect to other databases from Oracle.
    2) Use a type-4 JDBC driver for SQL Server, installed and running in the JVM of your Oracle server. I'm assuming your Oracle database is sufficiently recent to be java-enabled here.
    Justin

  • Need to access/connect Remote Unix server from Java

    Please any one give me a direct solution for connecting a remote Unix server through telnet connection from java application. Thanks in advance..

    If I run the below program codes, in the console it is asking to enter username and password in manual but I need to give it automatically.
    The highlighted "root" is entered by the user manually using keyboard.
    Expected:
    I mean the username, password and some action is set to be automatic, so that it should not ask the user to enter the input from keyboard.
    import java.awt.Robot;
    import java.awt.event.KeyEvent;
    import java.io.InputStream;
    import java.io.OutputStream;
    import java.io.FileOutputStream;
    import java.io.IOException;
    import org.apache.commons.net.telnet.TelnetClient;
    import org.apache.commons.net.telnet.TelnetNotificationHandler;
    import org.apache.commons.net.telnet.SimpleOptionHandler;
    import org.apache.commons.net.telnet.EchoOptionHandler;
    import org.apache.commons.net.telnet.TerminalTypeOptionHandler;
    import org.apache.commons.net.telnet.SuppressGAOptionHandler;
    import org.apache.commons.net.telnet.InvalidTelnetOptionException;
    import java.util.StringTokenizer;
    * This is a simple example of use of TelnetClient.
    * An external option handler (SimpleTelnetOptionHandler) is used.
    * Initial configuration requested by TelnetClient will be:
    * WILL ECHO, WILL SUPPR
    * ESS-GA, DO SUPPRESS-GA.
    * VT100 terminal type will be subnegotiated.
    * <p>
    * Also, use of the sendAYT(), getLocalOptionState(), getRemoteOptionState()
    * is demonstrated.
    * When connected, type AYT to send an AYT command to the server and see
    * the result.
    * Type OPT to see a report of the state of the first 25 options.
    * <p>
    * @author Bruno D'Avanzo
    public class UnixConnect implements Runnable, TelnetNotificationHandler
        static TelnetClient tc = null;
         * Main for the TelnetClientExample.
        public static void main(String[] args) throws IOException
            FileOutputStream fout = null;
            /*if(args.length < 1)
                System.err.println("Usage: TelnetClientExample1 <remote-ip> [<remote-port>]");
                System.exit(1);
            String remoteip = "192.168.20.11";
            int remoteport;
            if (args.length > 1)
                remoteport = (new Integer(args[1])).intValue();
            else
                remoteport = 23;
            try
                fout = new FileOutputStream ("spy.log", true);
            catch (Exception e)
                System.err.println(
                    "Exception while opening the spy file: "
                    + e.getMessage());
            tc = new TelnetClient();
            TerminalTypeOptionHandler ttopt = new TerminalTypeOptionHandler("VT200", false, false, true, false);
            EchoOptionHandler echoopt = new EchoOptionHandler(true, false, true, false);
            SuppressGAOptionHandler gaopt = new SuppressGAOptionHandler(true, true, true, true);
            try
                tc.addOptionHandler(ttopt);
                tc.addOptionHandler(echoopt);
                tc.addOptionHandler(gaopt);
            catch (InvalidTelnetOptionException e)
                System.err.println("Error registering option handlers: " + e.getMessage());
            while (true)
                boolean end_loop = false;
                try
                    tc.connect(remoteip, remoteport);
                    Thread reader = new Thread (new UnixConnect());
                    tc.registerNotifHandler(new UnixConnect());
                    reader.start();
                    OutputStream outstr = tc.getOutputStream();
                    byte[] buff = new byte[1024];
                    int ret_read = 0;
                    do
                        try
                            ret_read = System.in.read(buff);
                            if(ret_read > 0)
                            outstr.write(buff, 0 , ret_read);
                            outstr.flush();
                        catch (Exception e)
                            System.err.println("Exception while reading keyboard:" + e.getMessage());
                            end_loop = true;
                    while((ret_read > 0) && (end_loop == false));
                    try
                        tc.disconnect();
                    catch (Exception e)
                              System.err.println("Exception while connecting:" + e.getMessage());
                catch (Exception e)
                        System.err.println("Exception while connecting:" + e.getMessage());
                        System.exit(1);
         * Callback method called when TelnetClient receives an option
         * negotiation command.
         * <p>
         * @param negotiation_code - type of negotiation command received
         * (RECEIVED_DO, RECEIVED_DONT, RECEIVED_WILL, RECEIVED_WONT)
         * <p>
         * @param option_code - code of the option negotiated
         * <p>
        public void receivedNegotiation(int negotiation_code, int option_code)
            String command = null;
            if(negotiation_code == TelnetNotificationHandler.RECEIVED_DO)
                command = "DO";
            else if(negotiation_code == TelnetNotificationHandler.RECEIVED_DONT)
                command = "DONT";
            else if(negotiation_code == TelnetNotificationHandler.RECEIVED_WILL)
                command = "WILL";
            else if(negotiation_code == TelnetNotificationHandler.RECEIVED_WONT)
                command = "WONT";
            System.out.println("Received " + command + " for option code " + option_code);
         * Reader thread.
         * Reads lines from the TelnetClient and echoes them
         * on the screen.
        public void run()
            InputStream instr = tc.getInputStream();
            try
                byte[] buff = new byte[1024];
                int ret_read = 0;
                do
                    ret_read = instr.read(buff);
                    if(ret_read > 0)
                       System.out.print(new String(buff, 0, ret_read));
                while (ret_read >= 0);
            catch (Exception e)
                System.err.println("Exception while reading socket:" + e.getMessage());
            try
                tc.disconnect();
            catch (Exception e)
                System.err.println("Exception while closing telnet:" + e.getMessage());

  • Dbcon connection from sap db2 to external sql server

    Hi ,
    I am trying to connect from my sap server which is in unix platform with DB2 database to external SQL server using DBCON as  MSSQL_SERVER=<server_name> MSSQL_DBNAME=<db_name>. But while running ADBC_TEST_connection i am getting the error . When i check the error log it says
    Loading DB library '/usr/sap/DVL/SYS/exe/run/dbmssslib.so' ...
    M  *** ERROR => DlLoadLib()==DLENOACCESS - dlopen("/usr/sap/SID/SYS/exe/run/dbmssslib.so") FAILED
      "Unable to find library '/usr/sap/DVL/SYS/exe/run/dbmssslib.so'."  [dlux.c       445]
    M  {root-id=002655A9DCD21EE3B89D69F99DF39F0D}_{conn-id=00000000000000000000000000000000}_0
    B  *** ERROR => Couldn't load library '/usr/sap/SID/SYS/exe/run/dbmssslib.so'
    How to resolve this issue. As it was mentioned in few forum we need to download the dbsl library from kernel patches and to load in kernel path. As my  db is DB2  can  we download dbmssslib.so this library and load in kernel file? Is it will work?
    Regards,
    Rai

    Hi Rai,
    This error indicates that the ABAP stack could not find the SAP DBSL for SQL Server (dbmssslib.dll) in the kernel directory. If you encounter this error on a Unix - based server the root cause is clear: the DBSL does not exist for other platforms than Windows or Linux x84_64. In this case use a Windows-based or a Linux x86_64-based SAP Application Server to establish the connection. If your system does not contain a Windows-based or a Linux x86_64-based Application Server you need to setup a small one as workaround. If you encounter this error on a Windows Application Server or a Linux x86_64 based Application Server make sure that the DBSL is properly installed in the kernel directory as explained in the document below.
    For more details on configuration and troubleshooting refer to below SCN document
    How to access an external Microsoft SQL Server database
    Hope this helps.
    Regards,
    Deepak Kori

  • Connecting from Oracle to MS Access

    Hi,
    I've had a good search through the various topics on establishing a connection between Oracle and MS Access and have found that most center around Access initiating the connection (linked tables and the like).
    What I'd like to do is initiate the connection from Oracle.
    Some background:
    we are running Oracle 9.2.0.2 on an HP/UX 11 OS, and have a series of MS Access 2000 Databases that have identical schemas, but with totally different data content and different names (naming convention is datestamp of when Db was created).
    I would like to initiate a connection from within oracle to 'pull' the data from the Access DB's, and append the respective tables together into one lager table in oracle.
    Is there any way of doing this? Are there connection drivers that will allow oracle to create an ODBC connection to Access? and if so what must be loaded/configured within oracle on the Unix box to achieve this in an automated fashion?
    Any help most appreciated.
    Cheers,
    James

    You can do this sort of thing if you install Oracle Heterogenous Services. That lets you create a database link from an Oracle database to a non-Oracle database and issue SQL statements against the data in the non-Oracle database.
    Justin
    Distributed Database Consulting, Inc.
    www.ddbcinc.com/askDDBC

  • How to connect from Oracle 11g to SQL Server 2008 R2

    Hi,
    Is it possible to connect from Oracle 11g on AIX to SQL Server 2008 R2? If so, what is the preferred method?
    SQL Server has the original table. From Oracle 11g, we want to access data which is in SQL Server real time.
    Thank You
    Sarayu

    Hi,
    Have a look at these Oracle notes for the full information on the gateways -
    Master Note for Oracle Gateway Products (Doc ID 1083703.1)
    Functional Differences Between DG4ODBC and Specific Database Gateways (Doc ID 252364.1)
    Gateway and Generic Connectivity Licensing Considerations (Doc ID 232482.1)
    How to Setup DG4MSQL (Oracle Database Gateway for MS SQL Server) 64bit Unix OS (Linux, Solaris, AIX,HP-UX) (Doc ID 562509.1)
    How to Configure DG4ODBC on 64bit Unix OS (Linux, Solaris, AIX, HP-UX Itanium) to Connect to Non-Oracle Databases Post Install (Doc ID 561033.1)
    The Database Gateway for SQL*Server (DG4MSQL) needs a separate license but the Database Gateway for ODBC (DG4ODBC) is included in your RDBMS license. You only need to provide the third party ODBC driver needed by DG4ODBC.
    Regards,
    Mike

  • Java code to connect to unix box(putty)

    i'm having a great problem regarding accessing the putty box from java code.
    I need to read some log files from unix through java code.In my client program when i'm giving hostname and port=22...ssh terminal is getting detected,but i'm confused how to open that unix box by giving the username and password.and how am i goin to embed unix command in it.The entire job i've to do through java code.
    please help!!..Thanks
    Message was edited by:
    liz310
    Message was edited by:
    liz310

    thanks a lot guys for ur time...but i tried in every way..i'm getting hell lot of errors..please help..its really urgent
    /*this is my code:*/
    import com.jcraft.jsch.*;
    import com.jcraft.jsch.Channel;
    import com.jcraft.jsch.JSch;
    import com.jcraft.jsch.JSchException;
    import com.jcraft.jsch.Session;
    import com.jcraft.jsch.UserInfo;
    import java.io.*;
    public class shell_test {
    public static void main(String args[])
    String user="user15";
    String host="punlin040";
    String cmd="ls -l";
    JSch jsch = new JSch();
    try{
    Session session=jsch.getSession(user,host,22);
    session.setPassword("user15");
    //UserInfo usrInfo=new MyUserInfo();
    //session.setUserInfo(usrInfo);
    session.connect();
    Channel channel=session.openChannel("exec");
    ((ChannelExec) channel).setCommand(cmd);
    channel.setXForwarding(true);
    channel.connect();
    //code
    channel.setInputStream(System.in);
    // channel.setOutputStream(System.out);
    //((ChannelExec) channel).setErrStream(System.err);
    InputStream in = channel.getInputStream();
    channel.connect();
    byte[] tmp = new byte[1024];
    while (true)
    while (in.available() > 0)
    int i = in.read(tmp, 0, 1024);
    if (i < 0)
    break;
    System.out.print(new String(tmp, 0, i));
    if (channel.isClosed())
    in.close();
    // System.out.println("JSCH: exit-status: " +
    //channel.getExitStatus());
    break;
    try
    Thread.sleep(1000);
    catch (Exception ee)
    channel.disconnect();
    session.disconnect();
    //code
    //ch.setInputStream(System.in);
    //ch.setOutputStream(System.out);
    }catch(Exception e)
    {e.printStackTrace(); }
    /*public static class MyUserInfo implements UserInfo {
    public String getPassword()
    { return "password"; }
    public String getPassphrase()
    { return ""; }
    public boolean promptPassword(String arg0)
    { return true; }
    public boolean promptPassphrase(String arg0)
    { return true; }
    public boolean promptYesNo(String arg0)
    { return true; }
    public void showMessage(String arg0)
    but i'm getting following errors:
    com.jcraft.jsch.JSchException: java.lang.ClassNotFoundException: com.jcraft.jsch
    .jce.Random
    at com.jcraft.jsch.Session.connect(Session.java:160)
    at com.jcraft.jsch.Session.connect(Session.java:145)
    at shell_test.main(shell_test.java:25)
    Caused by: java.lang.ClassNotFoundException: com.jcraft.jsch.jce.Random
    at java.net.URLClassLoader$1.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClassInternal(Unknown Source)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Unknown Source)
    at com.jcraft.jsch.Session.connect(Session.java:156)
    ... 2 more

  • How to run import from Unix Oracle 8.0.5 database with Windows Oracle client?

    How to run import from Unix Oracle 8.0.5 database via network with Windows Oracle client? Is it possible? When I try to do it Oracle client just hangs... If not which ones are compatible Aix or Solaris to Unix or it must be a Unix client to connect to Unix Oracle database. Thank's for any help.

    Hi,
    In our project we are using this type. Since in this project server in UNIX(DEC) and client is running on windows. We have created a listener which always listen requests from client and doing the according to the request.
    Step1. create a request table, where u are inserting ur request.
    step2. create PRO*C proram, which is listening request on the table. If there is any request, call the imp (executable). This is happening on server side.
    Benifit. U can make a request from cleint and ftp the file client sit.
    Are u interested in more details and code, pls send a mail to me
    ---- Boby Jose Thekkanath
    [email protected]
    Dharma Computers(p) Ltd. Bangalore.
    null

  • Essbase migration procedure from Unix to NT

    Does anyone have a procedure to migrate essbase from unix to wondows NT? I know that is a procedure in installation guide Ch.10, but I think it is just for the NT to NT..

    we did this last year. export the data from the databases to a text file, use level 0 if you only load at level 0.after installing essbase on nt, add the same name apps and dbs in nt, connect to the unix & nt servers in appman, copy the outlines/dbs from unix to nt. load the data from your exports.copy all the object files eg .csc, .rpt, etc from the unix server, reset all server, app and db settings, including cfg file and recalc.we recreated security ids, groups and filters

  • Connect to Unix and load files

    Can I connect to Unix and load files without using agent on Unix?
    what I mean to connect directly to unix to load file from unix to Oracle database without using any agnets on Unix just by using server username and password
    Please help !!!
    Edited by: user653098 on Sep 5, 2010 11:45 AM

    One way i can think of is if the Files are in the same Server where the ODI Server . Launch the ODI Designer of the Server(using VNC or any other application ) and use the Local agent to load the data from Unix to database. Other than this you would need to have an Agent to communicate from your Client windows Machine and Unix box.

  • How to access the Oracle from Unix when SID is not provided?

    How to access the Oracle from Unix when SID is not provided.
    User Name : xxx
    Password : yyy
    SID : SID
    I use to access it using below command from Unix prompt:
    sqlplus xxx/yyy@SIDNow since I dont have SID, how to access the Oracle DB from Unix Box?
    User Name : xxx
    Password : yyy
    Service Name : zzz
    Regards,
    Sunny.

    Hi Ajay
    Thanks for the suggesstion :)..It worked as well.
    The Actual problem was in the "tnsnames.ora" file where in I need to make entry for the new SERVICE name.
    Now I am able to connect it properly.
    Regards,
    Sunny.

  • Connect from Outside

    Hi,
    I'm to connect to one 11g DB that run in SUSE. Here is the name of the DB
    SQL> select name from v$database;
    NAME
    ORCL
    SQL>
    select instance_name from v$instance ;
    INSTANCE_NAME
    orcl
    But when I login as root in the SUSE machine I've got this (the reason of that I used ssh, is due to that telnet is not available in SUSE)
    [root@webserver oracle]# ssh -p 1521 orcl
    ssh: Could not resolve hostname orcl: Name or service not known
    Any advice for this message above?

    HuaMin Chen wrote:
    Many thanks Edstevens. Then how can I achieve that I want to be able to connect to it from outside. I know that "ssh/telnet" is one pre-condition for that, isn't it?Not necessarily. As I said before, you can install the oracle client on your desktop/laptop and use the tools from there. No need for ssh at all.
    >
    Another thing is:
    I've just added 1521 port to the router
    http://www.4shared.com/photo/SdPj4_y1/fig100.html
    Do I need to reboot the router? Does anyone know if there's a "reboot" option for this model "TL-WR740N "?Don't know. I'm not a router guy.
    >
    Within the machine, I can ssh to 22 port without any problem:That's because port 22 is the standard port for the ssh communications protocol
    >
    [root@webserver ~]# ssh -p 22 3masters.dyndns.info
    [email protected]'s password:
    Last login: Fri May 13 23:30:13 2011 from 014198214097.ctinets.comFine, you can connect to the server.
    As I said before, don't do this as root. Don't do anything as root that doesn't absolutely require the very powerful privileges of root.
    [root@webserver ~]# exit
    logout
    But I do have problem to ssh to 1521 port below:
    [root@webserver ~]# ssh -p 1521 3masters.dyndns.info
    ssh_exchange_identification: Connection closed by remote host
    One more time: port 1521 is used by the oracle listener to to listen for connection requests to the oracle database. SSH is not making such a request and is NOT the tool for connecting to the database. The listener has no idea what is being asked of it when ssh sends it a packet, so the listener refuses to deal with it. You DO NOT connect to port 1521 with ssh. You connect to port 1521 with an Oracle compliant, OCI aware, program such as sqlplus.
    Any ideas?
    Think of SSH as being unix's equivielent to Windows cmd.exe. You don't connect to the database with cmd, though you may open cmd and then, from there, execute sqlplus.
    What do you imagine yourself doing once you 'connect from the outside'? What commands are you expecting to give? What are you expecting to see?
    Best regards
    Edited by: HuaMin Chen on May 13, 2011 11:51 PM

Maybe you are looking for

  • How too add another iPhone to Maps with DIFFERENT iCloud accounts

    I went to this support article:  http://support.apple.com/kb/TS5293 I want to send directions to my wife's iPhone BUT we have different iCloud IDs.  According to suppport article, both of us must have SAME iCloud ID. IS THERE A WAY AROUND THIS? I see

  • Nested tags are no longer evaluated since sp3

    Since the introduction of service pack 3 for WLS6.1, all our custom tags           have a problem: any tag that is nested inside one of our custom tags is not           evaluated, but just displayed as text. Before sp3 everything worked just         

  • Can't get rid of iPad 2 update notification number.

    A few days ago my update notification appeared (red circle with the numeral one) next to the App Store icon. When I click on "app store" and go to the update page there is nothing to update. Have an iPad 2. Any suggestions?

  • Question to Adobe: Ruling out non-Adobe viewers via Acrobat Javascript

    Hi, ***I would like to address this question to Adobe Acrobat developers:**** I'd like to add a doc-level javascript (thru another script) that will check the viewer type, and if it neither Acrobat (6 and higher) nor Reader, the document will close.

  • How to download movies ?!

    I can only see movies/videos but have no audio. They play fine on Itunes but when I "Convert Selection for Ipod" the sound is gone. I Purchased Quick Time Pro thinking this would help but I must be using it wrong because the same thing happens. Help