Re: [Koha] Common error handling in KOHA
Hi Barton Chittenden, Thanks for your reply. I am aware about the case you mentioned but that is not the thing. The scenario is different in my case , I need to navigate to a common error page when the application shows some error like "BEGIN failed--compilation aborted at /usr/share/koha/intranet/cgi-bin/events/add_event.pl line 172" You can see a sample error message which usually shows in KOHA for page not found - 404 error. Same as this , could you please help me out to redirect to a common page whenever the above mentioned error occurs. Regards, Rejeesh K.Nair On Thu, Feb 2, 2017 at 5:19 PM, Rejeesh K.Nair <rejeeshknair@gmail.com> wrote:
Hi Barton Chittenden,
Thanks for your reply.
I am aware about the case you mentioned but that is not the thing. The scenario is different in my case , I need to navigate to a common error page when the application shows some error like *"BEGIN failed--compilation aborted at /usr/share/koha/intranet/cgi-bin/events/add_event.pl <http://add_event.pl> line 172" *I have attached a sample error message which usually shows in KOHA for page not found - 404 error. Same as this , could you please help me out to redirect to a common page whenever the above mentioned error occurs.
Regards, Rejeesh K.Nair
On Thu, Feb 2, 2017 at 4:21 AM, Barton Chittenden < barton@bywatersolutions.com> wrote:
Rajeesh,
Perl errors are logged -- If you're on a package site running plack, the errors will be in
/var/log/koha/<instance>/plack-error.log.
If you're running a package site not on plack, look in
/var/log/koha/<instance>/intranet-error.log.
If you're running git, try
sudo grep ErrorLog /etc/apache2/sites-enabled/*.conf
... this should point you to the correct file.
On Wed, Feb 1, 2017 at 12:59 AM, Rejeesh K.Nair <rejeeshknair@gmail.com> wrote:
Hi All,
I need to implement common error handling page in KOHA.
The scenario is like , if we got an error which displays the folder structure see for example *"usr/share/koha/intranet/cgi-bin/tools/batch_delete_records.pl <http://batch_delete_records.pl> line 91". *Folder structure error message might be the security flaw of our application.
Is it possible to redirect it to a common page whenever this scenario occurs? Kindly help me out to resolve this.
Thanks & Regards,
Rejeesh K.Nair m: +91 (0) 9495316906 e: rejeeshknair@gmail.com <https://www.facebook.com/rejeeshnairk> <https://twitter.com/rejeeshkn air> <http://in.linkedin.com/in/rejeeshknair> <https://www.instagram.com/rejeeshknair/> _______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha
-- Thanks & Regards,
Rejeesh K.Nair m: +91 (0) 9495316906 <094953%2016906> e: rejeeshknair@gmail.com <https://www.facebook.com/rejeeshnairk> <https://twitter.com/rejeeshknair> <http://in.linkedin.com/in/rejeeshknair> <https://www.instagram.com/rejeeshknair/>
-- Thanks & Regards, Rejeesh K.Nair m: +91 (0) 9495316906 e: rejeeshknair@gmail.com <https://www.facebook.com/rejeeshnairk> <https://twitter.com/rejeeshknair> <http://in.linkedin.com/in/rejeeshknair> <https://www.instagram.com/rejeeshknair/>
Greetings, [SNIP]
when the application shows some error like "BEGIN failed--compilation aborted at /usr/share/koha/intranet/cgi-bin/events/add_event.pl line 172"
-- If you are giving an actual example of an error message you see, then you should be aware that no such code exists in the Koha code-base. I just checked master: $ git grep add_event
could you please help me out to redirect to a common page whenever the above mentioned error occurs.
In a standard installation the apache site is enabled and the configuration file has: ErrorDocument 400 /cgi-bin/koha/errors/400.pl ErrorDocument 401 /cgi-bin/koha/errors/401.pl ErrorDocument 403 /cgi-bin/koha/errors/403.pl ErrorDocument 404 /cgi-bin/koha/errors/404.pl ErrorDocument 500 /cgi-bin/koha/errors/500.pl You could modify the apache configuration file to point elsewhere, but that isn't going to catch the specific "failed--compilation" case only. Contact the person who customized this file. If you encounter this type of error in your logs, you should be reporting them on bugzilla. Though, again, if these are not part of the Koha code-base, you will need to contact the person who wrote them in the first place. GPML, Mark Tompsett
Hi Mark, As you said, *add_event.pl <http://add_event.pl> *is a custom file which is created by us. Its not a KOHA file. Please help me out to solve aforementioned issue, Is there any way to hide the errors / crash occurring in our KOHA application , which means users should not be able to view the errors in frontend. We have a function like "error_reporting(0)" in PHP to hide the errors happening like this, so is there anything like this in KOHA-Perl. Regards, Rejeesh K.Nair On Fri, Feb 3, 2017 at 11:09 AM, Mark Tompsett <mtompset@hotmail.com> wrote:
Greetings,
[SNIP]
when the application shows some error like "BEGIN failed--compilation aborted at /usr/share/koha/intranet/cgi-bin/events/add_event.pl line 172"
-- If you are giving an actual example of an error message you see, then you should be aware that no such code exists in the Koha code-base. I just checked master: $ git grep add_event
could you please help me out to redirect to a common page whenever the above mentioned error occurs.
In a standard installation the apache site is enabled and the configuration file has:
ErrorDocument 400 /cgi-bin/koha/errors/400.pl ErrorDocument 401 /cgi-bin/koha/errors/401.pl ErrorDocument 403 /cgi-bin/koha/errors/403.pl ErrorDocument 404 /cgi-bin/koha/errors/404.pl ErrorDocument 500 /cgi-bin/koha/errors/500.pl
You could modify the apache configuration file to point elsewhere, but that isn't going to catch the specific "failed--compilation" case only. Contact the person who customized this file.
If you encounter this type of error in your logs, you should be reporting them on bugzilla. Though, again, if these are not part of the Koha code-base, you will need to contact the person who wrote them in the first place.
GPML, Mark Tompsett
_______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha
-- Thanks & Regards, Rejeesh K.Nair m: +91 (0) 9495316906 e: rejeeshknair@gmail.com <https://www.facebook.com/rejeeshnairk> <https://twitter.com/rejeeshknair> <http://in.linkedin.com/in/rejeeshknair> <https://www.instagram.com/rejeeshknair/>
Hi All, As you said, *add_event.pl <http://add_event.pl/> *is a custom file which is created by us. Its not a KOHA file. Please help me out to solve aforementioned issue, Is there any way to hide the errors / crash occurring in our KOHA application , which means users should not be able to view the errors in frontend. We have a function like "error_reporting(0)" in PHP to hide the errors happening like this, so is there anything like this in KOHA-Perl. Can someone help me to solve this? Regards, Rejeesh K.Nair On Fri, Feb 3, 2017 at 3:54 PM, Rejeesh K.Nair <rejeeshknair@gmail.com> wrote:
Hi Mark,
As you said, *add_event.pl <http://add_event.pl> *is a custom file which is created by us. Its not a KOHA file. Please help me out to solve aforementioned issue, Is there any way to hide the errors / crash occurring in our KOHA application , which means users should not be able to view the errors in frontend.
We have a function like "error_reporting(0)" in PHP to hide the errors happening like this, so is there anything like this in KOHA-Perl.
Regards, Rejeesh K.Nair
On Fri, Feb 3, 2017 at 11:09 AM, Mark Tompsett <mtompset@hotmail.com> wrote:
Greetings,
[SNIP]
when the application shows some error like "BEGIN failed--compilation aborted at /usr/share/koha/intranet/cgi-bin/events/add_event.pl line 172"
-- If you are giving an actual example of an error message you see, then you should be aware that no such code exists in the Koha code-base. I just checked master: $ git grep add_event
could you please help me out to redirect to a common page whenever the above mentioned error occurs.
In a standard installation the apache site is enabled and the configuration file has:
ErrorDocument 400 /cgi-bin/koha/errors/400.pl ErrorDocument 401 /cgi-bin/koha/errors/401.pl ErrorDocument 403 /cgi-bin/koha/errors/403.pl ErrorDocument 404 /cgi-bin/koha/errors/404.pl ErrorDocument 500 /cgi-bin/koha/errors/500.pl
You could modify the apache configuration file to point elsewhere, but that isn't going to catch the specific "failed--compilation" case only. Contact the person who customized this file.
If you encounter this type of error in your logs, you should be reporting them on bugzilla. Though, again, if these are not part of the Koha code-base, you will need to contact the person who wrote them in the first place.
GPML, Mark Tompsett
_______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha
-- Thanks & Regards,
Rejeesh K.Nair m: +91 (0) 9495316906 <094953%2016906> e: rejeeshknair@gmail.com <https://www.facebook.com/rejeeshnairk> <https://twitter.com/rejeeshknair> <http://in.linkedin.com/in/rejeeshknair> <https://www.instagram.com/rejeeshknair/>
-- Thanks & Regards, Rejeesh K.Nair m: +91 (0) 9495316906 e: rejeeshknair@gmail.com <https://www.facebook.com/rejeeshnairk> <https://twitter.com/rejeeshknair> <http://in.linkedin.com/in/rejeeshknair> <https://www.instagram.com/rejeeshknair/>
participants (2)
-
Mark Tompsett -
Rejeesh K.Nair