1 2 3 Previous Next 37 Replies Latest reply: Jan 30, 2013 9:00 AM by Udo Go to original post RSS
      • 15. Re: New XE Install on Linux 5 - ORA-01017 Login Error
        Udo
        Possibly, the error
        ORA-31112: fail to unregister for HTTP port using xdb configuration
        is caused by a port conflict, i. e. another service is already using port 8080 (or whatever non-default value you may have chosen in your install). Because of that error I'm not sure the database homepage you see is the one that belongs to the XE instance we are talking about. Are you really sure it's up?
        Can someone let me know if the default Oracle XE Database install uses oracle database for the authentication? I doubt it tries to use OS authentication, by default.
        Actually, it uses both for default on Linux systems: You can login as sysdba without providing a username or password using
        sqlplus / as sysdba
        to the database your local enviroment points at. If you get "insufficient privileges", this usually means the dba-group isn't set properly or you've disabled OS-based authentication.
        Additionally, you can (always) use the authentication based on database users, e. g.
        sqlplus /nolog
        connect sys/password as sysdba
        (note that you don't need to add the service name XE unless you want to connect using a certain TNS Listener)
        Both seem to fail on your system which is very odd for a vanilla install.
        On the other hand, to startup your instance using the default init-scripts, OS-authentication is used and probably works on your system, as you say you can access its APEX/homepage. And the various install scripts use database authentication (sys and password) as well, so this probably has worked at some point of time.

        So, what you could try to do is
        1. Create a new user with no "special" environmental options, giving that user the default group "dba".
        2. Login with that user and run
        source /u01/app/oracle/product/11.2.0/xe/bin/oracle_env.sh
        sqlplus / as sysdba
        If this doesn't work, could you take a look at the non-binary part of the following file:

        /u01/app/oracle/product/11.2.0/xe/dbs/spfileXE.ora

        ... and check whether the parameters you see there match your system.

        -Udo

        P. S.:
        My company does have Oracle support, is there some place/person I could contact at Oracle for additional help?
        Sorry, you won't get official support for XE. If you encounter such problem for your regular supported database products, you'll probably first be pointed at some general documents that basically encourage you to do the things we have requested to do as well. But you can search the knowledge base and try to find additional ressources on how to troubleshoot ORAs 01017 and 01031...

        Edited by: Udo on 22.01.2013 16:34
        • 16. Re: New XE Install on Linux 5 - ORA-01017 Login Error
          985518
          Hi Udo,

          I am unable to login using sysdba or any account. I can access the APEX/Home page, but I can NOT login. tnsping looks good. BTW, I spoke with my manager, a distinguished engineer and he too had this same problem, on his MacBook Pro running VMware Fusion 4 and the same Linux 5 image that I provided to him. I'm now on VMware Workstation 9 for Windows 7, with the same problem.

          -bash-3.2$ sqlplus / as sysdba

          SQL*Plus: Release 11.2.0.2.0 Production on Tue Jan 22 10:03:54 2013

          Copyright (c) 1982, 2011, Oracle. All rights reserved.

          ERROR:
          ORA-01031: insufficient privileges

          Please take a look at the text data portion of my spfileXE.ora file and see if anything looks strange:
          XE.__db_cache_size=385875968
          XE.__java_pool_size=4194304
          XE.__large_pool_size=4194304
          XE.__oracle_base='/u01/app/oracle'#ORACLE_BASE set from environment
          XE.__pga_aggregate_target=432013312
          XE.__sga_target=641728512
          XE.__shared_io_pool_size=0
          XE.__shared_pool_size=234881024
          XE.__streams_pool_size=0
          *.audit_file_dest='/u01/app/oracle/admin/XE/adump'
          *.compatible='11.2.0.0.0'
          *.control_files='/u01/app/oracle/oradata/XE/control.dbf'
          *.db_name='XE'
          *.DB_RECOVERY_FILE_DEST='/u01/app/oracl
          e/fast_recovery_area'
          *.DB_RECOVERY_FILE_DEST_SIZE=10G
          *.diagnostic_dest='/u01/app/oracle'
          *.dispatchers='(PROTOCOL=TCP) (SERVICE=XEXDB)'
          *.job_queue_processes=4
          *.memory_target=1073741824
          *.open_cursors=300
          *.remote_login_passwordfile='EXCLUSIVE'
          *.sessions=20
          *.shared_servers=4
          *.undo_management='AUTO'
          *.undo_tablespace='UNDOTBS1'

          It seems like neither OS nor Oracle database authentication are working.

          How can I verify that I have OS authentication enabled?

          Is there any problem using the localhost loopback ip address? 127.0.0.1 is used in my /etc/hosts file, but I see I have an ip address assigned to eth0 192.168.220.128.

          /sbin/ifconfig -a
          eth0 Link encap:Ethernet HWaddr xx
          inet addr:192.168.220.128 Bcast:192.168.220.255 Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
          RX packets:113592 errors:0 dropped:0 overruns:0 frame:0
          TX packets:36930 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:19502696 (18.5 MiB) TX bytes:4372711 (4.1 MiB)

          lo Link encap:Local Loopback
          inet addr:127.0.0.1 Mask:255.0.0.0
          UP LOOPBACK RUNNING MTU:16436 Metric:1
          RX packets:235919 errors:0 dropped:0 overruns:0 frame:0
          TX packets:235919 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:17294069 (16.4 MiB) TX bytes:17294069 (16.4 MiB)

          All error msgs indicate I do not have sufficient privileges or the userid/passwd are invalid. So what privs is it looking at? Which is incorrect the userid or the passwd?

          I just added my personal account to Linux and performed a newgrp dba, successfully. I also sourced all the env variables that I setup for ORACLE. I still receive the ORA-01031 error.

          I noticed that the, lsnrctl status command, indicates that security is ON: Local OS Authentication. So, does that mean OS authentication is not working?

          bash-3.2$ lsnrctl status

          LSNRCTL for Linux: Version 11.2.0.2.0 - Production on 22-JAN-2013 11:53:10

          Copyright (c) 1991, 2011, Oracle. All rights reserved.

          Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC_FOR_XE)))
          STATUS of the LISTENER
          ------------------------
          Alias LISTENER
          Version TNSLSNR for Linux: Version 11.2.0.2.0 - Production
          Start Date 20-JAN-2013 07:29:40
          Uptime 2 days 4 hr. 23 min. 30 sec
          Trace Level off
          Security                  ON: Local OS Authentication
          SNMP OFF
          Default Service XE


          Thanks,
          Tom

          Edited by: 982515 on Jan 22, 2013 11:01 AM

          Edited by: 982515 on Jan 22, 2013 11:57 AM
          • 17. Re: New XE Install on Linux 5 - ORA-01017 Login Error
            985518
            To follow up on your questions on whether apex is really running, yes it is, but I can't login. http://localhost:8080/apex
            I don't see any place to attach a screen dump to your forum.

            ~Tom
            • 18. Re: New XE Install on Linux 5 - ORA-01017 Login Error
              985518
              I first shutdown the database and listener. I uninstalled Oracle XE, then I reinstalled Oracle XE. Before executing the, "/etc/init.d/oracle-xe configure" command, I changed the lines that login and set the initial sys and system passwds, so that it would print the command output to standard out.
              You can see below that I received both a insufficient privileges and an invalid option occurred. When I manually set all the environment variables at the command line and then execute the passwd setting command, everything looks correct, as far what the command line looks. It looks like there are two issues to figure out and this would explain why I cannot login later.

              Starting Oracle Net Listener...Done
              Configuring database...ERROR:
              ORA-01031: insufficient privileges


              SP2-0306: Invalid option.
              Usage: CONN[ECT] [logon [AS {SYSDBA|SYSOPER|SYSASM}] [edition=value]]
              where <logon> ::= <username>[<password>][@<connect_identifier>]
              <proxy> ::= <proxyuser>[<username>][<password>][@<connect_identifier>]

              The lines above occurred for each SQL attempt to set a passwd.

              Hopefully this will be an additional clue as to the real issue.

              ~Tom
              • 19. Re: New XE Install on Linux 5 - ORA-01017 Login Error
                985518
                Udo, help!

                Actually, this is really important to solve, as I work for a company that most everyone at Oracle has used. The Oracle database will be used by thousands of developers, via the VM image that I'm working on.

                Any additional ideas, would be greatly appreciated.

                Thanks,
                Tom
                • 20. Re: New XE Install on Linux 5 - ORA-01017 Login Error
                  orafad
                  I'll mention sqlnet.ora again, as the auth service parameter is required for "dba" group to be useful.
                  C:\>type C:\oracle\oraclexe\app\oracle\product\11.2.0\server\network\ADMIN\sqlnet.ora
                  # This file is actually generated by netca. But if customers choose to
                  # install "Software Only", this file wont exist and without the native
                  # authentication, they will not be able to connect to the database on NT.
                  
                  #SQLNET.AUTHENTICATION_SERVICES = (nts)
                  
                  C:\>sqlplus / as sysdba
                  
                  SQL*Plus: Release 11.2.0.2.0 Production on To Jan 24 20:12:18 2013
                  
                  Copyright (c) 1982, 2010, Oracle.  All rights reserved.
                  
                  ERROR:
                  ORA-01031: insufficient privileges
                  
                  
                  Enter user-name: ^C
                  C:\>REM now remove comment in sqlnet.ora to enable authentication_services parameter set to NTS
                  
                  C:\>sqlplus / as sysdba
                  
                  SQL*Plus: Release 11.2.0.2.0 Production on To Jan 24 20:13:29 2013
                  
                  Copyright (c) 1982, 2010, Oracle.  All rights reserved.
                  
                  Connected to an idle instance.
                  
                  SQL> ^C
                  Hope that helps.
                  • 21. Re: New XE Install on Linux 5 - ORA-01017 Login Error
                    orafad
                    Note that you'd have to create a sqlnet.ora directly under admin, if only occurence was in "samples" dir.
                    • 22. Re: New XE Install on Linux 5 - ORA-01017 Login Error
                      985518
                      I have a sqlnet.ora file now in the admin directory and since I'm on Linux (Win 7 running a virtual machine), what values do you suggest for the sqlnet.authentication_services. (none) or (beq, kerberos5)?
                      I tried none and restarted the xe, but so far no login.

                      Thanks,
                      Tom
                      • 23. Re: New XE Install on Linux 5 - ORA-01017 Login Error
                        orafad
                        If the native adapter is not platform generic (see Net reference/admin guide), try (all).
                        • 24. Re: New XE Install on Linux 5 - ORA-01017 Login Error
                          985518
                          I've set the value to (all) and restarted the Oracle DB server.

                          When you perform the, "oracle-xe configure", it fails to add the passwds for sys and system to Oracle's database. If I manually set all the variables and execute the command using the root id, here's the result:

                          echo alter user sys identified by \"$ORACLE_PASSWORD\"\; | $SU -s /bin/bash $ORACLE_OWNER -c "$SQLPLUS -s / as sysdba"
                          ERROR:
                          ORA-01031: insufficient privileges


                          SP2-0306: Invalid option.
                          Usage: CONN[ECT] [logon [AS {SYSDBA|SYSOPER|SYSASM}] [edition=value]]
                          where <logon> ::= <username>[<password>][@<connect_identifier>]
                          <proxy> ::= <proxyuser>[<username>][<password>][@<connect_identifier>]

                          Since no passwd has been added for sys/system I won't be able to login after the configure command is executed, right?

                          ~Tom
                          • 25. Re: New XE Install on Linux 5 - ORA-01017 Login Error
                            orafad
                            Forget about passwords for a moment. You need to get the basic 'sqlplus / as sysdba' to function, otherwise install won't succeed.

                            Figure out why - go back to system requirements.

                            Is the linux based OS on the required list? Are versions correct? Did you "prep" the linux properly before the Oracle installation? See Installation guide for more info.

                            Do you have SElinux enabled or something like that that could interfer?
                            • 26. Re: New XE Install on Linux 5 - ORA-01017 Login Error
                              orafad
                              982515 wrote:
                              ... using the root id ...
                              I missed that part.

                              Confirm as the oracle user, the outcome of sqlplus / as sysdba.
                              • 27. Re: New XE Install on Linux 5 - ORA-01017 Login Error
                                985518
                                su - oracle
                                -bash-3.2$ id
                                uid=969(oracle) gid=533(dba) groups=15(conf),100(users),533(dba),40010(oinstall),40011(oper)
                                -bash-3.2$ sqlplus -s / as sysdba
                                ERROR:
                                ORA-01031: insufficient privileges

                                From the actual, "oracle-xe configure":
                                + echo alter user sys identified by '"xxxxxxxxx";'
                                + /bin/su -s /bin/bash oracle -c '/u01/app/oracle/product/11.2.0/xe/bin/sqlplus -s / as sysdba'
                                ERROR:
                                ORA-01031: insufficient privileges

                                SP2-0306: Invalid option.
                                Usage: CONN[ECT] [logon [AS {SYSDBA|SYSOPER|SYSASM}] [edition=value]]
                                where <logon> ::= <username>[<password>][@<connect_identifier>]
                                <proxy> ::= <proxyuser>[<username>][<password>][@<connect_identifier>]

                                ~Tom
                                • 28. Re: New XE Install on Linux 5 - ORA-01017 Login Error
                                  985518
                                  I checked the installation requirements and I don't see anything that should stop login from working. I check all my install logs again and all look good.

                                  I did try creating a pwd file using the orapwd utility. I tried both authentication set to (all) and (none) and restarted the oracle db each time.

                                  If nothing else, sys user should work. I have no clue what permissions that oracle sqlplus is looking at that are not set correctly.

                                  ~Tom
                                  • 29. Re: New XE Install on Linux 5 - ORA-01017 Login Error
                                    orafad
                                    982515 wrote:
                                    restarted the oracle db each time.
                                    How is the instance restarted exactly? Should not be possible if authentication does not work. Something is missing...