0 Пользователей и 1 Гость просматривают эту тему.
  • 31 Ответов
  • 19474 Просмотров
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
всем доброе время суток!
вот на сегодняшний день у меня такая проблем с Joomla
При включения FactCGI+(Nginx+PHP-FPM) сайт сразу выдает ошибку 404
в логах nginx чистота, ничего не написано

Панель ISPmanagerLite 5.27.2
OS UbuntuServer 14.04.2
Сайт работает работает на joomle 3.4.1

Админка работает у Joomla, а сайт выдает ошибку 404

Куда копать я не знаю

Посылать на оф.сайт jooma, не надо, там я был и по их схеме nginx отваливается fail, вчера весь день гуглил и яндексировал но ничего путного я не нашел

вот конфиг nginx
Код
user www-data;
worker_processes 8;
pid /run/nginx.pid;

events {
        worker_connections 4096;
        multi_accept on;
}

http {

        ##
        # Basic Settings
        ##

        sendfile on;
        tcp_nopush on;
        tcp_nodelay on;
        keepalive_timeout 65;
        types_hash_max_size 2048;
        server_tokens off;
        client_max_body_size 30m;

        server_names_hash_bucket_size 64;
        server_name_in_redirect off;

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

        ##
        # Logging Settings
        ##

        access_log off; # /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/x-javascript text/xml application/xml application/xml+rss text/javascript;

        ##
        # nginx-naxsi config
        ##
        # Uncomment it if you installed nginx-naxsi
        ##

        #include /etc/nginx/naxsi_core.rules;

        ##
        # nginx-passenger config
        ##
        # Uncomment it if you installed nginx-passenger
        ##

        #passenger_root /usr;
        #passenger_ruby /usr/bin/ruby;

        ##
        # Virtual Host Configs
        ##

        include /etc/nginx/conf.d/*.conf;
        include /etc/nginx/sites-enabled/*;
        include /etc/nginx/vhosts/*/*;
 server {
                server_name localhost;
        disable_symlinks if_not_owner;
        listen 80;
        include /etc/nginx/vhosts-includes/*.conf;
        location @fallback {
                error_log /dev/null crit;
                proxy_pass http://127.0.0.1:8080;
                proxy_redirect http://127.0.0.1:8080 /;
                proxy_set_header Host $host;
                proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
                proxy_set_header X-Forwarded-Proto $scheme;
                access_log off ;
        }
        }
}

все это дело работает на ISPmanagerLite5
« Последнее редактирование: 12.06.2015, 15:50:39 от b2z »
*

wishlight

  • Живу я здесь
  • 4980
  • 293 / 1
  • от 150 руб быстрый хостинг без блокировок
Чисто Nginx, а на Joomla SEF включен?
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
Чисто Nginx, а на Joomla SEF включен?

Nginx + FastCGI + PHP-PFM, да включен и выключал все равно не работает, мне сказали на форме ISPsystem, что нужно прописать правила к .htaccess, в конфиге nginx, а какие не сказали(((
*

capricorn

  • Завсегдатай
  • 1949
  • 118 / 3
уберите директивы php_value из .htaccess, если есть. конф файлы трогать не надо. nginx работает обычно в паре с Apache.

произвольный файл php в корне сайта отрабатывает?
« Последнее редактирование: 21.05.2015, 23:53:08 от capricorn »
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
уберите директивы php_value из .htaccess, если есть. конф файлы трогать не надо. nginx работает обычно в паре с Apache.

произвольный файл php в корне сайта отрабатывает?

Причем здесь апач? апача вообще нету
произвольный php, что Вы имеете виду?

такой директивы php_value вообще нету, вот .htaccess
Код
##
# @package Joomla
# @copyright Copyright (C) 2005 - 2014 Open Source Matters. All rights reserved.
# @license GNU General Public License version 2 or later; see LICENSE.txt
##

##
# READ THIS COMPLETELY IF YOU CHOOSE TO USE THIS FILE!
#
# The line just below this section: 'Options +FollowSymLinks' may cause problems
# with some server configurations.  It is required for use of mod_rewrite, but may already
# be set by your server administrator in a way that dissallows changing it in
# your .htaccess file.  If using it causes your server to error out, comment it out (add # to
# beginning of line), reload your site in your browser and test your SEF url's.  If they work,
# it has been set by your server administrator and you do not need it set here.
##

## Can be commented out if causes errors, see notes above.
Options +FollowSymLinks

## Mod_rewrite in use.

RewriteEngine On

## Begin - Rewrite rules to block out some common exploits.
# If you experience problems on your site block out the operations listed below
# This attempts to block the most common type of exploit `attempts` to Joomla!
#
# Block out any script trying to base64_encode data within the URL.
RewriteCond %{QUERY_STRING} base64_encode[^(]*\([^)]*\) [OR]
# Block out any script that includes a <script> tag in URL.
RewriteCond %{QUERY_STRING} (<|%3C)([^s]*s)+cript.*(>|%3E) [NC,OR]
# Block out any script trying to set a PHP GLOBALS variable via URL.
RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]
# Block out any script trying to modify a _REQUEST variable via URL.
RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2})
# Return 403 Forbidden header and show the content of the root homepage
RewriteRule .* index.php [F]
#
## End - Rewrite rules to block out some common exploits.

## Begin - Custom redirects
#
# If you need to redirect some pages, or set a canonical non-www to
# www redirect (or vice versa), place that code here. Ensure those
# redirects use the correct RewriteRule syntax and the [R=301,L] flags.
#
## End - Custom redirects

##
# Uncomment following line if your webserver's URL
# is not directly related to physical file paths.
# Update Your Joomla! Directory (just / for root).
##

# RewriteBase /

## Begin - Joomla! core SEF Section.
#
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
#
# If the requested path and file is not /index.php and the request
# has not already been internally rewritten to the index.php script
RewriteCond %{REQUEST_URI} !^/index\.php
# and the requested path and file doesn't directly match a physical file
RewriteCond %{REQUEST_FILENAME} !-f
# and the requested path and file doesn't directly match a physical folder
RewriteCond %{REQUEST_FILENAME} !-d
# internally rewrite the request to the index.php script
RewriteRule .* index.php [L]
#
## End - Joomla! core SEF Section.
*

wishlight

  • Живу я здесь
  • 4980
  • 293 / 1
  • от 150 руб быстрый хостинг без блокировок
Да надо писать свои правила редиректа в конфиге nginx. Я чуть не в теме, может кто из форумчан подскажет. А так пока у меня сайты с апачем и nginx для статики.
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
Да надо писать свои правила редиректа в конфиге nginx. Я чуть не в теме, может кто из форумчан подскажет. А так пока у меня сайты с апачем и nginx для статики.

У меня тоже было раньше nginx + apache2, на ISPmanager 4, а сейчас ISPmanager 5 предлагает только FactCGI+(Nginx+PHP-FPM), вот что мне еще ответили на оф.форме ISPsystem
копайте в сторону настройки rewrite для nginx от Joomla
В режиме Nginx+PHP-FPM не работает .htaccess, и нужно вручную настроить nginx
*

wishlight

  • Живу я здесь
  • 4980
  • 293 / 1
  • от 150 руб быстрый хостинг без блокировок
https://docs.joomla.org/Nginx если вам нужен именно nginx
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
https://docs.joomla.org/Nginx если вам нужен именно nginx

там я был и по той технологии gnix отваливается fail
*

wishlight

  • Живу я здесь
  • 4980
  • 293 / 1
  • от 150 руб быстрый хостинг без блокировок
хз.. ну если все так, то пробуйте профиль apache+nginx+fast cgi. Я норм настраивал. Или обратитесь к специалистам по этому вопросу. Хотя в требованиях Joomla указан сервер apache для динамических запросов.
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
хз.. ну если все так, то пробуйте профиль apache+nginx+fast cgi. Я норм настраивал. Или обратитесь к специалистам по этому вопросу. Хотя в требованиях Joomla указан сервер apache для динамических запросов.

У меня нету Apache с связке с Ngnx и каким специалистам я должен обращаться?
Можно почту разработчиков Joomla
*

Apoca1ypto

  • Давно я тут
  • 749
  • 71 / 0
каким специалистам я должен обращаться?
1500 рублей и Вам все настроят под Ваши нужды https://systemintegra.ru/uslugi/all/proizvoditel_nost/optimizaciya_servera/
ISP отличная панель, но видимо всегда есть частные случае, где без точных знаний что-то нельзя настроить.
Во время спора в Интернете Ваш оппонент приводит неопровержимые доказательства своей точки зрения? Не отчаивайтесь. До...тесь до орфографии.
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
1500 рублей и Вам все настроят под Ваши нужды https://systemintegra.ru/uslugi/all/proizvoditel_nost/optimizaciya_servera/
ISP отличная панель, но видимо всегда есть частные случае, где без точных знаний что-то нельзя настроить.


заплатить это самый легких способ, но не способ научится
*

wishlight

  • Живу я здесь
  • 4980
  • 293 / 1
  • от 150 руб быстрый хостинг без блокировок
В isp 5 есть три профиля "базовых". apache_mpm_itk + nginx + mod_php, apache prefork + nginx + cgi/fast_cgi, ну и ваш. Еще можно без nginx, но это хуже. Все базово настраивается без особых проблем.
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
В isp 5 есть три профиля "базовых". apache_mpm_itk + nginx + mod_php, apache prefork + nginx + cgi/fast_cgi, ну и ваш. Еще можно без nginx, но это хуже. Все базово настраивается без особых проблем.

Там вот только что есть
*

wishlight

  • Живу я здесь
  • 4980
  • 293 / 1
  • от 150 руб быстрый хостинг без блокировок
Читайте документацию. Смотрите раздел возможности.
*

Apoca1ypto

  • Давно я тут
  • 749
  • 71 / 0
Там вот только что есть

Вот и используйте FastCGI (Apache)
Во время спора в Интернете Ваш оппонент приводит неопровержимые доказательства своей точки зрения? Не отчаивайтесь. До...тесь до орфографии.
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
так он сейчас и работает в FastCGI Apache, но с nginx'om быстрее работать будет
*

draff

  • Гуру
  • 5803
  • 434 / 7
  • ищу работу
и что за сборка, если nginx не стоит на фронте перед apache
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
и что за сборка, если nginx не стоит на фронте перед apache

FactCGI+(Nginx+PHP-FPM)
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
настроил теперь место 404 ошибки пишет File not found.
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
Ура нашел решение, чтоб работало с связке
закомментировал строки и написал свои, подходит как Joomla так и wordpress
Код
#user 'user' virtual host 'site.ru' configuration file
server {
        server_name site.ru www.site.ru;
        charset UTF-8;
        disable_symlinks if_not_owner from=$root_path;
        index index.html, index.php;
        root $root_path;
        set $root_path /var/www/user/data/www/site.ru;
        ssi on;
        error_log /var/www/httpd-logs/site.ru.error.log notice;
        include /etc/nginx/vhosts-includes/*.conf;
        #location / {
        #       location ~ [^/]\.ph(p\d*|tml)$ {
        #               try_files /does_not_exists @php;
        #       }
        #
        #}
         location / {
                try_files $uri $uri/ /index.php?q=$request_uri;
        location ~ [^/]\.ph(p\d*|tml)$ {
                try_files /does_not_exists @php;
        }
        }
        location @fallback {
                error_log /dev/null crit;
                access_log off ;
        }
        location @php {
                fastcgi_index index.php;
                fastcgi_param PHP_ADMIN_VALUE "sendmail_path = /usr/sbin/sendmail -t -i -f info@site.ru";
                fastcgi_pass unix:/var/www/php-fpm/site.sock;
                fastcgi_split_path_info ^((?U).+\.ph(?:p\d*|tml))(/?.+)$;
                try_files $uri =404;
                include fastcgi_params;
        }
        access_log off ;
        listen 77.41.111.112:80;
}

может кому не будь пригодиться, бесплатно)))
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
Теперь нашел еще проблему проблема заключается в том что, либо работает поиск, а админка выдает 404 ошибку, а если убрать часть кода, админка работает, отваливается поиск))

Вот так админка работает, поиск отваливается выдает вот это /component/finder/search.html?q=
Код
#user 'user' virtual host 'site.ru' configuration file
server {
        server_name site.ru www.site.ru;
        charset UTF-8;
        disable_symlinks if_not_owner from=$root_path;
        index index.html, index.php;
        root $root_path;
        set $root_path /var/www/user/data/www/site.ru;
        ssi on;
        error_log /var/www/httpd-logs/site.ru.error.log notice;
        location ~* ^.+\.(jpg|jpeg|gif|png|svg|js|css|mp3|ogg|mpe?g|avi|zip|gz|bz2?|rar|swf|pdf)$ {
                root $root_path;
                expires 7d;
        }
        location / {
                try_files $uri $uri/ /index.php?q=$request_uri;
        }
        location ~ [^/]\.ph(p\d*|tml)$ {
                try_files /does_not_exists @php;
        }
        location @fallback {
                error_log /dev/null crit;
                access_log off ;
                error_page 404 = @fallback;
        }
        location @php {
                fastcgi_index index.php;
                fastcgi_param PHP_ADMIN_VALUE "sendmail_path = /usr/sbin/sendmail -t -i -f info@site.ru";
                fastcgi_pass unix:/var/www/php-fpm/ebooks.sock;
                fastcgi_split_path_info ^((?U).+\.ph(?:p\d*|tml))(/?.+)$;
                try_files $uri =404;
                include fastcgi_params;
        }
        access_log off ;
        listen 77.41.111.112:80;
}

А так админка уходит в 404 ошибку, поиск работает
добавил только вот эти две строчки
if (!-f $request_filename) {
                rewrite ^(.*)$ /index.php;
                }

чтоб работал поиск
Код
#user 'user' virtual host 'site.ru' configuration file
server {
        server_name site.ru www.site.ru;
        charset UTF-8;
        disable_symlinks if_not_owner from=$root_path;
        index index.html, index.php;
        root $root_path;
        set $root_path /var/www/user/data/www/site.ru;
        ssi on;
        error_log /var/www/httpd-logs/site.ru.error.log notice;
        location ~* ^.+\.(jpg|jpeg|gif|png|svg|js|css|mp3|ogg|mpe?g|avi|zip|gz|bz2?|rar|swf|pdf)$ {
                root $root_path;
                expires 7d;
        }
        location / {
                try_files $uri $uri/ /index.php?q=$request_uri;
                if (!-f $request_filename) {
                rewrite ^(.*)$ /index.php;
                }
        }
        location ~ [^/]\.ph(p\d*|tml)$ {
                try_files /does_not_exists @php;
        }
        location @fallback {
                error_log /dev/null crit;
                access_log off ;
                error_page 404 = @fallback;
        }
        location @php {
                fastcgi_index index.php;
                fastcgi_param PHP_ADMIN_VALUE "sendmail_path = /usr/sbin/sendmail -t -i -f info@site.ru";
                fastcgi_pass unix:/var/www/php-fpm/ebooks.sock;
                fastcgi_split_path_info ^((?U).+\.ph(?:p\d*|tml))(/?.+)$;
                try_files $uri =404;
                include fastcgi_params;
        }
        access_log off ;
        listen 77.41.111.112:80;
}

проблема заключается в том что при этих двух строчках нельзя войти админку не так site.ru/administrator, а только site.ru/administrator/index.php
а через token и подавно выдает ошибку(((
« Последнее редактирование: 23.05.2015, 02:55:23 от Bismuth »
*

capricorn

  • Завсегдатай
  • 1949
  • 118 / 3
а так работает (из документации Joomla)?

Код
        location / {
                try_files $uri $uri/ /index.php?$args;
        }
*

Bismuth

  • Захожу иногда
  • 138
  • 2 / 0
а так работает (из документации Joomla)?

Код
        location / {
                try_files $uri $uri/ /index.php?$args;
        }


вот так все работает и сайт и поиск и админка, поменял только одну букву с !-f на !-е
Код
 location / {
                try_files $uri $uri/ /index.php?q=$request_uri;
                if (!-e $request_filename) {
                rewrite ^(.*)$ /index.php;

                }
        }
пока полет нормальный
*

ChaosHead

  • Гуру
  • 5241
  • 451 / 13
Видел готовые настройки. Нужно просто погуглитт.
*

Fat

  • Захожу иногда
  • 479
  • 25 / 0
  • Разрабатываю компоненты для Joomla
Bismuth, респект вам! Мне помогло решение!
*

Филипп Сорокин

  • Завсегдатай
  • 1918
  • 160 / 4
  • разработчик.москва
Второй вариант - хрень полнейшая. Зачем-то 2 рерайта, когда можно обойтись одним. Тот однострочный - это стандарт, все его используют.
*

Malory

  • Захожу иногда
  • 85
  • 6 / 0
С панелью Vesta побороть проблему помогла смена дефолтных настроек на:
Шаблон Web NGINX: Joomla   
Шаблон Backend PHP-FPM: socket
*

mark1

  • Захожу иногда
  • 394
  • 39 / 2
Делюсь рабочим конфигом вирутального хоста Nginx для запуска Joomla на Openserver. Я взял стандартный конфиг из Openserver и слегка дополнил (стандартный конфиг сыпал 404 ошибками). Сильно не ругайте, Nginx толком не знаю. Конфигу даём имя типа nginx-1.7_vhost.conf, и кладём в папку сайта.


Код
#---------------------------------------------#
# Начало шаблона конфигурации хоста
#---------------------------------------------#

server {
listen %ip%:%httpport%;
listen %ip%:%httpsport% ssl;
server_name %host% %aliases%;

server_name_in_redirect off;

root "%hostdir%";

location / {
    #root   "%hostdir%";
    index  index.php index.html index.htm;
try_files $uri $uri/ /index.php?$args;
}

location ~ \.php$ {
    #root           "%hostdir%";
    try_files      $uri =404;
    # if (!-e $document_root$document_uri){return 404;}   
    fastcgi_pass   backend;
    fastcgi_index  index.php;
    fastcgi_param  TMP    "%sprogdir%/userdata/temp";
    fastcgi_param  TMPDIR "%sprogdir%/userdata/temp";
    fastcgi_param  TEMP   "%sprogdir%/userdata/temp";
    fastcgi_buffers 4 64k;
fastcgi_connect_timeout 1s;
fastcgi_ignore_client_abort off;
    fastcgi_next_upstream timeout;
    fastcgi_read_timeout 30s;
fastcgi_send_timeout 30s; 
    fastcgi_param CONTENT_TYPE       $content_type;
    fastcgi_param CONTENT_LENGTH     $content_length;
    fastcgi_param DOCUMENT_URI       $document_uri;
    fastcgi_param DOCUMENT_ROOT      $document_root;
    fastcgi_param GATEWAY_INTERFACE  CGI/1.1;
fastcgi_param HTTPS              $https;
    fastcgi_param QUERY_STRING       $query_string;
    fastcgi_param REQUEST_METHOD     $request_method;
    fastcgi_param REQUEST_URI        $request_uri;   
    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        $host;
    fastcgi_param SERVER_PROTOCOL    $server_protocol;
    fastcgi_param SERVER_SOFTWARE    nginx;
    fastcgi_param SCRIPT_FILENAME    $document_root$fastcgi_script_name;
    fastcgi_param SCRIPT_NAME        $fastcgi_script_name;
}


# Cache file descriptors
open_file_cache          max=1000 inactive=20s;
open_file_cache_valid    30s;
open_file_cache_min_uses 2;
open_file_cache_errors   on;

# Expires
location ~* \.(?:jpg|jpeg|gif|png|ico|cur|gz|svg|svgz|mp4|ogg|ogv|webm|htc)$ {
expires 1M;
access_log off;
add_header Cache-Control "public";
}

location ~* \.(?:css|js)$ {
expires 1y;
access_log off;
add_header Cache-Control "public";
}



}

#---------------------------------------------#
# Конец шаблона конфигурации хоста
#---------------------------------------------#
Чтобы оставить сообщение,
Вам необходимо Войти или Зарегистрироваться
 

Прошу помощи. Ошибка при обновлении на Joomla 4

Автор wmsonic

Ответов: 1
Просмотров: 922
Последний ответ 29.10.2023, 22:07:23
от Kukush
Выходит ошибка в админской панели

Автор daymarus

Ответов: 0
Просмотров: 1410
Последний ответ 10.08.2023, 12:43:43
от daymarus
При обновлении ошибка 403 Forbidden Request forbidden by administrative rules

Автор THeCMeX

Ответов: 18
Просмотров: 2178
Последний ответ 14.07.2023, 17:13:19
от art22
Call to a member function NewColorizeImage() on null при переходе PHP 7 [Решено]

Автор Eholov

Ответов: 3
Просмотров: 2429
Последний ответ 17.03.2023, 11:03:04
от Olexa
Ошибка при обновлении с 3.10.10. до 4.х

Автор svd2014

Ответов: 1
Просмотров: 1451
Последний ответ 13.02.2023, 19:53:08
от weser