Sponsored Links
Sponsored Link

sponsored links

Collapse

Announcement

Collapse
No announcement yet.

Strange error when attempting to log into existing configuration

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Strange error when attempting to log into existing configuration

    Where I work, we are not using our iSeries as a web server at all (most everything is green screen for the time being). I think we would benefit a lot from migrating some things to a web based set up.

    Having no good idea where to start; I figured I might just mash our servers host-name into my browser bar and see what I get:
    Click image for larger version

Name:	help_1.png
Views:	1
Size:	10.5 KB
ID:	127970

    "That looks promising", I thought to myself. So I entered my credentials and was presented with this:
    Click image for larger version

Name:	help_2.png
Views:	1
Size:	7.9 KB
ID:	127971

    I work with java everyday, and NullPointerException (being a unchecked exception) generally means something preventable is occurring that is fudging everything up. Beyond that I don't have a clue what is actually going on here.

    I was not able to turn up anything very useful on Google. Any thoughts are appreciated.

  • #2
    Re: Strange error when attempting to log into existing configuration

    Well from the screen shots you don't appear to have "just mash our servers host-name into my ..." - the port number 2005 is there too. Since the default browser port is 80 that can't be an accident.

    Normally you reach that screen via port 2001 i.e. https://systemname:2001 which then redirects to 2005 for sign on credentials.

    It looks as if your admin server is not fully configured - or you do not have enough authority - although I would expect a better response to that situation.

    Rather than describe what happened how about you tell us what you were trying to do and then we can point you in the right direction.

    Comment


    • #3
      Re: Strange error when attempting to log into existing configuration

      I did describe exactly what I did. As for what I am trying to do; that is ambiguous at the moment; I suppose getting this set up to the point where I can start playing around with it would be a good short term goal.

      I discovered a list of ports to try out (since nothing happened connecting on 80 and I knew there were http server jobs started on the server) in an IBM document through my mostly fruitless googling. I did not think it mattered leaving that detail out.

      I suppose I should also mention at this point, that no one currently employed here would have set up any of this configuration.

      Comment


      • #4
        Re: Strange error when attempting to log into existing configuration

        OK - so you hunted around and found references to the 2000 series ports and tried one of those. It would have been useful to know that.

        My best guess is that you don't have enough authority and/or your HTTP admin server is not set up correctly. But you should get a better response than a Java error.

        What HTTP server instances do you see running on the system? (WRKACTJOB SBS(QHTTPSVR))

        If Admin is the only one then check the job logs for the admin instance to see if there are any hints.

        If Admin is the only one then you should be able to safely end the server and restart it. i.e. ENDTCPSVR SERVER(*HTTP) HTTPSVR(*ADMIN) and then STRTCPSVR SERVER(*HTTP) HTTPSVR(*ADMIN). Look for any messages in the log during restart.

        If you don't have enough authority to do this then you won't have enough authority to create a server instance

        If the admin server restarts then try and log in again by going to https://systemname:2001 and see what happens. It should redirect to port 2005 for sign on. If it blows up again then you're going to need more help. You are probably missing some PTFs.

        If you need more help it would be useful to know what release you are on.

        Comment


        • #5
          Re: Strange error when attempting to log into existing configuration

          We are running v7r1
          Authority should not be an issue I would think, my user class is *SECOFR.

          Anyways here's a dump of WRKACTJOB SBS(QHHTPSVR)

          Code:
                          Current                                        
          Subsystem/Job    User          Type  CPU %  Function            Status
          QHTTPSVR         QSYS          SBS      .0                      DEQW 
            ADMIN          QTMHHTTP      BCH      .0  PGM-QZHBMAIN        SIGW 
            ADMIN          QTMHHTTP      BCI      .0  PGM-QZSRLOG         SIGW 
            ADMIN          QTMHHTTP      BCI      .0  PGM-QZSRHTTP        SIGW 
            ADMIN1         QLWISVR       BCI      .0  JVM-com.ibm.lw      THDW 
            ADMIN2         QLWISVR       BCI      .0  JVM-com.ibm.lw      THDW 
            ADMIN3         QLWISVR       BCI      .0  JVM-com.ibm.lw      THDW 
            ADMIN4         QWEBADMIN     BCI      .0  JVM-com.ibm.lw      THDW 
            QZDASOINIT     QSECOFR       BCI      .0                      TIMW
          Again, I know we are not using anything web-based that is hosted on our iSeries so I am not sure where/how these would've been configured or started.

          (I took this from the job log of PGM-QZHBMAIN above)
          Code:
          CALL PGM(QHTTPSVR/QZHBMAIN) PARM('-S' 'ADMIN' '-AdmDftPort' '2001' '-AdmDf
          tSecPort' '2010' '-uiMin' '3' '-uiMax' '5' '-cEAMap' '*CCSID' '-cAEMap' '*
          CCSID' '-uiCCSID' '819' '-apache' '-d' '/QIBM/UserData/HTTPA/admin' '-f' '
          /QIBM/ProdData/HTTPA/admin/conf/admin-ibm.conf' '-AutoStartY' '-c' 'Listen
          ' '2001')
          It appears that admin-lwi.conf governs those numbered admin instances:
          Code:
           #---------------------------------------                              
           # LWI Admin Instance directives                                       
           #---------------------------------------                              
           LoadModule mod_ibm_lwi /QSYS.LIB/QHTTPSVR.LIB/QLWIIHSMOD.SRVPGM       
           LwiPluginConfig /QIBM/UserData/HTTPA/admin/conf/lwi-plugin-cfg.xml    
           <LwiProfile Admin1>                                                   
             LwiAutostartOption StartEnd                                         
             LwiStartJobQueue QHTTPSVR/QZHBHTTP HTTPWWW                          
             LwiAssignUserID QLWISVR                                             
           </LwiProfile>   
                                                       
          #---------------------------------------          
          # LWI Admin2 Instance directives                  
          #---------------------------------------          
          <LwiProfile Admin2>                               
            LwiAutostartOption StartEnd                     
            LwiStartJobQueue QHTTPSVR/QZHBHTTP HTTPWWW      
            LwiAssignUserID QLWISVR                         
          </LwiProfile>                                     
                          
          #---------------------------------------        
          # LWI Admin3 Instance directives                
          #---------------------------------------        
          <LwiProfile Admin3>                             
            LwiAutostartOption StartEnd                   
            LwiStartJobQueue QHTTPSVR/QZHBHTTP HTTPWWW    
            LwiAssignUserID QLWISVR                       
          </LwiProfile>                                                                                                     
                                                        
          #---------------------------------------      
          # LWI Admin4 Instance directives              
          #---------------------------------------      
          <LwiProfile Admin4>                           
            LwiAutostartOption StartEnd                 
            LwiStartJobQueue QHTTPSVR/QZHBHTTP HTTPWWW  
            LwiAssignUserID QWEBADMIN                     
          </LwiProfile>
          Edit: I managed to get in by using the actual IP address of the box instead of the hostname we assign it in our network (duh!) it still does the same thing when just going to http://host:2001. But I tried going directly to http://host:2001/HTTPAdmin I was prompted for my credentials and was presented with this:
          Click image for larger version

Name:	Untitled.png
Views:	1
Size:	104.3 KB
ID:	126701
          Last edited by Raywes88; September 24th, 2013, 07:13 AM. Reason: Success, of some sort

          Comment


          • #6
            Re: Strange error when attempting to log into existing configuration

            Interesting.. so you seem to have some DNS issues, that's why you're getting the 500 java.lang.NullPointerException ?? Either that, or you skipped the page by going directly to the HttpAdmin page.

            I would make sure DNS is working properly. Your hostname should resolve to the same IP address you used in the URL. If it does not, something needs to be fixed. Likewise, your IP address should resolve to the domain name.

            If all is well, and you're still having problems, I would contact IBM support.

            Comment


            • #7
              Re: Strange error when attempting to log into existing configuration

              Yea, I found out after some further reading that HTTPAdmin is accessed from a intermediate page that is supposed to be displayed when logging in at the prompt displayed @ http://host:2001.
              That is still not working, however, like you mentioned I seem to be able to navigate directly to the HTTPAdmin page.

              The NullPointer makes sense if it is a DNS issue because directly navigating to HTTPAdmin using our hostname caused errors; which is what made me think to try the IP address to begin with.

              EDIT: It just occured to me that our network admin just makes an entry in:
              Code:
              System32\drivers\etc\hosts
              To make the "hostname" we use resolve to the correct IP. This is probably at least part of the issue.

              Comment


              • #8
                Re: Strange error when attempting to log into existing configuration

                OK - so you need to get the DNS fixed - but you can use the IP and clearly that gets you in the door.

                As to what next - now we really do need to know what you plan on doing. For instance - if you were planning on installing any one of a number of free or fee web tools, many (PHP, CGIDEV2, Profound UI, etc. etc.) will configure an Apache server for you as part of the install. If you intend to start writing web apps using the raw APIs then you will need to configure an Apache instance yourself. That would be done from the Admin page you have now reached.

                In other words your next step depends on what you want to do next.

                Comment


                • #9
                  Re: Strange error when attempting to log into existing configuration

                  Thanks JonBoy I have been trying to determine how I want to proceed. I am most experienced in Java/Python so I was considering going with websphere or the IAS. I also spent some time researching some other alternatives like Renaissance, CGIDEV2, etc. Lots of questions...

                  What I've noticed is that I seem to be in an interesting position because most of these polished frameworks seems to be geared towards the RPG veteran, which I am not. And to go a route that utilizes something I am more familiar with leaves me at the mercy of the raw APIs.

                  On a semi related note, I've read that RDi was developed on top of Eclipse. I've found an Eclipse directory in my "system i access for windows" directory, so I assumed it was probably RDi, but I cannot get it to run:
                  Code:
                  !SESSION Sep 24, 2013 14:51:17.750 ---------------------------------------------
                  eclipse.buildId=M200409161125
                  java.version=1.6.0_23
                  java.vendor=Sun Microsystems Inc.
                  BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US
                  
                  !ENTRY org.eclipse.core.runtime Sep 24, 2013 14:51:17.750
                  !MESSAGE Product org.eclipse.platform.ide could not be found.
                  
                  !ENTRY org.eclipse.osgi Sep 24, 2013 14:51:17.758
                  !MESSAGE Application error
                  !STACK 1
                  java.lang.RuntimeException: No application id has been found.
                  	at org.eclipse.core.internal.runtime.PlatformActivator$1.run(Unknown Source)
                  	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(Unknown Source)
                  	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(Unknown Source)
                  	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                  	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
                  	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
                  	at java.lang.reflect.Method.invoke(Unknown Source)
                  	at org.eclipse.core.launcher.Main.basicRun(Main.java:185)
                  	at org.eclipse.core.launcher.Main.run(Main.java:704)
                  	at org.eclipse.core.launcher.Main.main(Main.java:688)

                  Comment


                  • #10
                    Re: Strange error when attempting to log into existing configuration

                    Well you can get Python for the IBM i (http://www.iseriespython.com/app/isp...Start?job=Home) but it is not supported by IBM in any manner. If you are familiar with Python and Java - but don't want to mess with WAS, or IAS or TomCat then I'd be inclined to download and install Zend Server - which is the IBM supported version. In fact IBM pay Zend to supply the product. It will do all the apache configuration for you and also install a copy of ZendDb (MySQL) if you let it. Add to that the DB2 storage engine (can't recall if that is installed by the Zend process) and you can access DB2 via the MySQL interfaces or directly via the DB2 interfaces or the IBM i PHP toolkit.

                    Comment


                    • #11
                      Re: Strange error when attempting to log into existing configuration

                      Thanks for the tip, I had not even thought of a PHP based solution. PHP has an almost complete OOP implementation, which I like. My superiors will also like that they are IBM partners, and the fact that we can get a proof of concept up and running without spending any coin.

                      The other tempting option is to go through the hassle of setting up DJango using iSeries python. The set up process looks ugly, but it almost seems worth it to be able to use DJango.

                      Edit: I've also just discovered this: https://code.google.com/p/ibm-db/wik..._django_README
                      Which is awesome, I had no idea IBM developed a DB2 backend for Django. This opens up the possibility of us doing web serving on one of our other servers and accessing the data we need from our iSeries.

                      Comment


                      • #12
                        Re: Strange error when attempting to log into existing configuration

                        The PHP Object model gets better all the time and the amount of excellent free software has helped several of my clients demonstrate the viability of IBM i in the modern world. IBM's arrangement with Zend also gives you a free 12 month license to Zend Studio which incorporates some great new features for mobile development.

                        If you have a tiny (<$400) bit of money take a look at PHPGrid (PHPGrid.com) which I wrote about here:http://www.ibmsystemsmag.com/ibmi/de...on/grid_tools/

                        There is a free version that can be used on the IBM i with MySQL (and can therefore access DB2 data via the DB2 Storage engine) but you need to pay some $ to get the version that supports all features including DB2 native access. We are using this in production now for quick reporting/searching requirements. Have had one or two issues that required support which has been excellent.

                        We've also used Xataface and ATK - you will probably love ATK if you are already OO literate. You'll have to write and ask them for the native DB2 drivers as they are not part of the base code.

                        Comment


                        • #13
                          Re: Strange error when attempting to log into existing configuration

                          Since it will involve no changes to the server, and I can work on it in my spare time freely (since I have a few other projects going currently); I am going to attempt to roll my own solution using a combination of the iSeries ODBC Access Driver, pyodbc, and web2py.

                          I have seen a few examples (here's one) that indicate this is possible, if I am met with any success I'll document my journey in a new thread on the forum here.

                          I appreciate the help/suggestions.

                          Comment


                          • #14
                            Re: Strange error when attempting to log into existing configuration

                            Be interesting to see how you get one - but one comment. You could do exactly the same thing with PHP and then move the code to the IBM i if it all works. Zend Sever can be downloaded FOC for Windows, Linux, Mac ... and it is the same code. That gives you a fully supported solution.

                            Just sayin'

                            Comment

                            sponsored links

                            Collapse

                            Working...
                            X