Public bug reported:

# lsb_release -rd
Description:    Ubuntu 16.04.1 LTS
Release:        16.04

# apt-cache policy php7.0-common
php7.0-common:
  Installed: 7.0.13-0ubuntu0.16.04.1
  Candidate: 7.0.15-1+deb.sury.org~xenial+1
  Version table:
     7.0.15-1+deb.sury.org~xenial+1 500
        500 http://ppa.launchpad.net/ondrej/php/ubuntu xenial/main amd64 
Packages
 *** 7.0.13-0ubuntu0.16.04.1 500
        500 http://ubuntu.mirror.true.nl/ubuntu xenial-updates/main amd64 
Packages
        100 /var/lib/dpkg/status
     7.0.8-0ubuntu0.16.04.3 500
        500 http://ubuntu.mirror.true.nl/ubuntu xenial-security/main amd64 
Packages
     7.0.4-7ubuntu2 500
        500 http://ubuntu.mirror.true.nl/ubuntu xenial/main amd64 Packages


When using multiple values for session.save_path with session.save_handler 
redis / memcache, a session_start results in an out of memory error:


# php session.php

mmap() failed: [12] Cannot allocate memory

mmap() failed: [12] Cannot allocate memory
PHP Fatal error:  Out of memory (allocated 2097152) (tried to allocate 
18446744073709545761 bytes) in /root/session.php on line 2


To reproduce:

php.ini

session.save_handler = memcache
session.save_path = "tcp://127.0.0.1:11211,tcp://127.0.0.1:11212" 

(doesn't have to be a working memcache instance, tested it both ways)

session.php

<?php
session_start();
?>


Same issue when using redis instead of memcache. When using just one value in 
the save_path, it works without issues.

This issue was not present in 7.0.8-0ubuntu0.1. When upgrading to
7.0.15-1+deb.sury.org~xenial+1
(https://launchpad.net/~ondrej/+archive/ubuntu/php) it works without
problem.

Also see: https://bugs.php.net/bug.php?id=73729 (wasn't able to find the
commit where the issue was fixed)

** Affects: php7.0 (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1661580

Title:
  Out of memory session_start

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/php7.0/+bug/1661580/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to