Skip to content

Tag: exec

Syntax error calling Python from C with fork-execv

I want to call a Python script as a child process from a C program using fork and execv. I have tested it calling bin/ls and it works: So I changed the C code to call the Create_Buffer() function in this Python file: The Python script has two functions; I want to call Create_Buffer(), so I changed my C file

shell linux don’t execute commande

I have this command and it works fine on shell. I want to run it with php but it does not work what i missed : edited : $arg=”arg1″; $arg2= “arg2”; after this change no error on output but still commande not executed edited : the original commande is like this : and i want to around th…

find: missing argument to -exec with ssh

Trying to remove directories from server: I tried with ; and ;; and ; and “{}” and -exec sh -c ‘rm -r “{}”‘ ; All get’s the error find: missing argument to “-exec’” Thanks Answer Directly running commands with ssh is often hard to impossible when you want …

PHP exec sudo script not working despite having sudo rights

My php script: my visudo line (I tripled checked every path) If i remove the ‘sudo’ in the exec() it will execute (i put a touch aaa at the start, with sudo the file isn’t even created so the script doesn’t even begin to execute). The script has exec rights for everyone. I can’t …