yeah, if you look at the thread you will see that I've already done this.
On Wed, 21 Sep 2005, adriano ghezzi wrote:
did you tried to run the script from the shell as www-data user ?
(if not su www-data) an then run the script may be something regarding
permission
hth
2005/9/21, John Nichel
did you tried to run the script from the shell as www-data user ?
(if not su www-data) an then run the script may be something regarding
permission
hth
2005/9/21, John Nichel <[EMAIL PROTECTED]>:
> [EMAIL PROTECTED] wrote:
> > I have two programs on two servers, and they both have similar proble
php places uploaded files in the /tmp directory with a unique name, and
when I copy them to my directory, I also guarantee a unique name for them.
I have verified that this is all working. I've patched this with a cron
job that runs every minute, but it really should happen in php, so that
the
I am assuming that you get hold of the file through uploading it, correct?
So, when it fails maybe another upload (i.e. script invocation) is happening
and the previous file gets lost/corrupted/whatever. Try to move the file to
another dir (maybe /tmp) with a random name and see what happens.
An
Yes, but that's been done. Since these are shared servers, on one I am
logged in as the user the web server is running as, on the other I can't
su to nobody, but were there permissions errors, I would have been able to
capture them. If permissions caused this, it would fail every time, since
[EMAIL PROTECTED] wrote:
> You're telling me. That's why I think php or apache kills it.
I didn't really follow this, but typically you can debug exec problems
from the command line by switching to the web server user id and running
the exact same command.
-Rasmus
--
PHP General Mailing List (
You're telling me. That's why I think php or apache kills it.
On Wed, 21 Sep 2005, John Nichel wrote:
[EMAIL PROTECTED] wrote:
convert doesn't produce any output regardless of whether it works or not.
Ecasound produces output when it works, but when it doesn't, it produces no
output. Using
[EMAIL PROTECTED] wrote:
convert doesn't produce any output regardless of whether it works or
not. Ecasound produces output when it works, but when it doesn't, it
produces no output. Using php tricks to capture standard error also
produces no output.
Hopefully somebody else on the list can h
convert doesn't produce any output regardless of whether it works or not.
Ecasound produces output when it works, but when it doesn't, it produces
no output. Using php tricks to capture standard error also produces no
output.
On Wed, 21 Sep 2005, John Nichel wrote:
[EMAIL PROTECTED] wrot
[EMAIL PROTECTED] wrote:
as I said, the default timout is 300 seconds, a lot longer than my
program takes to run, and I am pretty certain that if timeout were
triggered, I'd see it in the client.
Yeah, I'm using a browser on the php page, and everything seems to
function fine from the browser
as I said, the default timout is 300 seconds, a lot longer than my program
takes to run, and I am pretty certain that if timeout were triggered, I'd
see it in the client.
Yeah, I'm using a browser on the php page, and everything seems to
function fine from the browser to the server, it's after
[EMAIL PROTECTED] wrote:
timeout isn't being used on either of these machines, and as far as I
read it, the timeout directive would make the web server fail, producing
an apache error or some strange behaviour on the client end. Neither of
How is timeout _not_ being used? It's a core directi
timeout isn't being used on either of these machines, and as far as I read
it, the timeout directive would make the web server fail, producing an
apache error or some strange behaviour on the client end. Neither of
these happens, the php script completes normally, but the exec command
(and onl
[EMAIL PROTECTED] wrote:
the logs say things like:
/kunden/homepages/12/d117065027/htdocs/software/ImageMagick-6.2.3/utilities/convert
ib_images/Other_Spices_Basic_004.jpg -resize 180x120
ib_images/Other_Spices_Basic_004_thumb.jpg
this is a command I'm trying to get php to run. I then cut an
the logs say things like:
/kunden/homepages/12/d117065027/htdocs/software/ImageMagick-6.2.3/utilities/convert
ib_images/Other_Spices_Basic_004.jpg -resize 180x120 ib_images/Other_Spices_Basic_004_thumb.jpg
this is a command I'm trying to get php to run. I then cut and paste it
to the command
[EMAIL PROTECTED] wrote:
If the web server didn't have permission to execute the app, it would
NEVER execute the app, not execute it some of the time. In fact, it
ALWAYS executes the app, it just doesn't always allow it to finish.
I log all attempts to run these apps in order to debug, so I k
If the web server didn't have permission to execute the app, it would
NEVER execute the app, not execute it some of the time. In fact, it
ALWAYS executes the app, it just doesn't always allow it to finish.
I log all attempts to run these apps in order to debug, so I know that
the command as p
[EMAIL PROTECTED] wrote:
I don't want to crowd the list up with dead ends, so I was trying to
respond only to you.
You'll get more chances at finding the solution to this with the list's
eyes on it rather than just myself. Plus, it provides an archive of the
problem and the (if we find it)
I don't want to crowd the list up with dead ends, so I was trying to
respond only to you.
I'm not calling a php program from exec, I'm calling ecasound and
convert. For example, in the php code:
exec("convert $internalpath/$filename -resize
{$thumbWidth}x{$thumbHeight} $internalpath/$thumbn
Please reply to the list.
[EMAIL PROTECTED] wrote:
No, all of these things your are bringing up would cause the programs to
NEVER work, not work some of the time or when the data they are
processing is small.
Depends on the install. My cli uses a different php.ini than the web one.
Did you
[EMAIL PROTECTED] wrote:
I have two programs on two servers, and they both have similar problems.
In each one, I use 'exec' to call a helper program. In one case, it is
ecasound, which I use to resample an mp3. In the other, it is convert,
which creates a thumbnail of a very large image the u
[EMAIL PROTECTED] wrote:
I have two programs on two servers, and they both have similar problems.
In each one, I use 'exec' to call a helper program. In one case, it is
ecasound, which I use to resample an mp3. In the other, it is convert,
which creates a thumbnail of a very large image the u
You might find that get_current_user() is easier...
http://www.php.net/manual/en/function.get-current-user.php
On Wed, 6 Apr 2005, cragland wrote:
when running a simple php script, below, with exec, I recieve:
sh: /whoami: No such file or directory
Thanks very much,
cole
mailto:[EMAIL PROTECTED]
"
> when running a simple php script, below, with exec, I recieve:
> sh: /whoami: No such file or directory
>
> // outputs the username that owns the running php/httpd
> process // (on a system with the "whoami" executable in the
> path) echo exec('whoami'); ?>
>
You may want to try using the f
Sitthipong Thuetham wrote:
> I have a question on an exec() command, if I would like to switch user
> right on Unix server, what command should I use?
>
> example: on the UNIX shell will be like below
> $su root
> Password:'password'
>
> but when I tried running exec() command on PHP, I couldn't do
On Wed, 1 Dec 2004 16:18:01 +0700, Sitthipong Thuetham <[EMAIL PROTECTED]>
wrote:
> Dear PHP support,
>
> I have a question on an exec() command, if I would like to switch user right
> on Unix server, what command should I use?
>
> example: on the UNIX shell will be like below
> $su root
> Pass
"Nabil" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> so when i use php exec to do it , am i using apache user (nobody) or
am i
> using php user , is there a php user ?
> so what can i do ?
> i want to execute
> #useradd -d /home/all -g wahtever -s /bin/false newuser
> as i want to
so when i use php exec to do it , am i using apache user (nobody) or am i
using php user , is there a php user ?
so what can i do ?
i want to execute
#useradd -d /home/all -g wahtever -s /bin/false newuser
as i want to create only pop user on the system when my user make
regestration.. to give him
You can use sudo (man sudo), but keep in mind security!!!
nabil wrote:
hi all;
I want to execute
#useradd -d /home/all -g wahtever -s /bin/bash newuser
how can I do it ... I used exec and shell_exec and system
I tried all the following but with no hope
exec('useradd -d /home/all -g wahtever -s /b
ara: nabil
CC: [EMAIL PROTECTED]
Asunto: Re: [PHP] exec command
Importancia: Baja
> I want to execute
> #useradd -d /home/all -g wahtever -s /bin/bash newuser
You have to be root to add a user to the system...and just a heads
up...you might want to rethink doing this from apache or
>From CLI or Web?
You must have in mind that useradd only can be executed by root user.
-Mensaje original-
De: nabil [mailto:[EMAIL PROTECTED]
Enviado el: miƩrcoles, 01 de octubre de 2003 16:05
Para: [EMAIL PROTECTED]
Asunto: [PHP] exec command
Importancia: Baja
hi all;
I want to ex
> I want to execute
> #useradd -d /home/all -g wahtever -s /bin/bash newuser
You have to be root to add a user to the system...and just a heads
up...you might want to rethink doing this from apache or php. The
security implications alone make me cringe.
--
Ray
--
PHP General Mailing List (http
David:
Permissions were the first guess - I chmoded 777 everything - still no go.
On the server, there should be a second file created identical to the first
with the results of the sed find and replace in it - the only thing that is
created is a blank file.
So, it is not permissions, nothing is
Hello,
This is a reply to an e-mail that you wrote on Tue, 15 Jul 2003 at 23:17,
lines prefixed by '>' were originally written by you.
> "if I print out the exec line with the
> dynamically generated paths, etc, then execute that through the
> terminal, no
> problem. "
> >From the first email mean
"if I print out the exec line with the
dynamically generated paths, etc, then execute that through the terminal, no
problem. "
>From the first email meaning that I did just like you suggested already and
it works in the terminal and contains exactly what I expect it to.
But thanks :)
On 7/15/03
Hello,
This is a reply to an e-mail that you wrote on Tue, 15 Jul 2003 at 21:30,
lines prefixed by '>' were originally written by you.
> I have the following exec command in php:
> exec("/bin/sed -f $GLOBALS[TMP_MAIL_DIR]"."cmdfile
> $GLOBALS[TMP_MAIL_DIR]"."$mailid >
> $GLOBALS[TMP_MAIL_DIR]"."$m
manju visu wrote:
Hi everyone,
If possible reply me.
I have one problem.
I'm trying to execute exec() command to generate stats by using the
exec() function, it does not generate an error but it also does not
run the command, and the value of $result thats returned from exec()
is 11.
Below is
what is the output of $results ?
print_r($results);
try another command, ie.
exec("echo hello world", $results);
exec("echo hello world > /tmp/test.txt", $results);
does that work? does that file aliases.db permissions set as world
writeable, or the user.group set to nobody.nobody (ie. whateve
38 matches
Mail list logo