php-fpm.conf 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599
  1. ;;;;;;;;;;;;;;;;;;;;;
  2. ; FPM Configuration ;
  3. ;;;;;;;;;;;;;;;;;;;;;
  4. ; All relative paths in this configuration file are relative to PHP's install
  5. ; prefix (/usr/local). This prefix can be dynamically changed by using the
  6. ; '-p' argument from the command line.
  7. ;;;;;;;;;;;;;;;;;;
  8. ; Global Options ;
  9. ;;;;;;;;;;;;;;;;;;
  10. [global]
  11. ; Pid file
  12. ; Note: the default prefix is /var
  13. ; Default Value: none
  14. ;pid = run/php-fpm.pid
  15. ; Error log file
  16. ; If it's set to "syslog", log is sent to syslogd instead of being written
  17. ; into a local file.
  18. ; Note: the default prefix is /var
  19. ; Default Value: log/php-fpm.log
  20. ;error_log = log/php-fpm.log
  21. ; syslog_facility is used to specify what type of program is logging the
  22. ; message. This lets syslogd specify that messages from different facilities
  23. ; will be handled differently.
  24. ; See syslog(3) for possible values (ex daemon equiv LOG_DAEMON)
  25. ; Default Value: daemon
  26. ;syslog.facility = daemon
  27. ; syslog_ident is prepended to every message. If you have multiple FPM
  28. ; instances running on the same server, you can change the default value
  29. ; which must suit common needs.
  30. ; Default Value: php-fpm
  31. ;syslog.ident = php-fpm
  32. ; Log level
  33. ; Possible Values: alert, error, warning, notice, debug
  34. ; Default Value: notice
  35. ;log_level = notice
  36. ; Log limit on number of characters in the single line (log entry). If the
  37. ; line is over the limit, it is wrapped on multiple lines. The limit is for
  38. ; all logged characters including message prefix and suffix if present. However
  39. ; the new line character does not count into it as it is present only when
  40. ; logging to a file descriptor. It means the new line character is not present
  41. ; when logging to syslog.
  42. ; Default Value: 1024
  43. ;log_limit = 4096
  44. ; Log buffering specifies if the log line is buffered which means that the
  45. ; line is written in a single write operation. If the value is false, then the
  46. ; data is written directly into the file descriptor. It is an experimental
  47. ; option that can potentionaly improve logging performance and memory usage
  48. ; for some heavy logging scenarios. This option is ignored if logging to syslog
  49. ; as it has to be always buffered.
  50. ; Default value: yes
  51. ;log_buffering = no
  52. ; If this number of child processes exit with SIGSEGV or SIGBUS within the time
  53. ; interval set by emergency_restart_interval then FPM will restart. A value
  54. ; of '0' means 'Off'.
  55. ; Default Value: 0
  56. ;emergency_restart_threshold = 0
  57. ; Interval of time used by emergency_restart_interval to determine when
  58. ; a graceful restart will be initiated. This can be useful to work around
  59. ; accidental corruptions in an accelerator's shared memory.
  60. ; Available Units: s(econds), m(inutes), h(ours), or d(ays)
  61. ; Default Unit: seconds
  62. ; Default Value: 0
  63. ;emergency_restart_interval = 0
  64. ; Time limit for child processes to wait for a reaction on signals from master.
  65. ; Available units: s(econds), m(inutes), h(ours), or d(ays)
  66. ; Default Unit: seconds
  67. ; Default Value: 0
  68. ;process_control_timeout = 0
  69. ; The maximum number of processes FPM will fork. This has been designed to control
  70. ; the global number of processes when using dynamic PM within a lot of pools.
  71. ; Use it with caution.
  72. ; Note: A value of 0 indicates no limit
  73. ; Default Value: 0
  74. ; process.max = 128
  75. ; Specify the nice(2) priority to apply to the master process (only if set)
  76. ; The value can vary from -19 (highest priority) to 20 (lowest priority)
  77. ; Note: - It will only work if the FPM master process is launched as root
  78. ; - The pool process will inherit the master process priority
  79. ; unless specified otherwise
  80. ; Default Value: no set
  81. ; process.priority = -19
  82. ; Send FPM to background. Set to 'no' to keep FPM in foreground for debugging.
  83. ; Default Value: yes
  84. ;daemonize = yes
  85. ; Set open file descriptor rlimit for the master process.
  86. ; Default Value: system defined value
  87. ;rlimit_files = 1024
  88. ; Set max core size rlimit for the master process.
  89. ; Possible Values: 'unlimited' or an integer greater or equal to 0
  90. ; Default Value: system defined value
  91. ;rlimit_core = 0
  92. ; Specify the event mechanism FPM will use. The following is available:
  93. ; - select (any POSIX os)
  94. ; - poll (any POSIX os)
  95. ; - epoll (linux >= 2.5.44)
  96. ; - kqueue (FreeBSD >= 4.1, OpenBSD >= 2.9, NetBSD >= 2.0)
  97. ; - /dev/poll (Solaris >= 7)
  98. ; - port (Solaris >= 10)
  99. ; Default Value: not set (auto detection)
  100. ;events.mechanism = epoll
  101. ; When FPM is built with systemd integration, specify the interval,
  102. ; in seconds, between health report notification to systemd.
  103. ; Set to 0 to disable.
  104. ; Available Units: s(econds), m(inutes), h(ours)
  105. ; Default Unit: seconds
  106. ; Default value: 10
  107. ;systemd_interval = 10
  108. ;;;;;;;;;;;;;;;;;;;;
  109. ; Pool Definitions ;
  110. ;;;;;;;;;;;;;;;;;;;;
  111. ; Multiple pools of child processes may be started with different listening
  112. ; ports and different management options. The name of the pool will be
  113. ; used in logs and stats. There is no limitation on the number of pools which
  114. ; FPM can handle. Your system will tell you anyway :)
  115. ; Include one or more files. If glob(3) exists, it is used to include a bunch of
  116. ; files from a glob(3) pattern. This directive can be used everywhere in the
  117. ; file.
  118. ; Relative path can also be used. They will be prefixed by:
  119. ; - the global prefix if it's been set (-p argument)
  120. ; - /usr/local otherwise
  121. include=/etc/php-fpm.d/*.conf
  122. ; Start a new pool named 'www'.
  123. ; the variable $pool can be used in any directive and will be replaced by the
  124. ; pool name ('www' here)
  125. [www]
  126. ; Per pool prefix
  127. ; It only applies on the following directives:
  128. ; - 'access.log'
  129. ; - 'slowlog'
  130. ; - 'listen' (unixsocket)
  131. ; - 'chroot'
  132. ; - 'chdir'
  133. ; - 'php_values'
  134. ; - 'php_admin_values'
  135. ; When not set, the global prefix (or /usr/local) applies instead.
  136. ; Note: This directive can also be relative to the global prefix.
  137. ; Default Value: none
  138. ;prefix = /path/to/pools/$pool
  139. ; Unix user/group of processes
  140. ; Note: The user is mandatory. If the group is not set, the default user's group
  141. ; will be used.
  142. user = www
  143. group = www
  144. ; The address on which to accept FastCGI requests.
  145. ; Valid syntaxes are:
  146. ; 'ip.add.re.ss:port' - to listen on a TCP socket to a specific IPv4 address on
  147. ; a specific port;
  148. ; '[ip:6:addr:ess]:port' - to listen on a TCP socket to a specific IPv6 address on
  149. ; a specific port;
  150. ; 'port' - to listen on a TCP socket to all addresses
  151. ; (IPv6 and IPv4-mapped) on a specific port;
  152. ; '/path/to/unix/socket' - to listen on a unix socket.
  153. ; Note: This value is mandatory.
  154. ; If using a TCP port, never expose this to a public network.
  155. listen = /var/www/run/php-fpm.sock
  156. ; Set listen(2) backlog.
  157. ; Default Value: 511 (-1 on FreeBSD and OpenBSD)
  158. ;listen.backlog = 511
  159. ; Set permissions for unix socket, if one is used. In Linux, read/write
  160. ; permissions must be set in order to allow connections from a web server. Many
  161. ; BSD-derived systems allow connections regardless of permissions. The owner
  162. ; and group can be specified either by name or by their numeric IDs.
  163. ; Default Values: user and group are set as the running user
  164. ; mode is set to 0660
  165. listen.owner = www
  166. listen.group = www
  167. listen.mode = 0660
  168. ; When POSIX Access Control Lists are supported you can set them using
  169. ; these options, value is a comma separated list of user/group names.
  170. ; When set, listen.owner and listen.group are ignored
  171. ;listen.acl_users =
  172. ;listen.acl_groups =
  173. ; List of addresses (IPv4/IPv6) of FastCGI clients which are allowed to connect.
  174. ; Equivalent to the FCGI_WEB_SERVER_ADDRS environment variable in the original
  175. ; PHP FCGI (5.2.2+). Makes sense only with a tcp listening socket. Each address
  176. ; must be separated by a comma. If this value is left blank, connections will be
  177. ; accepted from any ip address.
  178. ; Default Value: any
  179. ;listen.allowed_clients = 127.0.0.1
  180. ; Specify the nice(2) priority to apply to the pool processes (only if set)
  181. ; The value can vary from -19 (highest priority) to 20 (lower priority)
  182. ; Note: - It will only work if the FPM master process is launched as root
  183. ; - The pool processes will inherit the master process priority
  184. ; unless it specified otherwise
  185. ; Default Value: no set
  186. ; process.priority = -19
  187. ; Set the process dumpable flag (PR_SET_DUMPABLE prctl) even if the process user
  188. ; or group is different than the master process user. It allows to create process
  189. ; core dump and ptrace the process for the pool user.
  190. ; Default Value: no
  191. ; process.dumpable = yes
  192. ; Choose how the process manager will control the number of child processes.
  193. ; Possible Values:
  194. ; static - a fixed number (pm.max_children) of child processes;
  195. ; dynamic - the number of child processes are set dynamically based on the
  196. ; following directives. With this process management, there will be
  197. ; always at least 1 children.
  198. ; pm.max_children - the maximum number of children that can
  199. ; be alive at the same time.
  200. ; pm.start_servers - the number of children created on startup.
  201. ; pm.min_spare_servers - the minimum number of children in 'idle'
  202. ; state (waiting to process). If the number
  203. ; of 'idle' processes is less than this
  204. ; number then some children will be created.
  205. ; pm.max_spare_servers - the maximum number of children in 'idle'
  206. ; state (waiting to process). If the number
  207. ; of 'idle' processes is greater than this
  208. ; number then some children will be killed.
  209. ; ondemand - no children are created at startup. Children will be forked when
  210. ; new requests will connect. The following parameter are used:
  211. ; pm.max_children - the maximum number of children that
  212. ; can be alive at the same time.
  213. ; pm.process_idle_timeout - The number of seconds after which
  214. ; an idle process will be killed.
  215. ; Note: This value is mandatory.
  216. pm = dynamic
  217. ; The number of child processes to be created when pm is set to 'static' and the
  218. ; maximum number of child processes when pm is set to 'dynamic' or 'ondemand'.
  219. ; This value sets the limit on the number of simultaneous requests that will be
  220. ; served. Equivalent to the ApacheMaxClients directive with mpm_prefork.
  221. ; Equivalent to the PHP_FCGI_CHILDREN environment variable in the original PHP
  222. ; CGI. The below defaults are based on a server without much resources. Don't
  223. ; forget to tweak pm.* to fit your needs.
  224. ; Note: Used when pm is set to 'static', 'dynamic' or 'ondemand'
  225. ; Note: This value is mandatory.
  226. pm.max_children = 5
  227. ; The number of child processes created on startup.
  228. ; Note: Used only when pm is set to 'dynamic'
  229. ; Default Value: (min_spare_servers + max_spare_servers) / 2
  230. pm.start_servers = 2
  231. ; The desired minimum number of idle server processes.
  232. ; Note: Used only when pm is set to 'dynamic'
  233. ; Note: Mandatory when pm is set to 'dynamic'
  234. pm.min_spare_servers = 1
  235. ; The desired maximum number of idle server processes.
  236. ; Note: Used only when pm is set to 'dynamic'
  237. ; Note: Mandatory when pm is set to 'dynamic'
  238. pm.max_spare_servers = 3
  239. ; The number of seconds after which an idle process will be killed.
  240. ; Note: Used only when pm is set to 'ondemand'
  241. ; Default Value: 10s
  242. ;pm.process_idle_timeout = 10s;
  243. ; The number of requests each child process should execute before respawning.
  244. ; This can be useful to work around memory leaks in 3rd party libraries. For
  245. ; endless request processing specify '0'. Equivalent to PHP_FCGI_MAX_REQUESTS.
  246. ; Default Value: 0
  247. ;pm.max_requests = 500
  248. ; The URI to view the FPM status page. If this value is not set, no URI will be
  249. ; recognized as a status page. It shows the following information:
  250. ; pool - the name of the pool;
  251. ; process manager - static, dynamic or ondemand;
  252. ; start time - the date and time FPM has started;
  253. ; start since - number of seconds since FPM has started;
  254. ; accepted conn - the number of request accepted by the pool;
  255. ; listen queue - the number of request in the queue of pending
  256. ; connections (see backlog in listen(2));
  257. ; max listen queue - the maximum number of requests in the queue
  258. ; of pending connections since FPM has started;
  259. ; listen queue len - the size of the socket queue of pending connections;
  260. ; idle processes - the number of idle processes;
  261. ; active processes - the number of active processes;
  262. ; total processes - the number of idle + active processes;
  263. ; max active processes - the maximum number of active processes since FPM
  264. ; has started;
  265. ; max children reached - number of times, the process limit has been reached,
  266. ; when pm tries to start more children (works only for
  267. ; pm 'dynamic' and 'ondemand');
  268. ; Value are updated in real time.
  269. ; Example output:
  270. ; pool: www
  271. ; process manager: static
  272. ; start time: 01/Jul/2011:17:53:49 +0200
  273. ; start since: 62636
  274. ; accepted conn: 190460
  275. ; listen queue: 0
  276. ; max listen queue: 1
  277. ; listen queue len: 42
  278. ; idle processes: 4
  279. ; active processes: 11
  280. ; total processes: 15
  281. ; max active processes: 12
  282. ; max children reached: 0
  283. ;
  284. ; By default the status page output is formatted as text/plain. Passing either
  285. ; 'html', 'xml' or 'json' in the query string will return the corresponding
  286. ; output syntax. Example:
  287. ; http://www.foo.bar/status
  288. ; http://www.foo.bar/status?json
  289. ; http://www.foo.bar/status?html
  290. ; http://www.foo.bar/status?xml
  291. ;
  292. ; By default the status page only outputs short status. Passing 'full' in the
  293. ; query string will also return status for each pool process.
  294. ; Example:
  295. ; http://www.foo.bar/status?full
  296. ; http://www.foo.bar/status?json&full
  297. ; http://www.foo.bar/status?html&full
  298. ; http://www.foo.bar/status?xml&full
  299. ; The Full status returns for each process:
  300. ; pid - the PID of the process;
  301. ; state - the state of the process (Idle, Running, ...);
  302. ; start time - the date and time the process has started;
  303. ; start since - the number of seconds since the process has started;
  304. ; requests - the number of requests the process has served;
  305. ; request duration - the duration in µs of the requests;
  306. ; request method - the request method (GET, POST, ...);
  307. ; request URI - the request URI with the query string;
  308. ; content length - the content length of the request (only with POST);
  309. ; user - the user (PHP_AUTH_USER) (or '-' if not set);
  310. ; script - the main script called (or '-' if not set);
  311. ; last request cpu - the %cpu the last request consumed
  312. ; it's always 0 if the process is not in Idle state
  313. ; because CPU calculation is done when the request
  314. ; processing has terminated;
  315. ; last request memory - the max amount of memory the last request consumed
  316. ; it's always 0 if the process is not in Idle state
  317. ; because memory calculation is done when the request
  318. ; processing has terminated;
  319. ; If the process is in Idle state, then informations are related to the
  320. ; last request the process has served. Otherwise informations are related to
  321. ; the current request being served.
  322. ; Example output:
  323. ; ************************
  324. ; pid: 31330
  325. ; state: Running
  326. ; start time: 01/Jul/2011:17:53:49 +0200
  327. ; start since: 63087
  328. ; requests: 12808
  329. ; request duration: 1250261
  330. ; request method: GET
  331. ; request URI: /test_mem.php?N=10000
  332. ; content length: 0
  333. ; user: -
  334. ; script: /home/fat/web/docs/php/test_mem.php
  335. ; last request cpu: 0.00
  336. ; last request memory: 0
  337. ;
  338. ; Note: There is a real-time FPM status monitoring sample web page available
  339. ; It's available in: /usr/local/share/php/fpm/status.html
  340. ;
  341. ; Note: The value must start with a leading slash (/). The value can be
  342. ; anything, but it may not be a good idea to use the .php extension or it
  343. ; may conflict with a real PHP file.
  344. ; Default Value: not set
  345. ;pm.status_path = /status
  346. ; The address on which to accept FastCGI status request. This creates a new
  347. ; invisible pool that can handle requests independently. This is useful
  348. ; if the main pool is busy with long running requests because it is still possible
  349. ; to get the status before finishing the long running requests.
  350. ;
  351. ; Valid syntaxes are:
  352. ; 'ip.add.re.ss:port' - to listen on a TCP socket to a specific IPv4 address on
  353. ; a specific port;
  354. ; '[ip:6:addr:ess]:port' - to listen on a TCP socket to a specific IPv6 address on
  355. ; a specific port;
  356. ; 'port' - to listen on a TCP socket to all addresses
  357. ; (IPv6 and IPv4-mapped) on a specific port;
  358. ; '/path/to/unix/socket' - to listen on a unix socket.
  359. ; Default Value: value of the listen option
  360. ;pm.status_listen = 127.0.0.1:9001
  361. ; The ping URI to call the monitoring page of FPM. If this value is not set, no
  362. ; URI will be recognized as a ping page. This could be used to test from outside
  363. ; that FPM is alive and responding, or to
  364. ; - create a graph of FPM availability (rrd or such);
  365. ; - remove a server from a group if it is not responding (load balancing);
  366. ; - trigger alerts for the operating team (24/7).
  367. ; Note: The value must start with a leading slash (/). The value can be
  368. ; anything, but it may not be a good idea to use the .php extension or it
  369. ; may conflict with a real PHP file.
  370. ; Default Value: not set
  371. ;ping.path = /ping
  372. ; This directive may be used to customize the response of a ping request. The
  373. ; response is formatted as text/plain with a 200 response code.
  374. ; Default Value: pong
  375. ;ping.response = pong
  376. ; The access log file
  377. ; Default: not set
  378. ;access.log = log/$pool.access.log
  379. ; The access log format.
  380. ; The following syntax is allowed
  381. ; %%: the '%' character
  382. ; %C: %CPU used by the request
  383. ; it can accept the following format:
  384. ; - %{user}C for user CPU only
  385. ; - %{system}C for system CPU only
  386. ; - %{total}C for user + system CPU (default)
  387. ; %d: time taken to serve the request
  388. ; it can accept the following format:
  389. ; - %{seconds}d (default)
  390. ; - %{milliseconds}d
  391. ; - %{mili}d
  392. ; - %{microseconds}d
  393. ; - %{micro}d
  394. ; %e: an environment variable (same as $_ENV or $_SERVER)
  395. ; it must be associated with embraces to specify the name of the env
  396. ; variable. Some examples:
  397. ; - server specifics like: %{REQUEST_METHOD}e or %{SERVER_PROTOCOL}e
  398. ; - HTTP headers like: %{HTTP_HOST}e or %{HTTP_USER_AGENT}e
  399. ; %f: script filename
  400. ; %l: content-length of the request (for POST request only)
  401. ; %m: request method
  402. ; %M: peak of memory allocated by PHP
  403. ; it can accept the following format:
  404. ; - %{bytes}M (default)
  405. ; - %{kilobytes}M
  406. ; - %{kilo}M
  407. ; - %{megabytes}M
  408. ; - %{mega}M
  409. ; %n: pool name
  410. ; %o: output header
  411. ; it must be associated with embraces to specify the name of the header:
  412. ; - %{Content-Type}o
  413. ; - %{X-Powered-By}o
  414. ; - %{Transfert-Encoding}o
  415. ; - ....
  416. ; %p: PID of the child that serviced the request
  417. ; %P: PID of the parent of the child that serviced the request
  418. ; %q: the query string
  419. ; %Q: the '?' character if query string exists
  420. ; %r: the request URI (without the query string, see %q and %Q)
  421. ; %R: remote IP address
  422. ; %s: status (response code)
  423. ; %t: server time the request was received
  424. ; it can accept a strftime(3) format:
  425. ; %d/%b/%Y:%H:%M:%S %z (default)
  426. ; The strftime(3) format must be encapsuled in a %{<strftime_format>}t tag
  427. ; e.g. for a ISO8601 formatted timestring, use: %{%Y-%m-%dT%H:%M:%S%z}t
  428. ; %T: time the log has been written (the request has finished)
  429. ; it can accept a strftime(3) format:
  430. ; %d/%b/%Y:%H:%M:%S %z (default)
  431. ; The strftime(3) format must be encapsuled in a %{<strftime_format>}t tag
  432. ; e.g. for a ISO8601 formatted timestring, use: %{%Y-%m-%dT%H:%M:%S%z}t
  433. ; %u: remote user
  434. ;
  435. ; Default: "%R - %u %t \"%m %r\" %s"
  436. ;access.format = "%R - %u %t \"%m %r%Q%q\" %s %f %{mili}d %{kilo}M %C%%"
  437. ; The log file for slow requests
  438. ; Default Value: not set
  439. ; Note: slowlog is mandatory if request_slowlog_timeout is set
  440. ;slowlog = log/$pool.log.slow
  441. ; The timeout for serving a single request after which a PHP backtrace will be
  442. ; dumped to the 'slowlog' file. A value of '0s' means 'off'.
  443. ; Available units: s(econds)(default), m(inutes), h(ours), or d(ays)
  444. ; Default Value: 0
  445. ;request_slowlog_timeout = 0
  446. ; Depth of slow log stack trace.
  447. ; Default Value: 20
  448. ;request_slowlog_trace_depth = 20
  449. ; The timeout for serving a single request after which the worker process will
  450. ; be killed. This option should be used when the 'max_execution_time' ini option
  451. ; does not stop script execution for some reason. A value of '0' means 'off'.
  452. ; Available units: s(econds)(default), m(inutes), h(ours), or d(ays)
  453. ; Default Value: 0
  454. ;request_terminate_timeout = 0
  455. ; The timeout set by 'request_terminate_timeout' ini option is not engaged after
  456. ; application calls 'fastcgi_finish_request' or when application has finished and
  457. ; shutdown functions are being called (registered via register_shutdown_function).
  458. ; This option will enable timeout limit to be applied unconditionally
  459. ; even in such cases.
  460. ; Default Value: no
  461. ;request_terminate_timeout_track_finished = no
  462. ; Set open file descriptor rlimit.
  463. ; Default Value: system defined value
  464. ;rlimit_files = 1024
  465. ; Set max core size rlimit.
  466. ; Possible Values: 'unlimited' or an integer greater or equal to 0
  467. ; Default Value: system defined value
  468. ;rlimit_core = 0
  469. ; Chroot to this directory at the start. This value must be defined as an
  470. ; absolute path. When this value is not set, chroot is not used.
  471. ; Note: you can prefix with '$prefix' to chroot to the pool prefix or one
  472. ; of its subdirectories. If the pool prefix is not set, the global prefix
  473. ; will be used instead.
  474. ; Note: chrooting is a great security feature and should be used whenever
  475. ; possible. However, all PHP paths will be relative to the chroot
  476. ; (error_log, sessions.save_path, ...).
  477. ; Default Value: not set
  478. chroot = /var/www
  479. ; Chdir to this directory at the start.
  480. ; Note: relative path can be used.
  481. ; Default Value: current directory or / when chroot
  482. ;chdir = /var/www
  483. ; Redirect worker stdout and stderr into main error log. If not set, stdout and
  484. ; stderr will be redirected to /dev/null according to FastCGI specs.
  485. ; Note: on highloaded environment, this can cause some delay in the page
  486. ; process time (several ms).
  487. ; Default Value: no
  488. ;catch_workers_output = yes
  489. ; Decorate worker output with prefix and suffix containing information about
  490. ; the child that writes to the log and if stdout or stderr is used as well as
  491. ; log level and time. This options is used only if catch_workers_output is yes.
  492. ; Settings to "no" will output data as written to the stdout or stderr.
  493. ; Default value: yes
  494. ;decorate_workers_output = no
  495. ; Clear environment in FPM workers
  496. ; Prevents arbitrary environment variables from reaching FPM worker processes
  497. ; by clearing the environment in workers before env vars specified in this
  498. ; pool configuration are added.
  499. ; Setting to "no" will make all environment variables available to PHP code
  500. ; via getenv(), $_ENV and $_SERVER.
  501. ; Default Value: yes
  502. ;clear_env = no
  503. ; Limits the extensions of the main script FPM will allow to parse. This can
  504. ; prevent configuration mistakes on the web server side. You should only limit
  505. ; FPM to .php extensions to prevent malicious users to use other extensions to
  506. ; execute php code.
  507. ; Note: set an empty value to allow all extensions.
  508. ; Default Value: .php
  509. ;security.limit_extensions = .php .php3 .php4 .php5 .php7
  510. ; Pass environment variables like LD_LIBRARY_PATH. All $VARIABLEs are taken from
  511. ; the current environment.
  512. ; Default Value: clean env
  513. ;env[HOSTNAME] = $HOSTNAME
  514. ;env[PATH] = /usr/local/bin:/usr/bin:/bin
  515. ;env[TMP] = /tmp
  516. ;env[TMPDIR] = /tmp
  517. ;env[TEMP] = /tmp
  518. ; Additional php.ini defines, specific to this pool of workers. These settings
  519. ; overwrite the values previously defined in the php.ini. The directives are the
  520. ; same as the PHP SAPI:
  521. ; php_value/php_flag - you can set classic ini defines which can
  522. ; be overwritten from PHP call 'ini_set'.
  523. ; php_admin_value/php_admin_flag - these directives won't be overwritten by
  524. ; PHP call 'ini_set'
  525. ; For php_*flag, valid values are on, off, 1, 0, true, false, yes or no.
  526. ; Defining 'extension' will load the corresponding shared extension from
  527. ; extension_dir. Defining 'disable_functions' or 'disable_classes' will not
  528. ; overwrite previously defined php.ini values, but will append the new value
  529. ; instead.
  530. ; Note: path INI options can be relative and will be expanded with the prefix
  531. ; (pool, global or /usr/local)
  532. ; Default Value: nothing is defined by default except the values in php.ini and
  533. ; specified at startup with the -d argument
  534. ;php_admin_value[sendmail_path] = /usr/sbin/sendmail -t -i -f www@my.domain.com
  535. ;php_flag[display_errors] = off
  536. ;php_admin_value[error_log] = /var/log/fpm-php.www.log
  537. ;php_admin_flag[log_errors] = on
  538. ;php_admin_value[memory_limit] = 32M