우분투 20.04 + Nginx 로 세팅하고 있는데, FastCGI sent in stderr: "Primary script unknown" 에러가 발생하는 경우
본문
우분투 20.04 및 Nginx, php8.1 조합으로 세팅하고 있는데,
php 파일을 인식하지 못하고 있습니다.
root는 홈디렉토리로 인식 시켰는데,
html 파일은 잘 인식하는데 php파일만 인식을 못하네요.
제 php 블럭을 올립니다.
        location ~ \.php$ {
            root /home/root/www;
            fastcgi_split_path_info ^(.+\.php)(.*)$;
            #fastcgi_pass 127.0.0.1:9000;
            fastcgi_pass unix:/run/php/php8.1-fpm.sock;
            fastcgi_index index.php;
            #fastcgi_param SCRIPT_FILENAME /home/root/www$fastcgi_script_name;
            include fastcgi_params;
        }
웹상에서 로드 시 발생하는 에러코드는 다음과 같습니다.
FastCGI sent in stderr: "Primary script unknown" while reading response header from upstream
                답변을 작성하시기 전에 로그인 해주세요.
            
    
