[ecasound] php-triggered interactive script terminates

From: spencer marsden <mildmanjan@email-addr-hidden>
Date: Tue Sep 25 2012 - 13:51:04 EEST

Hi,
apologies for incorrect nomenclature of procedures

 Problem: wanting to launch ecasound engine in interactive mode from php, with jack_transport controlling playback.

I have a php script that calls shell scripts which trigger playback of ecasound correctly. Ecasound is using jack, which I have invoked as www-data.
scripts such as

#!/bin/bash
# play
set -x on
TERM=linux
export TERM
ecasound -i /var/www/upload/*.wav -o jack,system
set -x off

work fine, both from terminal (as www-data) and exec from php generated web page:

else if
      ($_GET['action'] == "play") {
         $command = '/var/www/TRANSPORT/linuxplay.sh';
      //$output = passthru($command . ' 2>&1 &');
$output = exec($command . ' 2>&1', $output_array, $return_val);

so far so good, but the following script:

#!/bin/bash
# engine_start
set -x on
TERM=linux
export TERM
ecasound -c -i /var/www/upload/*.wav -o jack,system -G:jack,hereiam,recv -E engine-launch -K ;
set -x off

 only works invoked from terminal (as www-data). That is to say I see the connection "hereiam" in qjackctl's connection kit, and jack_transport (again, invoked by www-data) controls it just fine.
>>When invoked by php, the connection "hereiam" appears momentarily in qjackctl's connection kit and then disappears after a second.

Its php5, linux mint 12. My var/log/apache/error log gives:

+ set -x off
+ TERM=linux
+ export TERM
+ ecasound -c -i /var/www/upload/Fournobletruths-03.wav -o jack,system -G:jack,hereiam,recv -E engine-launch -K
Cannot lock down 82241434 byte memory area (Cannot allocate memory)
Cannot lock down 82241434 byte memory area (Cannot allocate memory)
+ set -x off

any help appreciated
                                               

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/

_______________________________________________
Ecasound-list mailing list
Ecasound-list@email-addr-hidden
https://lists.sourceforge.net/lists/listinfo/ecasound-list
Received on Tue Sep 25 16:15:02 2012

This archive was generated by hypermail 2.1.8 : Tue Sep 25 2012 - 16:15:03 EEST