10 Replies Latest reply: Mar 25, 2013 5:07 AM by 474591 RSS

    APEX 4 with two HTTP servers ?

    474591
      Hi Im into new territory for me here
      hope some one can point me in the right direction.

      I have an internal linux server running 11i and APEX4 with HTTP server
      all apps work perfectly internally

      I have a HTTP server in the DMZ with modplsql configured to link to one of the apps in my internal network
      The app is in a Linux box with 11i and is 4.0 apex.

      Internaly (on the LAN) the HTTP server that is on the same box as 11i and Apex renders every thing properly.


      When I try to access the application via the web images do not render.
      Dropdown lists all work but the dynamic actions on them don't,
      also the submit function does nothing when pressed.

      Can any one point me in the direction of reading material on this kind of setup?

      Thanks in advance

      Bjorn
        • 1. Re: APEX 4 with two HTTP servers ?
          jariola
          Hi,

          If I understand correctly your setup, I assume you have not copy APEX images to other server folder.
          Check from configuration file witch folder alias /i/ is pointing and place APEX install files image folder content there.

          Regards,
          Jari
          -----
          My Blog: http://dbswh.webhop.net/htmldb/f?p=BLOG:HOME:0
          Twitter: http://www.twitter.com/jariolai
          • 2. Re: APEX 4 with two HTTP servers ?
            AndyPol
            Hi

            I my opinion You have to configure regular Apache as Reverse Proxy in DMZ. Reverse Proxy will redirect every request to your internal server. It will be work perfect.

            Regards
            • 3. Re: APEX 4 with two HTTP servers ?
              474591
              Hi Jari,
              I was thinking along the same lines, I have a job into get access to the server. Structured IT orginisations take time to do anything!
              thanks
              • 4. Re: APEX 4 with two HTTP servers ?
                474591
                Hi Andy,

                My Comms bods have their load ballencers apparently working as a reverse proxi. But making the HTTP server a reverse proxi is a thought. I'll run it by them.
                Thanks for the avenue of investigation.

                Cheers
                • 5. Re: APEX 4 with two HTTP servers ?
                  474591
                  @AndyPol - stiil waiting on the comms bods getting back to me.


                  Ok eventualy I was permitted to see (they sent me a copy) the dads.conf file on the HTTP server and given rights to write to the image folder.
                  I copied the images from
                  /fs1/app/oracle/product/ohs_apex/Apache/images/ on the internal server
                  to
                  /fs1/app/oracle/product/ohs_home/Apache/images/
                  on the DMZ server.

                  Still no joy. the page is displayed with no images and when you try to run javascript you get an error on page.

                  the following is the dads.conf - I'm not seeing anything wrong with it, can any one note anything obviouse?


                  Alias /i/ "/fs1/app/oracle/product/ohs_home/Apache/images/"

                  AddType text/xml xbl
                  AddType text/x-component htc

                  <Location /pls/apex>
                  Order deny,allow
                  PlsqlDocumentPath docs
                  AllowOverride None
                  PlsqlDocumentProcedure wwv_flow_file_mgr.process_download
                  PlsqlDatabaseConnectString crdapex.southlanarkshire.gov.uk:1521:orcl ServiceNameFormat
                  PlsqlNLSLanguage AMERICAN_AMERICA.AL32UTF8
                  PlsqlAuthenticationMode Basic
                  SetHandler pls_handler
                  PlsqlDocumentTablename wwv_flow_file_objects$
                  PlsqlDatabaseUsername APEX_PUBLIC_USER
                  PlsqlDefaultPage apex
                  PlsqlDatabasePassword ranger
                  Allow from all
                  </Location>

                  Edited by: bjorn toulouse on Mar 15, 2013 4:58 AM

                  Edited by: bjorn toulouse on Mar 15, 2013 4:59 AM
                  • 6. Re: APEX 4 with two HTTP servers ?
                    474591
                    Bump
                    • 7. Re: APEX 4 with two HTTP servers ?
                      AndyPol
                      Hi

                      My reverse proxy section in httpd.conf:


                      ------------------------

                           # image Alias
                           Alias /i/ /u01/apex/images/
                           # Directory for APEX files
                           <Directory "/u01/apex/images/">

                                Options None
                                AllowOverride None
                                Order allow,deny
                                Allow from all
                                
                                # Cache
                                <IfModule mod_expires.c>
                                     ExpiresActive     On
                                     ExpiresDefault     "access plus 1 month"
                                </IfModule>

                                ### compressed Files type
                           <IfModule mod_deflate.c>
                           AddOutputFilterByType DEFLATE text/css
                           AddOutputFilterByType DEFLATE application/x-javascript
                           AddOutputFilterByType DEFLATE application/xhtml+xml
                           AddOutputFilterByType DEFLATE application/xml
                                     AddOutputFilterByType DEFLATE text/x-component
                                </IfModule>

                           </Directory>
                           
                           ### Setting reverse proxy

                           # flasch Charts #HOST# )
                           ProxyPreserveHost On

                           ProxyPass /apex     http://localhost:8080/apex
                           ProxyPassReverse /apex     http://localhost:8080/apex

                           
                           SetEnv force-proxy-request-1.0 1
                           SetEnv proxy-nokeepalive 1
                      --------------------------------

                      It works perfect for me.

                      Regards
                      • 8. Re: APEX 4 with two HTTP servers ?
                        474591
                        Hi Andy, thanks for getting back to me,
                        this is driving me nuts.
                        In my orginisation IT is devided into small boxes for each function so...

                        Apex - development - me and kev
                        Linux - server team
                        Oracle - DBAs
                        HTTP Server - DBAs (because it comes on the oracle CD go figure??)
                        Any changes to permissions or security - the opperations team
                        Anything to do with internet - internet team

                        I raised a request with the comms team to look at using the box as a reverse proxi, they have not got back to me yet.
                        Apex is low on their priority list.

                        From what they told me they have a hardware reverse proxi to "translate" the incoming requests to the DMZ http server. The DMZ http server then uses modplsql to query my application. The app is based of view of the data on the Internal DB server.

                        With a bit of luck they might let us try the reverse proxi on the DMZ server.

                        Like I said I'm a bit out my depth on this one.

                        Cheers
                        • 9. Re: APEX 4 with two HTTP servers ?
                          474591
                          oops double post - sorry

                          Edited by: bjorn toulouse on Mar 18, 2013 7:21 AM
                          • 10. Re: APEX 4 with two HTTP servers ?
                            474591
                            In addition to Andy's Comments the following should be noted.

                            For some reason the Http server required the images path to be the same on both boxes - no idea why - if you install http server stand alone you will get an ohs_home if installed with apex you get ohs_apex, create an ohs_apex folder and copy every thing into it.

                            The other wierd bit is that the http server will no longer look here for its images, it will go to the apex server that is running HTTP server.
                            So why it neads this folder or indead why it neads the conf files to point here is a mystery to me.

                            Any way heres hopping this helps someone else.