title: Luci unable to launch the requested CGI program: /www/cgi-bin/sample.cgi: Exec error
body: <p>I tried to execute a Cgi-Cpp program on a <code>uhttpd server</code> running on an <code>OpenWRT</code> install. The Cgi file is <code>/www/cgi-bin/sample.cgi</code> and has execute permissions too. I am trying to access this Cgi with HTML file. This is my <code>sample.cgi</code> file:</p>
  
  <pre><code>#include &lt;iostream&gt;
  #include &lt;vector&gt;  
  #include &lt;string&gt;  
  #include &lt;stdio.h&gt;  
  #include &lt;stdlib.h&gt; 
  
  #include &lt;cgicc/CgiDefs.h&gt; 
  #include &lt;cgicc/Cgicc.h&gt; 
  #include &lt;cgicc/HTTPHTMLHeader.h&gt; 
  #include &lt;cgicc/HTMLClasses.h&gt;  
  
  using namespace std;
  using namespace cgicc;
  
  int main () {
     Cgicc formData;
  
     cout &lt;&lt; "Content-type:text/html\r\n\r\n";
     cout &lt;&lt; "&lt;html&gt;\n";
     cout &lt;&lt; "&lt;head&gt;\n";
     cout &lt;&lt; "&lt;title&gt;Using GET and POST Methods&lt;/title&gt;\n";
     cout &lt;&lt; "&lt;/head&gt;\n";
     cout &lt;&lt; "&lt;body&gt;\n";
  
     form_iterator fi = formData.getElement("first_name");  
  
     if( !fi-&gt;isEmpty() &amp;&amp; fi != (*formData).end()) {  
        cout &lt;&lt; "First name: " &lt;&lt; **fi &lt;&lt; endl;  
     }else{
        cout &lt;&lt; "No text entered for first name" &lt;&lt; endl;  
     }
     cout &lt;&lt; "&lt;/body&gt;\n";
     cout &lt;&lt; "&lt;/html&gt;\n";
  
     return 0;
  } 
  </code></pre>
  
  <p>I get an error when I click the submit button in HTML:</p>
  
  <pre><code>unable to launch the requested CGI program: /www/cgi-bin/sample.cgi: Exec error
  </code></pre>
  
  <p>What am I missing? All permission are set there. Any suggestions?</p>