Using mojoportal in a NAT Network.

This is the place to report bugs and get support. When posting in this forum, please always provide as much detail as possible.

Please do not report problems with a custom build or custom code in this forum. If you are producing your own build from the source code and have problems or questions, ask in the developer forum, do not report it as a bug.

This is the place to report bugs and get support

When posting in this forum, please try to provide as many relevant details as possible. Particularly the following:

  • What operating system were you running when the bug appeared?
  • What database platform is your site using?
  • What version of mojoPortal are you running?
  • What version of .NET do you use?
  • What steps are necessary to reproduce the issue? Compare expected results vs actual results.
Please do not report problems with a custom build or custom code in this forum. If you are producing your own build from the source code and have problems or questions, ask in the developer forum.
This thread is closed to new posts. You must sign in to post in the forums.
8/8/2011 1:42:02 AM
Gravatar
Total Posts 550

Using mojoportal in a NAT Network.

Hi Joe,

The SiteUtils.GetCurrentPageUrl() method not return correct domain name or translated IP address of the web server. It return the local IP address of the web server. For example by clicking the Cancel link in   ModuleSetting.aspx page redirects to 192.168.x.x (the local IP of web server machine), while we expected domain name or translated IP address.

Best,

Asad

8/8/2011 11:41:47 AM
Gravatar
Total Posts 2239

Re: Using mojoportal in a NAT Network.

Hi Asad,

I am not sure about the internal workings of mojoPortal on this one but I can say that all of the sites I host are behind a firewall which uses NAT and none of the sites have this issue. If there is some kind of reverse-nat, that might cause an issue if it is configured improperly but it wouldn't be an issue if properly configured.

In short, I suggest looking at your network configuration rather than mojoPortal for a solution to this problem.

HTH,
Joe D.

1/23/2012 3:37:58 AM
Gravatar
Total Posts 87

Re: Using mojoportal in a NAT Network.

Hi,

I have some similar problem: the website is in intranet network and some users access it using local IP like 192.168.....  but when i try to access the website from outside - sometimes !!! - i see some odd things - webpages looks incorrect and some links are not working and when i look in the HTML code i see 192.168.... references to css and some other things, then i login via rdp to the server, restart the web-application and everything works well. May be someone can advise what to change in my website configureation? may be IIS? i need both types of users external and internal to access the site but sometimes it falls out.

Thanks,

Victor 

1/23/2012 1:25:45 PM
Gravatar
Total Posts 1203
Proud member of the mojoPortal team

Help support mojoPortal!
Add-on modules

Re: Using mojoportal in a NAT Network.

I'd recommend using the preferred host name setting, if possible--that way you will be using a known URL for all site visitors (this URL must resolve correctly for both your internal and external DNS users, of course). Also make sure all of your links are relative to the site root and not hardcoded with the host name/IP address.

If you have a development server you want to mirror production but not force host name, add AllowForcingPreferredHostName = false to that site's user.config.

Hope that helps,

Jamie

1/23/2012 1:52:11 PM
Gravatar
Total Posts 18439

Re: Using mojoportal in a NAT Network.

Hi Victor,

If you are able to work from the source code, you should get the very latest code and see if it works better. Previously we were using the siteSettings.SiteRoot property in a number of places. The problem with that is that siteSettings is cached (for 5 minutes at a time by default) so if it got cached using one url then that url would be the cached site root and if a request comes in over the alternate url that cached value may not be correct. I've deprecated that property on SiteSettings and changed all the places where is was used to instead use SiteUtils.GetNavigationSiteRoot(). This should make sure that the site root is always calculated based on the current request.

If you are not able to update from source code, I will probably make a new release on Thursday.

I'm not 100% sure this is the cause of the problem, but it could very well be.

Hope that helps,

Joe

1/23/2012 2:26:11 PM
Gravatar
Total Posts 550

Re: Using mojoportal in a NAT Network.

Hi Joe,

Your right.I did started this thread about 5 month ago, I traced it and what was happened is what that you mentioned. But after updating source code and publish it again in previous week it works fine.

Best,

Asad

1/23/2012 2:36:03 PM
Gravatar
Total Posts 18439

Re: Using mojoportal in a NAT Network.

Hi Asad,

I made these changes this morning so if updating before solved the problem for you it must have been a different problem or a different cause.

Best,

Joe

1/23/2012 2:54:13 PM
Gravatar
Total Posts 550

Re: Using mojoportal in a NAT Network.

Excuse me I forget that my brother correct it in locally in our case.

Best,

Asad

You must sign in to post in the forums. This thread is closed to new posts.