Jump to content

Continuous random problem when close session and reopen it.


LJDP
 Share

Recommended Posts

Continuous random problem when close session and reopen it.

Try close sesión with:

UniSession.AddJS('location.href=''http://google.com''');

because need redirect navigation to an other page

and with

UniApplication.Terminate('Closed application');

I try windo3s2088 server with IIS7 and Apache 2.2.

An random problem persist with this log:

From Unigui:

ProgramWeb: 000003B0: 14:33:48HttpExtensionProc:EAccessViolation : Access violation at address 01B6E044 in module 'ProgramWeb.dll'. Read of address 0000005C

From Apache 2.2 server

[Mon Jan 23 14:26:31 2012] [notice] Parent: Received restart signal -- Restarting the server.
[Mon Jan 23 14:26:31 2012] [notice] Child 2852: Exit event signaled. Child process is ending.
httpd.exe: Could not reliably determine the server's fully qualified domain name, using 192.168.3.2 for ServerName
[Mon Jan 23 14:26:31 2012] [notice] Apache/2.2.21 (Win32) configured -- resuming normal operations
[Mon Jan 23 14:26:31 2012] [notice] Server built: Sep  9 2011 10:26:10
[Mon Jan 23 14:26:31 2012] [notice] Parent: Created child process 228
httpd.exe: Could not reliably determine the server's fully qualified domain name, using 192.168.3.2 for ServerName
httpd.exe: Could not reliably determine the server's fully qualified domain name, using 192.168.3.2 for ServerName
[Mon Jan 23 14:26:32 2012] [notice] Child 228: Child process is running
[Mon Jan 23 14:26:32 2012] [notice] Child 228: Acquired the start mutex.
[Mon Jan 23 14:26:32 2012] [notice] Child 228: Starting 64 worker threads.
[Mon Jan 23 14:26:32 2012] [notice] Child 2852: Released the start mutex
[Mon Jan 23 14:26:33 2012] [notice] Child 2852: All worker threads have exited.
[Mon Jan 23 14:26:33 2012] [notice] Child 2852: Child process is exiting
[Mon Jan 23 14:26:33 2012] [notice] Child 228: Starting thread to listen on port 80.
[Mon Jan 23 14:27:36 2012] [error] [client 192.168.4.4] C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico is not executable; ensure interpreted scripts have "#!" or "'!" first line, referer: http://192.168.3.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:27:36 2012] [error] [client 192.168.4.4] (9)Bad file descriptor: don't know how to spawn child process: C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico, referer: http://192.168.3.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:27:38 2012] [error] [client 192.168.4.4] C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico is not executable; ensure interpreted scripts have "#!" or "'!" first line, referer: http://192.168.3.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:27:38 2012] [error] [client 192.168.4.4] (9)Bad file descriptor: don't know how to spawn child process: C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico, referer: http://192.168.3.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:27:38 2012] [error] [client 192.168.4.4] C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico is not executable; ensure interpreted scripts have "#!" or "'!" first line, referer: http://192.168.3.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:27:38 2012] [error] [client 192.168.4.4] (9)Bad file descriptor: don't know how to spawn child process: C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico, referer: http://192.168.3.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:27:42 2012] [error] [client 192.168.4.4] C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico is not executable; ensure interpreted scripts have "#!" or "'!" first line, referer: http://192.168.3.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:27:42 2012] [error] [client 192.168.4.4] (9)Bad file descriptor: don't know how to spawn child process: C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico, referer: http://192.168.3.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:27:43 2012] [error] [client 192.168.4.4] C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico is not executable; ensure interpreted scripts have "#!" or "'!" first line, referer: http://192.168.3.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:27:43 2012] [error] [client 192.168.4.4] (9)Bad file descriptor: don't know how to spawn child process: C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico, referer: http://192.168.3.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:28:00 2012] [error] [client 127.0.0.1] C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico is not executable; ensure interpreted scripts have "#!" or "'!" first line, referer: http://localhost/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:28:00 2012] [error] [client 127.0.0.1] (9)Bad file descriptor: don't know how to spawn child process: C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico, referer: http://localhost/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:28:02 2012] [error] [client 192.168.4.4] C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico is not executable; ensure interpreted scripts have "#!" or "'!" first line, referer: http://192.168.3.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:28:02 2012] [error] [client 192.168.4.4] (9)Bad file descriptor: don't know how to spawn child process: C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico, referer: http://192.168.3.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:30:12 2012] [error] [client 127.0.0.1] C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico is not executable; ensure interpreted scripts have "#!" or "'!" first line, referer: http://localhost/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:30:12 2012] [error] [client 127.0.0.1] (9)Bad file descriptor: don't know how to spawn child process: C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/img/80.ico, referer: http://localhost/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:30:19 2012] [error] [client 192.168.4.4] Premature end of script headers: ProgramWeb.dll
[Mon Jan 23 14:30:19 2012] [warn] [client 192.168.4.4] ISAPI: HSE_STATUS_ERROR result from HttpExtensionProc(): C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:30:23 2012] [error] [client 192.168.4.4] Premature end of script headers: ProgramWeb.dll
[Mon Jan 23 14:30:23 2012] [warn] [client 192.168.4.4] ISAPI: HSE_STATUS_ERROR result from HttpExtensionProc(): C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:31:08 2012] [error] [client 192.168.4.4] Premature end of script headers: ProgramWeb.dll
[Mon Jan 23 14:31:08 2012] [warn] [client 192.168.4.4] ISAPI: HSE_STATUS_ERROR result from HttpExtensionProc(): C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:31:18 2012] [error] [client 192.168.3.2] Premature end of script headers: ProgramWeb.dll
[Mon Jan 23 14:31:18 2012] [warn] [client 192.168.3.2] ISAPI: HSE_STATUS_ERROR result from HttpExtensionProc(): C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/ProgramWeb.dll
[Mon Jan 23 14:31:18 2012] [error] [client 192.168.3.2] File does not exist: C:/Archivos de programa/Apache Software Foundation/Apache2.2/htdocs/favicon.ico
[Mon Jan 23 14:31:21 2012] [error] [client 192.168.3.2] File does not exist: C:/Archivos de programa/Apache Software Foundation/Apache2.2/htdocs/favicon.ico

