
Webmin を使用して、Ubuntu 18.04 で Apache 仮想サーバーをセットアップしました。サーバー ディレクティブは次のとおりです。
DocumentRoot /home/name/public_html
ServerName www.name.com
<Directory "/home/name/public_html">
allow from all
Options None
Require all granted
Options ExecCGI
</Directory>
2 つのディレクトリ /cgi-bin/A/a.cgi と /cgi-bin/B/b.cgi に Perl スクリプトがあります。2 つの PHP スクリプトがあり、これらのスクリプトに接続するリンクを持つ 2 つの Web ページ (a.php と b.php) を配信しています。<a href="/cgi-bin/A/a.cgi" をクリックすると、リンクは正常に機能し、Perl スクリプトは出力を返します。ただし、<a href="/cgi-bin/B/b.cgi" をクリックすると、「スクリプトが見つからないか、stat できません: /usr/lib/cgi-bin/B」というメッセージが表示されます。
最初のリンクは機能するのに、2 番目のリンクは機能しないのはなぜなのか、私には理解できません。他の点では両者は同じです。Apache が /cgi-bin/B ファイル パスを /cgi-bin/A ではなく /usr/lib/cgi-bin/B に置き換えるのはなぜでしょうか。ご協力をよろしくお願いします。