Subject: Re[2]: php cli, mysql as non-root (solved)
To: Zafer Aydogan <zafer@aydogan.de>
From: None <netbsd-users@rmroppert.de>
List: pkgsrc-users
Date: 08/14/2007 21:48:00
Hello Zafer Aydogan,

am Dienstag, 14. August 2007 um 20:55 schrieben Sie:

> 2007/8/14, netbsd-users@rmroppert.de <netbsd-users@rmroppert.de>:
>> an customer wants to run an php script as cron-job.
>> In this script there is an mysql query.
>>
>> If i run the script from the commandline or as a cronjob as "root". it
>> works.
>> If i run it as the coustomers user. There is the error:
>>
...
>> I use netbsd 3.1,
>>
>> PHP 4.4.7 (cli) (built: Jul  5 2007 21:24:42)
>> Copyright (c) 1997-2007 The PHP Group
>> Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies
>> with eAccelerator v0.9.5, Copyright (c) 2004-2006 eAccelerator, by eAccelerator
>>
>> Has someone an idea how i get the php script working as cron for the user?

> do you have installed databases/php-mysql ?

> I have a daily php cronjob (running as a user) that does mysql queries
> without any problems.
> But i'm running php5/mysql5

thank you for your answer.
It was my mistake. An directory obove the php.ini
file has not enough rights.
So all users in "wheel" could read it, but not the customer user.
Sorry.

Reinhold



-- 
R.M.ROPPERT