• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Quick Question: IIS and memory leaks

Cogman

Lifer
Dumb question. I know of a memory leak in an app that I'm developing that will be ran from IIS. The application won't run for long, and the leak won't be too big (couple of kb at the most, and shouldn't be in a looping situation). However, it will be a PITA to fix (its a linked list, tree, structure thing from libxml if you are curious).

Does IIS clear the memory from the CGI applications that finish executing. In other words, does it use windows to execute the application (which automatically releases the heap when the app finishes executing). If so, I don't really have a problem, and won't worry about it. If not, then I need to go through and tackle this PITA.
 
Depends on what kind of application it is. If it's an asp.net app then it gets loaded into an appdomain, and if that domain runs out of memory it will be recycled. If you're spawning an executable then any memory it allocates during execution will be freed when it exits. DLLs can be a more complicated story, but probably will get loaded into the appdomain and end up being treated like the asp.net case. Not 100% sure though.
 
You'll most likely have to resolve the leak. Unless you've done some tweaking to the IIS object cache settings, IIS will caching regardless of what it's hosting and this could lead to IIS itself crashing.
 
Depends on what kind of application it is. If it's an asp.net app then it gets loaded into an appdomain, and if that domain runs out of memory it will be recycled. If you're spawning an executable then any memory it allocates during execution will be freed when it exits. DLLs can be a more complicated story, but probably will get loaded into the appdomain and end up being treated like the asp.net case. Not 100% sure though.
Well, I decided to be less lazy, I threw in a 1gb memory leak (go big or go home 🙂) at the start of the app. Turns out IIS spawns a new executable when dealing with compiled CGI programs (memory spiked, but didn't stay high). The leak stays in.
 
While on the topic of web servers, I've been playing around with setting one up (mostly a personal deal). I'm at my parents house over the summer and they get their internet though an Alltel/VZW aircard. My web server works on the LAN but not from a remote connection or via the WAN IP.

I'm guessing that the ISP is blocking the traffic so you don't have people like me hosting a website on a 3G connection, but is there a way to confirm these suspicions?
 
While on the topic of web servers, I've been playing around with setting one up (mostly a personal deal). I'm at my parents house over the summer and they get their internet though an Alltel/VZW aircard. My web server works on the LAN but not from a remote connection or via the WAN IP.

I'm guessing that the ISP is blocking the traffic so you don't have people like me hosting a website on a 3G connection, but is there a way to confirm these suspicions?
Its more likely that your router is filtering out incoming requests. Working with home routers and webservers is a PITA.
 
Its more likely that your router is filtering out incoming requests. Working with home routers and webservers is a PITA.

I've tried DMZ and port forwarding but it doesn't help. It's a WRT54G and there are quite a few guides that outline the settings required, which is pretty much just forward TCP port 80 to the LAN IP of the web server. I'll probably just configure the web server on a different port later to see if I'm right.
 
No need to change the server, just change the port the firewall is forwarding from. Instead of external:80->internal:80 change your port forward to do external:8080->internal:80
 
No need to change the server, just change the port the firewall is forwarding from. Instead of external:80->internal:80 change your port forward to do external:8080->internal:80

But you'll probably want to try something other than 8080, if they're filtering 80 they're probably filtering 8080 as well.
 
Back
Top