Please assign a menu to the primary menu location under menu

Nginx

nginx – could not build the types_hash, you should increase either types_hash_max_size: 1024 or types_hash_bucket_size: 32

nginx 시작시 아래와 같은 메세지가 나오면 # /usr/local/nginx/sbin/nginx nginx: could not build the types_hash, you should increase either types_hash_max_size: 1024 or types_hash_bucket_size: 32 nginx: configuration file /usr/local/nginx/nginx.conf test failed   http 부분에 적절하게 넣어주고 시작 하면 됨. http { include mime.types; default_type application/octet-stream; types_hash_max_size 2048; server_names_hash_bucket_size 64; ………….. Blah blah ………….. }   잘 됨. # /usr/local/nginx/sbin/nginx -t nginx: the configuration file /usr/local/nginx/nginx.conf syntax is ok nginx: configuration file /usr/local/nginx/nginx.conf test is successful   issue http://trac.nginx.org/nginx/ticket/352

How to WordPress Permalink Setting on Nginx

WordPress 블로그를 사용하다 보면 Permalink를 사용자 임의로 변경 하고 싶을때가 있습니다. Nginx를 웹서버로 사용하고 있는 사용자에게 도움이 될까 싶어 포스팅 합니다. Nginx 설정 파일의 server구문 사이에 아래 예제 처럼 적용 하시면 됩니다. # Yongbok.net server { listen 80; server_name yongbok.net www.yongbok.net yongbok.com www.yongbok.com; root /home/user/ruo91/public_html; index index.php index.html; # Logs access_log logs/www-access.log; error_log logs/www-error.log; # WordPress Permalink try_files $uri $uri/ /blog/index.php?$args; # php-fpm location ~ .php$ { fastcgi_pass unix:/dev/shm/php-fpm.sock; fastcgi_index index.php; fastcgi_split_path_info ^(.+.php)(/.+)$; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi.conf; } }

How to hide the server name on nginx

nginx 웹서버의 서버 이름을 다른 것으로 변경하는 방법입니다. (tested : nginx 1.2.6 stable) 1. src/core/nginx.h 수정 NGINX_VER 부분을 적절하게 수정합니다. #define NGINX_VER “nginx/” NGINX_VERSION ex) Unknown으로 설정한 경우 #define NGINX_VER “Unknown” 2. src/http/ngx_http_header_filter_module.c 수정 헤더에서 보여지는 부분입니다. 49 ~ 50 라인을 적절하게 수정합니다. static char ngx_http_server_string = “Server: nginx” CRLF; static char ngx_http_server_full_string = “Server: ” NGINX_VER CRLF; ex) Unknown으로 설정한 경우 static char ngx_http_server_string = “Server: Unknown” CRLF; static char ngx_http_server_full_string = “Server: ” CRLF; 3. src/http/ngx_http_special_response.c 수정 http status code에 따라 나타나는 페이지입니다. 21 ~ 32 라인을 적절하게 수정합니다. static u_char ngx_http_error_full_tail의 NGINX_VER 부분과 static u_char ngx_http_error_tail의 nginx

How to install nginx for windows

MS Windows에서 Nginx를 설치하는 방법입니다. 1. Nginx 다운로드 Stable 버전을 다운로드 합니다. http://nginx.org/en/download.html 2. Nginx 압축풀기 적당한 곳에 압축을 풀어줍니다. 설치는 이것이 끝입니다. ex) C:Program Filesnginx 3. 서비스 등록 이제 시스템이 재시작 되어도 자동으로 nginx가 실행 되도록 서비스에 등록 해줍니다. (Lloyd Kinsella(?)님에게 감사의 표시를 전합니다.) nginx-svc-bin.zip를 다운로드 합니다. Nginx가 설치된 곳에 파일을 위치 시켜줍니다. 그후 nginxsvc.exe.config를 편집기로 열어 nginxPath 부분을 Nginx가 위치한 곳으로 변경 합니다. <?xml version=”1.0″?> <configuration> <appSettings> <add key=”nginxPath” value=”C:Program Filesnginx”/> <add key=”gracefulQuit” value=”false”/> <add key=”forceStop” value=”true”/> </appSettings> </configuration> 윈도우 키 + R을 눌러 실행창이 뜨면 cmd.exe를 합니다. 명령프롬프트 창이 뜨면 nginx가 설치된 위치로 이동합니다. Microsoft Windows Copyright

CentOS – How to install Nginx, PHP-FPM, MySQL

본 글은 CentOS 6.3에서 Nginx, PHP-FPM, MySQL을 설치하는 방법이며 설치 순서는 MySQL, Nginx, PHP-FPM 입니다. 1. 설치 – epel 기본 저장소에는 nginx와 php-fpm, 각종 php extension들이 없기 때문에 사용하겠습니다. # rpm -ivh http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-7.noarch.rpm # rpm -ivh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm   epel, remi 저장소가 우선시 되도록 priority 설치 및 설정 # yum install -y yum-priorities # nano /etc/yum.repos.d/epel.repo name=Extra Packages for Enterprise Linux 6 – $basearch #baseurl=http://download.fedoraproject.org/pub/epel/6/$basearch mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-6&arch=$basearch failovermethod=priority enabled=1 priority=1 gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6 # nano /etc/yum.repos.d/remi.repo name=Les RPM de remi pour Enterprise Linux $releasever – $basearch #baseurl=http://rpms.famillecollet.com/enterprise/$releasever/remi/$basearch/ mirrorlist=http://rpms.famillecollet.com/enterprise/$releasever/remi/mirror enabled=1 priority=1 gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-remi failovermethod=priority   – MySQL # yum install -y mysql mysql-server #

1 2 3