Nie jesteś zalogowany.
Jeśli nie posiadasz konta, zarejestruj je już teraz! Pozwoli Ci ono w pełni korzystać z naszego serwisu. Spamerom dziękujemy!
Prosimy o pomoc dla małej Julki — przekaż 1% podatku na Fundacji Dzieciom zdazyć z Pomocą.
Więcej informacji na dug.net.pl/pomagamy/.




Użytkownik





nginx i php-fpm uruchomione
a strony zamiast sie otwierac w przegladarce chca sie sciagnac na dysk
$ sudo systemctl status php-fpm
php-fpm.service - The PHP FastCGI Process Manager
Loaded: loaded (/usr/lib/systemd/system/php-fpm.service; disabled)
Active: active (running) since Fri 2013-06-21 21:04:24 IST; 2min 52s ago
Main PID: 14466 (php-fpm)
Status: "Processes active: 0, idle: 2, Requests: 0, slow: 0, Traffic: 0req/sec"
CGroup: name=systemd:/system/php-fpm.service
├─14466 php-fpm: master process (/etc/php/php-fpm.conf)
├─14474 php-fpm: pool www
└─14475 php-fpm: pool www
Jun 21 21:04:24 arch php-fpm[14466]: [21-Jun-2013 21:04:24] NOTICE: fpm is running, pid 14466
Jun 21 21:04:24 arch php-fpm[14466]: [21-Jun-2013 21:04:24] NOTICE: ready to handle connections
Jun 21 21:04:24 arch systemd[1]: Started The PHP FastCGI Process Manager.
Jun 21 21:04:24 arch php-fpm[14466]: [21-Jun-2013 21:04:24] NOTICE: systemd monitor interval set to 10000ms
Jun 21 21:05:01 arch systemd[1]: Started The PHP FastCGI Process Manager.
Jun 21 21:05:52 arch systemd[1]: Started The PHP FastCGI Process Manager.
Jun 21 21:05:56 arch systemd[1]: Started The PHP FastCGI Process Manager.
Jun 21 21:07:00 arch systemd[1]: Started The PHP FastCGI Process Manager.
przemo@arch ~ $ sudo systemctl status nginx
nginx.service - A high performance web server and a reverse proxy server
Loaded: loaded (/usr/lib/systemd/system/nginx.service; disabled)
Active: active (running) since Fri 2013-06-21 21:04:24 IST; 3min 10s ago
Process: 14471 ExecStart=/usr/bin/nginx -g pid /run/nginx.pid; daemon on; master_process on; (code=exited, status=0/SUCCESS)
Process: 14467 ExecStartPre=/usr/bin/nginx -t -q -g pid /run/nginx.pid; daemon on; master_process on; (code=exited, status=0/SUCCESS)
Main PID: 14472 (nginx)
CGroup: name=systemd:/system/nginx.service
├─14472 nginx: master process /usr/bin/nginx -g pid /run/nginx.pid; daemon on; master_process on;
└─14473 nginx: worker process
Jun 21 21:04:24 arch systemd[1]: Started A high performance web server and a reverse proxy server.
Jun 21 21:05:01 arch systemd[1]: Started A high performance web server and a reverse proxy server.
Jun 21 21:06:06 arch systemd[1]: Started A high performance web server and a reverse proxy server.
Jun 21 21:07:00 arch systemd[1]: Started A high performance web server and a reverse proxy server.Offline




Użytkownik





SORRY szkolny blad mozna skasowac watek jak sie da za wczasu, letnie przesilenie sie udzialilo dostalem zacmienia mozgu.
Ostatnio edytowany przez pink (2013-06-22 10:33:27)
Offline







Podobno człowiek...;)








pink napisał(-a):
SORRY szkolny blad mozna skasowac watek jak sie da za wczasu, letnie przesilenie sie udzialilo dostalem zacmienia muzgu.
A co to znaczy
...zacmienia muzgu
Łap sznurka.
Pozdro
;-)
Ostatnio edytowany przez Jacekalex (2013-06-22 02:59:29)
Offline




Użytkownik





no wlasnie to znaczy to.
http://pl.wikipedia.org/wiki/Defekt_Muzg%C3%B3
Ostatnio edytowany przez pink (2013-06-22 11:01:21)
Offline




Użytkownik





