[Watford] PHP - mail() function / Distro Suse10.3

Neel Upadhyaya bahulneel at gmail.com
Mon Dec 3 15:45:45 GMT 2007


Regarding the off status of display_errors, check the contents of
/etc/php5/conf.d as one of the file here may be unsetting it.  The
othe option is to put:
ini_set('display_errors', true); near the head of your php script.
This would be my personal preference as you then have stricter control
over error reporting.

Also the default location of php errors is the apache error log, you
can locate this in your apache config by looking for the ErrorLog
directive.  Another way to locate the file is by using the lsof
command:

as root:
lsof 2> /dev/null |grep "\(httpd\|apache\).*error"

-- 
MCSE is to computers as McDonalds Certified Chef is to fine cuisine.

On 03/12/2007, walt <walt at helvatron.co.uk> wrote:
> Sorry Alain, Distro is Suse 10.3.  Wont happen again.
>
> I ran that script and its very comprehensive.  The php.ini is in
> /etc/php5/apache2.  Copy attached.
>
> One interesting bit is that I setup:
>                 display_errors = on
> in the correct php.ini but phpinfo() still reports as off.  I rebooted after
> checking the ini file and its still reported as off.
>
> I have also set the sendmail_from directive to may email address but still
> comes up as no value.
>
> Error_log = php_errors but I have no idea where the file ends up. In any
> case phpinfo() still reports it as no value.
>
> Thanks for your help.
> Walter
>
> -----Original Message-----
> From: watford-bounces at mailman.lug.org.uk
> [mailto:watford-bounces at mailman.lug.org.uk] On Behalf Of Alain Williams
> Sent: 03 December 2007 11:30
> To: watford at mailman.lug.org.uk
> Subject: Re: [Watford] PHP - mail() function
>
> On Mon, Dec 03, 2007 at 09:40:14AM -0000, walt wrote:
> > Thanks Alain,
> >
> > I was looking for the logs but Linux is like a rabbit warren, I can never
> > find anything or I have to read reams of stuff to track it down. Which is
> > why I asked the question,  are there any logs somewhere.
>
> Depends on which distro you are using (do tell us) as to exactly they are,
> but start by looking under /var/log.
>
> > I am using a web form to access sendmail via mail().
> >
> > On the other hand I have found a command that allows testing of sendmail:
> >  /usr/sbin/sendmail -bv -v -oL10 recipient at domain.net
> > I ran it and it tells me that sendmail is functional that the address is
> > deliverable using my ISPs relay host.
> >
> > If I then tried the next test:
> >       /usr/sbin/sendmail -v  walt at helvatron.co.uk
> >       This is a test
> >       .
> > I get:
> > walt at helvatron.co.uk... Connecting to [127.0.0.1] via relay...
>
> You don't want to do that ...
>
> > And after all that I managed to track down the log under /var/log/mail
> which
> > contains no entries about mail() attempting to connect.
> >
> > I have no idea yet where to look for the queue (MTA) file/folder/logs.
>
>
>
> > There are 2 php.ini, /etc/php5/apache2  &  /etc/php5/cli.  I am assuming
> its
> > the one in apache2 I need to change and I have set 'error_reporting=E_ALL'
> .
>
> Set:
>         display_errors = on
>         log_errors = On
>         error_reporting=E_ALL | E_STRICT
>
> What is the value of error_log ?
>
> Run a php script with: <?php phpinfo(); ?>
> That will tell you which php.ini you are using.
> Looks as if you are using debian (or ubuntu) ??
>
> --
> Alain Williams
> Linux Consultant - Mail systems, Web sites, Networking, Programmer, IT
> Lecturer.
> +44 (0) 787 668 0256  http://www.phcomp.co.uk/
> Parliament Hill Computers Ltd. Registration Information:
> http://www.phcomp.co.uk/contact.php
> Chairman of UKUUG: http://www.ukuug.org/
> #include <std_disclaimer.h>
>
> _______________________________________________
> Watford mailing list
> Watford at mailman.lug.org.uk
> https://mailman.lug.org.uk/mailman/listinfo/watford
>
> _______________________________________________
> Watford mailing list
> Watford at mailman.lug.org.uk
> https://mailman.lug.org.uk/mailman/listinfo/watford
>
>
>



More information about the Watford mailing list