I see this thred about ISAPI / Multi processor problem and I do not know if this may be the cause:

http://www.delphigroups.info/2/5/337564.html

I use IbObjects. See http://www.ibobjects.../ibowhatis.html

 

Multi-tier Development

IB Objects caters admirably for middle-tier application server, CGI, WIN-CGI and ISAPI styles of application development, where a tight, stable connectivity core and high performance are demanded. These components are well-proven in multi-threading applications. Under most circumstances IBO handles sessions in multi-threaded apps automatically via thread local storage mechanisms. In applications where explicit session control is required, such as an ISAPI module, IBO's TIB_Session provides the necessary isolation.

IBO 4 introduces explicit support for connection pooling, very suitable for ISAPI applications, because each web hit can close its own connection if it used one; and connection handles need not be wasted on hits that turn out not to need a connection.

What's your opinion.

Thanks.

Link to comment
Share on other sites

Navigating from uniGUI to another web page

This close actual session?.

It´s a safe method for terminate user session?

About this:

You must start a new session.

With that method, and that unit: Main.oncreate, MainModule.oncreate?

Thx.

Link to comment
Share on other sites

  • Administrators

This close actual session?.

It´s a safe method for terminate user session?

About this:

You must start a new session.

With that method, and that unit: Main.oncreate, MainModule.oncreate?

Thx.

 

What functionality do you want to achieve? I understand that you want to leave a uniGUI session by navigating to another page then return back to it. Am I correct?

Link to comment
Share on other sites

My scenario is:

1. User close sesión and redirect to an other url.

With this method close sessión an redirect or session stop when timeout?

procedure TMainForm.UniButton2Click(Sender: TObject);
begin
 UniSession.AddJS('location.href="http://www.google.com"');
end;

2. User want return to de unigui page. It´s needed manual start new session or it´s automatic?

In case of manual start: where and how I can start a new sessión.

In this second point I get the random error of first post. Not always, only sometimes.

Link to comment
Share on other sites

Besides, after this errror 500 I need Restart the web server (IIS 7 or Apache 2.2) because I get the message:

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Link to comment
Share on other sites

  • Administrators

You need to reduce the problem to a specific point. I have no idea what your app internally do or what components it use.

There is no way for a uniGUI DLL to cause a 500 error. Especially on IIS7 where isapi apps run in isolated pools. An isapi app can crash, but it is very unlikely to crash the web server itself. In worst case you can re-run app by recycling the related pool and there is no need to restart the web server.

 

As I told you need to simply your app and observe the exact point where problem starts. For example what happens if you don't redirect your app to another web page?

Link to comment
Share on other sites

I'm doing tests and refactor the application entry, so far with little success, but still trying ...

One question:

With this method close sessión an redirect or session stop when timeout?

procedure TMainForm.UniButton2Click(Sender: TObject);
begin
 UniSession.AddJS('location.href="http://www.google.com"');
end;

Link to comment
Share on other sites

It is possible that if the user re-enters the page before of time out produce the error I'm trying to solve?

I do not mean to use the Back button, but by directly entering the url or clicking on a link from another page.

This is the log:

[Wed Jan 25 10:05:34 2012] [error] [client 192.168.4.4] Premature end of script headers: Programa.dll
[Wed Jan 25 10:05:34 2012] [warn] [client 192.168.4.4] ISAPI: HSE_STATUS_ERROR result from HttpExtensionProc(): C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/Programa.dll
[Wed Jan 25 10:06:03 2012] [error] [client 80.24.113.46] Premature end of script headers: Programa.dll
[Wed Jan 25 10:06:03 2012] [warn] [client 80.24.113.46] ISAPI: HSE_STATUS_ERROR result from HttpExtensionProc(): C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/Programa.dll
[Wed Jan 25 10:07:13 2012] [error] [client 127.0.0.1] Premature end of script headers: programa.dll, referer: http://localhost/cgi-bin/programa.dll
[Wed Jan 25 10:07:13 2012] [warn] [client 127.0.0.1] ISAPI: HSE_STATUS_ERROR result from HttpExtensionProc(): C:/Archivos de programa/Apache Software Foundation/Apache2.2/cgi-bin/programa.dll, referer: http://localhost/cgi-bin/programa.dll

Link to comment
Share on other sites

Sometimes yes and sometimes not. But the error always occurs at startup.

It has happened: localhost be working normally. On a client has error on startup and this client can not work until you restart the isapi. I'm still working normally on localhost and only I have problems if I close the application and try open it again.

It's very strange... It takes 4 days trying to fix it but ...

Link to comment
Share on other sites

I change

  //UniSession.AddJS('location.href=''http://google.com'''); 

for

  uniapplication.terminate; 

and the result is slightly better but still failed.

To give you an idea of ​​the problem I sent an email to info@unicui.com with pdf with the events that occurs on the server.

You can see them and give me your opinion?

Thx.

Link to comment
Share on other sites

  • Administrators

I change

  //UniSession.AddJS('location.href=''http://google.com'''); 

for

  uniapplication.terminate; 

and the result is slightly better but still failed.

 

Simply saying it failed gives me zero clue about the issue. It failed but how? When? Code sample?

 

To give you an idea of ​​the problem I sent an email to info@unicui.com with pdf with the events that occurs on the server.

You can see them and give me your opinion?

Thx.

 

Please send to:

info@fmsoft.net

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...