Odswierzam watek aby nie zakladac nowego a moze i ten nabierze wiecej sesu
nginx dziala strony html sie wyswietlaja ale php juz nie
konfiguracja wyglada tak ale juz nie wiem czy nie namieszalem:
nginx.conf
user www-data;
worker_processes 4;
pid /run/nginx.pid;
events {
worker_connections 768;
# multi_accept on;
}
http {
##
# Basic Settings
##
sendfile on;
tcp_nopush on;
tcp_nodelay on;
keepalive_timeout 2;
types_hash_max_size 2048;
# server_tokens off;
# server_names_hash_bucket_size 64;
# server_name_in_redirect off;
include /etc/nginx/mime.types;
default_type application/octet-stream;
##
# SSL Settings
##
ssl_protocols TLSv1 TLSv1.1 TLSv1.2; # Dropping SSLv3, ref: POODLE
ssl_prefer_server_ciphers on;
##
# Logging Settings
##
access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log;
##
# Gzip Settings
##
gzip on;
gzip_disable "msie6";
# 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/javascript text/xml application/xml application/xml+rss text/javascript;
##
# Virtual Host Configs
##
include /etc/nginx/conf.d/*.conf;
include /etc/nginx/sites-enabled/*;
}
#mail {
# # See sample authentication script at:
# # http://wiki.nginx.org/ImapAuthenticateWithApachePhpScript
#
# # auth_http localhost/auth.php;
# # pop3_capabilities "TOP" "USER";
# # imap_capabilities "IMAP4rev1" "UIDPLUS";
#
# server {
# listen localhost:110;
# protocol pop3;
# proxy on;
# }
#
# server {
# listen localhost:143;
# protocol imap;
# proxy on;
# }
#}fastcgi.conf
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_param QUERY_STRING $query_string; fastcgi_param REQUEST_METHOD $request_method; fastcgi_param CONTENT_TYPE $content_type; fastcgi_param CONTENT_LENGTH $content_length; fastcgi_param SCRIPT_NAME $fastcgi_script_name; fastcgi_param REQUEST_URI $request_uri; fastcgi_param DOCUMENT_URI $document_uri; fastcgi_param DOCUMENT_ROOT $document_root; fastcgi_param SERVER_PROTOCOL $server_protocol; fastcgi_param HTTPS $https if_not_empty; fastcgi_param GATEWAY_INTERFACE CGI/1.1; fastcgi_param SERVER_SOFTWARE nginx/$nginx_version; fastcgi_param REMOTE_ADDR $remote_addr; fastcgi_param REMOTE_PORT $remote_port; fastcgi_param SERVER_ADDR $server_addr; fastcgi_param SERVER_PORT $server_port; fastcgi_param SERVER_NAME $server_name; # PHP only, required if PHP was built with --enable-force-cgi-redirect fastcgi_param REDIRECT_STATUS 200;
/sites-avilable/default
server {
listen 80;
root /home/przemo/Public/www;
index index.php index.html index.htm;
server_name localhost;
location / {
try_files $uri $uri/ /index.html;
}
error_page 404 /404.html;
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /home/przemo/Public/www;
}
# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
location ~ \.php$ {
try_files $uri =404;
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
}/sites-avilable/local.net
server {
listen 80;
server_name localhost;
charset utf-8;
access_log off;
root /home/przemo/Public/www;
index index.php;
location / {
try_files $uri $uri/ /index.php;
#lub: try_files $uri $uri/ /index.php?id=$uri&$args
}
location ~ \.php$ {
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
}
location ~ /\.ht { deny all; }
location ~ /\. { deny all; }
}php-fpm.conf
;;;;;;;;;;;;;;;;;;;;; ; FPM Configuration ; ;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;; ; Global Options ; ;;;;;;;;;;;;;;;;;; [global] pid = /run/php5-fpm.pid error_log = /var/log/php5-fpm.log ;;;;;;;;;;;;;;;;;;;; ; Pool Definitions ; ;;;;;;;;;;;;;;;;;;;; include=/etc/php5/fpm/pool.d/*.conf
Ostatnio edytowany przez pink (2015-05-20 17:00:07)
Offline







Podobno człowiek...;)








A co w logach Nginxa i PHP słychać?
Offline




Użytkownik





o przepraszam nginx przestal dzialac
cat /var/log/nginx/error.log 2015/05/20 17:58:02 [emerg] 17921#0: "location" directive is not allowed here in /etc/nginx/conf.d/caches.conf:2 2015/05/20 17:58:03 [emerg] 18029#0: "location" directive is not allowed here in /etc/nginx/conf.d/caches.conf:2
pusto w logach nginx
caches.conf
## caches
location ~* \.(jpg|jpeg|gif|css|png|js|ico|html)$ {
access_log off;
expires max;
}
location ~* \.(js)$ {
access_log off;
log_not_found off;
expires 7d;
}
location ~* \.(woff|svg)$ {
access_log off;
log_not_found off;
expires 30d;
}
location ~ /\.ht {
deny all;
}cat /var/log/php5-fpm.log
[sudo] password for przemo:
[20-May-2015 16:13:24] NOTICE: configuration file /etc/php5/fpm/php-fpm.conf test is successful
[20-May-2015 16:13:24] NOTICE: fpm is running, pid 3793
[20-May-2015 16:13:24] NOTICE: ready to handle connections
[20-May-2015 16:13:24] NOTICE: systemd monitor interval set to 10000ms
Ostatnio edytowany przez pink (2015-05-20 19:00:38)
Offline




Użytkownik





pomogla reinstalacja i podlinkowanie /Public/www do /usr/share/nginx/html zamiast podawania bezposredniej sciezki w konfigu.
[SOLVED]
Ostatnio edytowany przez pink (2015-05-21 10:21:58)
Offline