BTW: did you check
/var/log/apache2/error.log

On Wed, Dec 9, 2015 at 4:55 PM, Dieter Wirz <[email protected]> wrote:
> Hi
> Apache in debian runs as user www-data. Has the user www-data the rights to 
> run
> 1. your program
> 2. access gpio
>
> You may test this if you su www-data, having no password:
> su # become root
> su www-data # become user www-data
> bash # as www-data has no shell
> /var/www/ledCtl $led $onOff
>
> HTH
>
>
> On Tue, Dec 8, 2015 at 8:02 PM, Marcelo Rodrigues <[email protected]> wrote:
>> Hi Everyone,
>>
>> I wrote a small C program for turning on/off the LEDs of the BeagleBone, it
>> works fine when I call it direct from command line. However, when I try to
>> call it from a PHP code it doesn't work.
>>
>> I'm using Linux beaglebone 3.8.13-bone71.1 and Apache2. The C program reads
>> 2 arguments from command line (led and onOff) that says which led to control
>> and its state. The exec line in the PHP code is the following:
>> exec("/var/www/ledCtl $led $onOff");
>>
>> Do you have any idea how can I find the reason this call doen'st work from
>> PHP code?
>>
>> Thanks in advance.
>>
>> --
>> For more options, visit http://beagleboard.org/discuss
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "BeagleBoard" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected].
>> For more options, visit https://groups.google.com/d/optout.

-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to