LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 09-21-2014, 03:41 AM   #1
lamletoi
Member
 
Registered: Oct 2011
Posts: 46

Rep: Reputation: Disabled
Arrow Problem with Nginx adn FastCGI on Ubuntu 14 + No input file specific


Hi everybody,
Currently , I am deploying a server for develppment
Nginx , MariaDB, Php-fpm, Memcached,APC, Phalcon.
But i have encounting with an error :
Code:
No input file specified.
Detail :

Code:
2014/09/21 15:11:48 [error] 12849#0: *4 FastCGI sent in stderr: "PHP message: PHP Warning:  Unknown: failed to open stream: Success in Unknown on line 0
Unable to open primary script: /usr/share/nginx/html/xxx/ (Success)" while reading response header from upstream, client: 111.111.111.111, server: xxx.com.vn, request: "GET / HTTP/1.1", upstream: "fastcgi://unix:/var/run/php5-fpm.sock:", host: "xxx.com.vn"
I have followed http://nginxlibrary.com/resolving-no...ecified-error/ but i was not successful due to there is no accurate case for me

Code:
nginx version: nginx/1.4.6 (Ubuntu)
Additional .ini files parsed

Code:
/etc/php5/fpm/conf.d/05-opcache.ini, /etc/php5/fpm/conf.d/10-pdo.ini, /etc/php5/fpm/conf.d/20-apcu.ini, /etc/php5/fpm/conf.d/20-curl.ini, /etc/php5/fpm/conf.d/20-gd.ini, /etc/php5/fpm/conf.d/20-json.ini, /etc/php5/fpm/conf.d/20-mcrypt.ini, /etc/php5/fpm/conf.d/20-memcached.ini, /etc/php5/fpm/conf.d/20-mysql.ini, /etc/php5/fpm/conf.d/20-mysqli.ini, /etc/php5/fpm/conf.d/20-pdo_mysql.ini, /etc/php5/fpm/conf.d/20-readline.ini, /etc/php5/fpm/conf.d/30-phalcon.ini
Nginx config :

Code:
user www-data;
worker_processes 8;
pid /run/nginx.pid;

events {
        worker_connections 4000;
        multi_accept on;
        use epoll;
}

http {
        ##
        # Tuning  Settings
        ##

        sendfile on;
        tcp_nopush on;
        tcp_nodelay on;
        keepalive_timeout 30;
        keepalive_requests 100000;
        reset_timedout_connection on;
        client_body_timeout 10;
        send_timeout 2;

        types_hash_max_size 2048;
        server_tokens off;
        error_log /var/log/nginx/error.log crit;

        open_file_cache max=200000 inactive=20s; 
        open_file_cache_valid 30s; 
        open_file_cache_min_uses 2;
        open_file_cache_errors on;
        access_log off;


        include /etc/nginx/mime.types;
        default_type application/octet-stream;


        gzip on;
        #gzip_disable "msie6";
        gzip_min_length 10240;
        gzip_proxied expired no-cache no-store private auth;
        gzip_types text/plain text/css text/xml text/javascript application/x-javascript application/xml;
        gzip_disable "MSIE [1-6]\.";
        # gzip_vary on;
        # gzip_proxied any;
        # gzip_comp_level 6;
        # gzip_buffers 16 8k;
        # gzip_http_version 1.1;
        # gzip_types text/plain text/css application/json application/x-javascript text/xml application/xml application/xml+rss text/javascript;


        include /etc/nginx/conf.d/*.conf;
        include /etc/nginx/sites-enabled/*;
}
Host config in site-enableds :
Code:
server {
        listen 80;
        root /usr/share/nginx/html/xxx/home;
        index index.php index.html index.htm;
        charset utf-8;
        server_name xxx.com.vn;


    gzip on;
    gzip_types
        text/plain
        text/css
        text/javascript
        text/xml
        image/x-icon
        image/png
        image/gif
        image/jpeg
        image/jpg 
        image/svg+xml
        application/x-javascript
        application/xml
        application/xml+rss
        application/x-font-ttf
        application/x-font-truetype
        application/x-font-opentype
        application/font-woff
        application/vnd.ms-fontobject
        application/octet-stream; 
    
    server_tokens off;
    access_log off;
    add_header Access-Control-Allow-Origin *;


        try_files $uri $uri/ @rewrite;

            location @rewrite {
                rewrite ^/(.*)$ /index.php?_url=/$1;
                }

                location ~* ^.+\.(jpg|jpeg|gif|png|ico|css|js|xml|svg|eot|ttf|woff)$ {
                 log_not_found off;
                expires max;
                }





        location ~ \.php$ {
                try_files  $uri =404;
                fastcgi_split_path_info ^(.+\.php)(/.+)$;
                fastcgi_pass unix:/var/run/php5-fpm.sock;
                fastcgi_index index.php;
                include fastcgi_params;
                fastcgi_param PATH_INFO $fastcgi_path_info;
                        fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
                        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
                        fastcgi_param SCRIPT_NAME $fastcgi_script_name;

        }

          location ~ /\.ht {
                log_not_found off;
                deny all;
        }

}
I also chmod -R 755 và chown www-data:www-data to home directory.
I need for help.
Thanks.
 
Old 09-21-2014, 04:47 PM   #2
halvy
Member
 
Registered: Aug 2005
Location: Anchorage, Alaska (soon EU, hopefully)
Distribution: Anything NOT SystemD (ie. M$) related.
Posts: 918

Rep: Reputation: 42
I am not sure what your permission are *suppose* to be on the input file.

Or maybe a bug.. have you checked?

That's an awefull lot of different factors (programs) you are balancing there... good luck
 
Old 09-21-2014, 09:01 PM   #3
lamletoi
Member
 
Registered: Oct 2011
Posts: 46

Original Poster
Rep: Reputation: Disabled
Hi,
This error occurs when you browser the website
I am not sure its bug.
There are alot of pepople have faced with this matter before.
I am trying to bring the best peformance for my web server with that factor.

Last edited by lamletoi; 09-21-2014 at 09:05 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to secure nginx +php using fastcgi in shared enviorment Kraiser10 Linux - Security 3 08-31-2014 06:41 AM
[SOLVED] fastcgi cannot find php files after I created nginx chroot environment Laertiades Linux - Server 1 01-30-2013 01:03 PM
[SOLVED] Nginx not passing the PHP scripts to FastCGI server listening on 127.0.0.1:9000 dreamcoder Linux - Server 8 08-02-2012 08:46 AM
LXer: How to Installing Nginx with PHP5-FastCGI and MySql Support on Ubuntu Server 12.04 LTS LXer Syndicated Linux News 0 06-15-2012 10:20 AM
LXer: Drupal 6 Hosting With nginx And PHP-FastCGI On Ubuntu 9.10 LXer Syndicated Linux News 0 04-08-2010 02:10 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 08:29 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration