AppServerPortPreference on Websphere 6.0.17 - Websphere

This is a discussion on AppServerPortPreference on Websphere 6.0.17 - Websphere ; Hello, We have a virtual host running on port 100, and an external IP being translated from port 80 to this port 100. When the user hits the websphere app, they are forwarded from the login.jsp and the new URL ...

+ Reply to Thread
Results 1 to 7 of 7

Thread: AppServerPortPreference on Websphere 6.0.17

  1. AppServerPortPreference on Websphere 6.0.17

    Hello,

    We have a virtual host running on port 100, and an external IP being translated from port 80 to this port 100.

    When the user hits the websphere app, they are forwarded from the login.jsp and the new URL has the port 100 written in it.
    ex: http://somehost.com/myApp and it returns http://somehost.com:100/myApp

    I understand this is a setting of AppServerPortPreference but I can't figure out how to change it. We are using the built-in webserver in Websphere, so there is no plugin-cfg.xml file that I can find.

    Please help, this is a frustrating problem!

  2. Re: AppServerPortPreference on Websphere 6.0.17

    This is a still a big problem for me... Has nobody else had this problem?? I must be doing something very wrong or something.

    Any help would be much appreciated!

  3. Re: AppServerPortPreference on Websphere 6.0.17

    desikage@yahoo.com wrote:
    > Hello,
    >
    > We have a virtual host running on port 100, and an external IP being translated from port 80 to this port 100.
    >
    > When the user hits the websphere app, they are forwarded from the login.jsp and the new URL has the port 100 written in it.
    > ex: http://somehost.com/myApp and it returns http://somehost.com:100/myApp
    >
    > I understand this is a setting of AppServerPortPreference but I can't figure out how to change it. We are using the built-in webserver in Websphere, so there is no plugin-cfg.xml file that I can find.
    >
    > Please help, this is a frustrating problem!


    I'm not sure I understand what the problem is here. Is your app
    listening on port 100? Does http://somehost.com:100/myApp work? What is
    causing the redirection to the new page? Is this an HTTP redirect
    (status code 3xx)?

    Given a url of http://somehost.com/myApp, a browser will connect to port
    80 and perform a GET request for "/myApp". The only way to tell a
    browser to connect to port 100 instead of port 80 is through the use of
    an explicit port in the URL, i.e. http://somehost.com:100/myApp.

    Alternatively, is this a transparent port forwarding implemented by the
    gateway between the browser and the app server install?

    Ian.

    --
    ian.burnett@uk.ibm.com :: IBM, Hursley, UK

  4. Re: AppServerPortPreference on Websphere 6.0.17

    > I'm not sure I understand what the problem is here.
    > Is your app
    > listening on port 100? Does
    > http://somehost.com:100/myApp work? What is
    > causing the redirection to the new page? Is this an
    > HTTP redirect
    > (status code 3xx)?
    >
    > Given a url of http://somehost.com/myApp, a browser
    > will connect to port
    > 80 and perform a GET request for "/myApp". The only
    > way to tell a
    > browser to connect to port 100 instead of port 80 is
    > through the use of
    > an explicit port in the URL, i.e.
    > http://somehost.com:100/myApp.
    >
    > Alternatively, is this a transparent port forwarding
    > implemented by the
    > gateway between the browser and the app server
    > install?
    >


    Thanks Ian, I'll try to be more specific:

    We have about 3 applications on our 1 server and they all run on different ports 81,100,101 on our internal 192 IP. Our firewall has 3 external IP address's and they translate port 80 to the 3 different ports internally.

    What happens is that occasionally, I'll hit http://somesite.com and it will translate into http://somesite.com:100 (depending on the application) and cause an error. I think the program is doing a forward in the java (it logs in to our Servlet, then forwards to a JSP after Login info is done), but it always uses relative URL's. Websphere seems to tack on the port 100, but not always, it works a lot of the time, especially if you go to a specific page and not just the directory.

    We've had these apps running since version 4, and the problem has only appeared in 6.0, and I can't figure out what the problem is.

    Thanks for any help, I greatly appreciate it! The Websphere setup is pretty much default, we didn't change much, don't use SSL, we do use LDAP though and basic security.

  5. Re: AppServerPortPreference on Websphere 6.0.17

    desikage@yahoo.com wrote:
    >> I'm not sure I understand what the problem is here.
    >> Is your app
    >> listening on port 100? Does
    >> http://somehost.com:100/myApp work? What is
    >> causing the redirection to the new page? Is this an
    >> HTTP redirect
    >> (status code 3xx)?
    >>
    >> Given a url of http://somehost.com/myApp, a browser
    >> will connect to port
    >> 80 and perform a GET request for "/myApp". The only
    >> way to tell a
    >> browser to connect to port 100 instead of port 80 is
    >> through the use of
    >> an explicit port in the URL, i.e.
    >> http://somehost.com:100/myApp.
    >>
    >> Alternatively, is this a transparent port forwarding
    >> implemented by the
    >> gateway between the browser and the app server
    >> install?
    >>

    >
    > Thanks Ian, I'll try to be more specific:
    >
    > We have about 3 applications on our 1 server and they all run on different ports 81,100,101 on our internal 192 IP. Our firewall has 3 external IP address's and they translate port 80 to the 3 different ports internally.
    >
    > What happens is that occasionally, I'll hit http://somesite.com and it will translate into http://somesite.com:100 (depending on the application) and cause an error. I think the program is doing a forward in the java (it logs in to our Servlet, then forwards to a JSP after Login info is done), but it always uses relative URL's. Websphere seems to tack on the port 100, but not always, it works a lot of the time, especially if you go to a specific page and not just the directory.
    >
    > We've had these apps running since version 4, and the problem has only appeared in 6.0, and I can't figure out what the problem is.
    >
    > Thanks for any help, I greatly appreciate it! The Websphere setup is pretty much default, we didn't change much, don't use SSL, we do use LDAP though and basic security.


    Thanks, I now understand your setup.

    I've had a poke around my WAS installation and I'm not sure that there's
    an equivalent of AppServerPortPreference for the built-in webcontainer.

    I'm curious, however, as to why this is intermittent. I would have
    expected it to consistently fail with if it were due to such a setting.

    Do all applications produce the same behaviour? What code is the
    application executing to bounce from the login servlet to the JSP?

    Ian.

    --
    ian.burnett@uk.ibm.com :: IBM, Hursley, UK

  6. Re: AppServerPortPreference on Websphere 6.0.17


    > Thanks, I now understand your setup.
    >
    > I've had a poke around my WAS installation and I'm
    > not sure that there's
    > an equivalent of AppServerPortPreference for the
    > built-in webcontainer.
    >
    > I'm curious, however, as to why this is intermittent.
    > I would have
    > expected it to consistently fail with if it were due
    > to such a setting.
    >
    > Do all applications produce the same behaviour? What
    > code is the
    > application executing to bounce from the login
    > servlet to the JSP?
    >


    There are 2 applications, and they behave exactly the same way. I've narrowed the problem further though to find out what specifically triggers it:

    the url http://mysite.com/myApp causes the problem, but http://mysite.com/myApp/ doesn't. Having the last / or even a specific page is ok, but if you just point at the directory, without the last slash, it will redirect to the port.

    Luckily our links point to a full URL, but some customers connect by just typing in the application without the slash, and it causes them errors.

    Perhaps this is indeed a bug and not something on my end? It does all this before it reaches any of my code.


  7. Re: AppServerPortPreference on Websphere 6.0.17

    desikage@yahoo.com wrote:
    >> Thanks, I now understand your setup.
    >>
    >> I've had a poke around my WAS installation and I'm
    >> not sure that there's
    >> an equivalent of AppServerPortPreference for the
    >> built-in webcontainer.
    >>
    >> I'm curious, however, as to why this is intermittent.
    >> I would have
    >> expected it to consistently fail with if it were due
    >> to such a setting.
    >>
    >> Do all applications produce the same behaviour? What
    >> code is the
    >> application executing to bounce from the login
    >> servlet to the JSP?
    >>

    >
    > There are 2 applications, and they behave exactly the same way. I've narrowed the problem further though to find out what specifically triggers it:
    >
    > the url http://mysite.com/myApp causes the problem, but http://mysite.com/myApp/ doesn't. Having the last / or even a specific page is ok, but if you just point at the directory, without the last slash, it will redirect to the port.
    >
    > Luckily our links point to a full URL, but some customers connect by just typing in the application without the slash, and it causes them errors.
    >
    > Perhaps this is indeed a bug and not something on my end? It does all this before it reaches any of my code.
    >


    Nope, sorry, out of ideas on how to resolve this. If the behaviour has
    changed between WebSphere AppServer releases and you believe it is
    incorrect, raise a PMR.

    Ian.

    --
    ian.burnett@uk.ibm.com :: IBM, Hursley, UK

+ Reply to Thread