File: 0044-Disable-garbage-collection-routine.patch

package info (click to toggle)
php8.4 8.4.11-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 208,108 kB
  • sloc: ansic: 1,060,628; php: 35,345; sh: 11,866; cpp: 7,201; pascal: 4,913; javascript: 3,091; asm: 2,810; yacc: 2,411; makefile: 689; xml: 446; python: 301; awk: 148
file content (54 lines) | stat: -rw-r--r-- 2,284 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
From: Athos Ribeiro <athos.ribeiro@canonical.com>
Date: Sat, 20 Jan 2024 14:01:24 +0100
Subject: Disable GC in ini files

Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=831752
Bug-Ubuntu: https://bugs.launchpad.net/debian/+source/php7.3/+bug/1772915
Forwarded: not-needed
Last-Update: 2024-01-19

This is disabled in the Debian packages due to the strict permissions on
/var/lib/php. Instead, GC is performed through /etc/cron.d/php, which uses the
session.gc_maxlifetime setting.
Last-Update: 2024-01-19
---
 php.ini-development | 7 ++++++-
 php.ini-production  | 7 ++++++-
 2 files changed, 12 insertions(+), 2 deletions(-)

diff --git a/php.ini-development b/php.ini-development
index 6509686..ef35f3e 100644
--- a/php.ini-development
+++ b/php.ini-development
@@ -1362,7 +1362,12 @@ session.serialize_handler = php
 ; Development Value: 1
 ; Production Value: 1
 ; https://php.net/session.gc-probability
-session.gc_probability = 1
+; Debian Default Value: 0
+; This is disabled in the Debian packages due to the strict permissions
+; on /var/lib/php. Instead, GC is performed through /etc/cron.d/php,
+; which uses the session.gc_maxlifetime setting. Please, check
+; /usr/share/doc/php8.3-common/README.Debian.gz for further reference.
+session.gc_probability = 0
 
 ; Defines the probability that the 'garbage collection' process is started on every
 ; session initialization. The probability is calculated by using gc_probability/gc_divisor,
diff --git a/php.ini-production b/php.ini-production
index e0c83c8..d0ef58b 100644
--- a/php.ini-production
+++ b/php.ini-production
@@ -1358,7 +1358,12 @@ session.serialize_handler = php
 ; Development Value: 1
 ; Production Value: 1
 ; https://php.net/session.gc-probability
-session.gc_probability = 1
+; Debian Default Value: 0
+; This is disabled in the Debian packages due to the strict permissions
+; on /var/lib/php. Instead, GC is performed through /etc/cron.d/php,
+; which uses the session.gc_maxlifetime setting. Please, check
+; /usr/share/doc/php8.2-common/README.Debian.gz for further reference.
+session.gc_probability = 0
 
 ; Defines the probability that the 'garbage collection' process is started on every
 ; session initialization. The probability is calculated by using gc_probability/gc_divisor,