New error installing (docker)

635 views
Skip to first unread message

tat...@gmail.com

unread,
Mar 1, 2019, 4:08:47 PM3/1/19
to AtoM Users
Hello group!

Creating a new AtoM installation from docker, I got this new error message:

creating libtool
appending configuration tag
"CXX" to libtool
configure
: creating ./config.status
config
.status: creating config.h
+ make
/bin/sh /pecl-memcache-NON_BLOCKING_IO_php7/libtool --mode=compile cc -I/usr/local/include/php -I. -I/pecl-memcache-NON_BLOCKING_IO_php7 -DPHP_ATOM_INC -I/pecl-memcache-NON_BLOCKING_IO_php7/include -I/pecl-memcache-NON_BLOCKING_IO_php7/main -I/pecl-memcache-NON_BLOCKING_IO_php7 -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib  -DHAVE_CONFIG_H  -g -O2   -c /pecl-memcache-NON_BLOCKING_IO_php7/php7/memcache.c -o php7/memcache.lo
mkdir php7
/.libs
 cc
-I/usr/local/include/php -I. -I/pecl-memcache-NON_BLOCKING_IO_php7 -DPHP_ATOM_INC -I/pecl-memcache-NON_BLOCKING_IO_php7/include -I/pecl-memcache-NON_BLOCKING_IO_php7/main -I/pecl-memcache-NON_BLOCKING_IO_php7 -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /pecl-memcache-NON_BLOCKING_IO_php7/php7/memcache.c  -fPIC -DPIC -o php7/.libs/memcache.o
/pecl-memcache-NON_BLOCKING_IO_php7/php7/memcache.c: In function 'php_mmc_store':
/pecl-memcache-NON_BLOCKING_IO_php7/php7/memcache.c:643:8: error: too many arguments to function 'mmc_prepare_key_ex'
   
if (mmc_prepare_key_ex(ZSTR_VAL(key), ZSTR_LEN(key), request->key, &(request->key_len), MEMCACHE_G(key_prefix)) != MMC_OK) {
       
^~~~~~~~~~~~~~~~~~
In file included from /pecl-memcache-NON_BLOCKING_IO_php7/php7/php_memcache.h:34:0,
                 
from /pecl-memcache-NON_BLOCKING_IO_php7/php7/memcache.c:30:
/pecl-memcache-NON_BLOCKING_IO_php7/php7/memcache_pool.h:399:5: note: declared here
 
int mmc_prepare_key_ex(const char *, unsigned int, char *, unsigned int *);
     
^~~~~~~~~~~~~~~~~~
make
: *** [Makefile:194: php7/memcache.lo] Error 1
ERROR
: Service 'atom' failed to build: The command '/bin/sh -c set -xe          && apk add --no-cache --virtual .phpext-builddeps                       gettext-dev                     libmcrypt-dev                   libxslt-dev                     zlib-dev                        libmemcached-dev                    autoconf                         build-base              && docker-php-ext-install                       calendar                        gettext                         mbstring                        mcrypt                  mysqli                  opcache                         pdo_mysql                       sockets                      xsl                     zip             && curl -Ls https://github.com/websupport-sk/pecl-memcache/archive/NON_BLOCKING_IO_php7.tar.gz | tar xz -C /            && cd /pecl-memcache-NON_BLOCKING_IO_php7               && phpize && ./configure && make && make install                && docker-php-ext-enable memcache            && rm -rf /pecl-memcache-NON_BLOCKING_IO_php7           && apk add --virtual .phpext-rundeps                    gettext                         libmcrypt                       libxslt                         libmemcached-libs               && apk del .phpext-builddeps' returned a non-zero code: 2



Did something change in any package? Because I just did this installation a few days ago and it was okay.

Thanks,
Tatiana Canelhas

José Raddaoui

unread,
Mar 4, 2019, 6:37:02 AM3/4/19
to AtoM Users
Hi Tatiana,

We recently found some issues installing the Memcache extension over PHP 7.3 in the Dockerfile, a teammate created this commit to fix that issue a couple of weeks ago. I'm not sure if you're facing the same issue but, if you're missing that commit, I'd give it a try.

Please, let us know if that works.

Best regards.

tat...@gmail.com

unread,
Mar 4, 2019, 11:35:22 AM3/4/19
to AtoM Users
Hi José, thanks for your repply.

I tried changing my file to this commit, but got on the same issue:

creating libtool
appending configuration tag
"CXX" to libtool
configure
: creating ./config.status
config
.status: creating config.h
+ make
/bin/sh /pecl-memcache-NON_BLOCKING_IO_php7/libtool --mode=compile cc -I/usr/local/include/php -I. -I/pecl-memcache-NON_BLOCKING_IO_php7 -DPHP_ATOM_INC -I/pecl-memcache-NON_BLOCKING_IO_php7/include -I/pecl-memcache-NON_BLOCKING_IO_php7/main -I/pecl-memcache-NON_BLOCKING_IO_php7 -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib  -DHAVE_CONFIG_H  -g -O2   -c /pecl-memcache-NON_BLOCKING_IO_php7/php7/memcache.c -o php7/memcache.lo
mkdir php7
/.libs
 cc
-I/usr/local/include/php -I. -I/pecl-memcache-NON_BLOCKING_IO_php7 -DPHP_ATOM_INC -I/pecl-memcache-NON_BLOCKING_IO_php7/include -I/pecl-memcache-NON_BLOCKING_IO_php7/main -I/pecl-memcache-NON_BLOCKING_IO_php7 -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /pecl-memcache-NON_BLOCKING_IO_php7/php7/memcache.c  -fPIC -DPIC -o php7/.libs/memcache.o
/pecl-memcache-NON_BLOCKING_IO_php7/php7/memcache.c: In function 'php_mmc_store':
/pecl-memcache-NON_BLOCKING_IO_php7/php7/memcache.c:643:8: error: too many arguments to function 'mmc_prepare_key_ex'
   
if (mmc_prepare_key_ex(ZSTR_VAL(key), ZSTR_LEN(key), request->key, &(request->key_len), MEMCACHE_G(key_prefix)) != MMC_OK) {
       
^~~~~~~~~~~~~~~~~~
In file included from /pecl-memcache-NON_BLOCKING_IO_php7/php7/php_memcache.h:34,

                 
from /pecl-memcache-NON_BLOCKING_IO_php7/php7/memcache.c:30:
/pecl-memcache-NON_BLOCKING_IO_php7/php7/memcache_pool.h:399:5: note: declared here
 
int mmc_prepare_key_ex(const char *, unsigned int, char *, unsigned int *);
     
^~~~~~~~~~~~~~~~~~
make
: *** [Makefile:194: php7/memcache.lo] Error 1

ERROR
: Service 'atom' failed to build: The command '/bin/sh -c set -xe          && apk add --no-cache --virtual .phpext-builddeps                       gettext-dev                  libxslt-dev                     libzip-dev                      zlib-dev                        libmemcached-dev                    autoconf                         build-base              && docker-php-ext-install                       calendar                        gettext             mbstring                         mysqli                  opcache                         pdo_mysql                       sockets                         xsl zip              && docker-php-ext-configure zip --with-libzip           && docker-php-ext-install zip           && curl -Ls https://github.com/websupport-sk/pecl-memcache/archive/NON_BLOCKING_IO_php7.tar.gz | tar xz -C /                 && cd /pecl-memcache-NON_BLOCKING_IO_php7               && phpize && ./configure && make && make install             && docker-php-ext-enable memcache               && rm -rf /pecl-memcache-NON_BLOCKING_IO_php7           && apk add --virtual .phpext-rundeps                         gettext                         libxslt                         libmemcached-libs               && apk del .phpext-builddeps' returned a non-zero code: 2


Still don´t know whats´s going on, because in a few days ago it was working.

Thanks.
Tatiana

Damian Bauder

unread,
Mar 6, 2019, 1:28:09 PM3/6/19
to AtoM Users
Has anybody made progress with this issue? I just encountered it today, both before and after applying the commit José mentioned. I haven't had time to look too closely, but perhaps something changed in the latest memcache package?

Cheers,

Damian

raddao...@gmail.com

unread,
Mar 6, 2019, 1:34:01 PM3/6/19
to AtoM Users
Hi Tatiana and Damian,

I'm experiencing the same issue now, this seems to be related:


I'm looking for a workaround but I don't have a proper solution yet.

Regards.

Damian Bauder

unread,
Mar 6, 2019, 3:00:45 PM3/6/19
to AtoM Users
Thanks, José, appreciate it!

Damian Bauder

unread,
Mar 6, 2019, 3:09:59 PM3/6/19
to AtoM Users

It mentions a commit that might work for now.

Damian

raddao...@gmail.com

unread,
Mar 6, 2019, 4:01:50 PM3/6/19
to AtoM Users
Thanks Damian,

That issue has a lot more info than the one I found. We could temporarily use the commit mentioned in there by changing the following lines in the AtoM Dockerfile:


To this ones:

&& cd /websupport-sk-pecl-memcache-4a9e4ab \
&& phpize && ./configure && make && make install \
&& docker-php-ext-enable memcache \
&& rm -rf /websupport-sk-pecl-memcache-4a9e4ab \

Please, let us know how it goes.

Regards.

tat...@gmail.com

unread,
Mar 7, 2019, 3:42:34 PM3/7/19
to AtoM Users
Hi Guys,

My co-worker Nilton Freitas changed the Dockerfile (as attached) and the installation worked for me.

Can you test it too???

Tatiana Canelhas
Dockerfile

Ricardo Pinho - CM Oliveira Azemeis

unread,
Mar 7, 2019, 4:20:47 PM3/7/19
to AtoM Users
Thank you Tatiana, your Dockerfile worked for me!

Damian Bauder

unread,
Mar 8, 2019, 1:30:55 PM3/8/19
to AtoM Users
Hi Tatiana and Ricardo,

I prefer the attached Dockerfile, which uses José's suggested changes. I haven't looked that closely, but I think the commit José references is from earlier in the same branch, which is considerably more up-to-date than the php7 branch that Tatiana's co-worker integrated.

Also, as a sidenote, at least when cloning from stable/2.4.x, I did not need to apply the patch for the memcache issue José recommended earlier. If you're working on qa, however, I expect it's needed.

Cheers,

Damian
Dockerfile

Damian Bauder

unread,
Mar 8, 2019, 1:35:14 PM3/8/19
to AtoM Users
And I belatedly decided to compare Tatiana's and my Dockerfiles and spotted more differences. It's probably best to take these with a grain of salt, and integrate only the changes you need rather than straight up running them ;-)

Damian

Ricardo Pinho

unread,
Mar 14, 2019, 8:33:51 AM3/14/19
to ica-ato...@googlegroups.com
Dear Radda,
I come to warn Artefactual to please consider reviewing this topic,
because it seems that if someone follows the following guide today:
https://www.accesstomemory.org/pt/docs/2.4/dev-manual/env/compose/
Still will end up with this error building docker.
Thank you in advance.
Best regards,
Ricardo Pinho

--
You received this message because you are subscribed to the Google Groups "AtoM Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ica-atom-user...@googlegroups.com.
To post to this group, send email to ica-ato...@googlegroups.com.
Visit this group at https://groups.google.com/group/ica-atom-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/ica-atom-users/1ccfde1f-45f0-406c-9ba8-6aa318f15c15%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


--
Ricardo Pinho

José Raddaoui

unread,
Mar 14, 2019, 10:00:10 AM3/14/19
to ica-ato...@googlegroups.com
Thanks for the warning Ricardo,

I didn't want to introduce that temporary change in the Dockerfile as I was expecting they to fix the issue quickly, which seems to be the case as of two days ago. You should be able to rebuild the two containers using the Dockerfile (without cache):

docker-compose build --no-cache atom atom_worker
docker-compose up -d

Best regards.

Ricardo Pinho

unread,
Mar 14, 2019, 11:02:38 AM3/14/19
to ica-ato...@googlegroups.com
Hi,
I'm sorry to insist, but I've just tried to run docker compose on a clean install (VM) and the error remains.

Both 2.4.1 & stable/2.4.x

include lines:
[001] FROM php:7.0-fpm-alpine
and
[028] && curl -Ls https://github.com/websupport-sk/pecl-memcache/archive/NON_BLOCKING_IO_php7.tar.gz | tar xz -C / \

To solve the problem Damian suggested replacing:
[028] && curl -Ls https://github.com/websupport-sk/pecl-memcache/tarball/4a9e4ab | tar xz -C / \ 

Tatiana suggested another solution but with several more changes.

Of course "qa/2.5.x" is another different version.

Cheers,
Ricardo Pinho


For more options, visit https://groups.google.com/d/optout.


--
Ricardo Pinho

José Raddaoui

unread,
Mar 14, 2019, 12:46:55 PM3/14/19
to ica-ato...@googlegroups.com
Not a problem Ricardo,

Thanks for pointing this out. Both Dockerfiles use the same "pecl-memcache/NON_BLOCKING_IO_php7" branch, the main difference is that in stable/2.4.x we're using PHP 7.0 and in qa/2.5.x we use PHP 7.2. They fixed the error we mentioned before for 7.2, but it looks to be a different one for 7.0 and 7.1:


Which already has a pull request (not merged yet):


I know it's not ideal that you have to make a temporary change in the Dockerfile for the time being, but they may fix the issue before we make the temporary change in the main AtoM code. As a side note, the Docker image and Docker Compose environment we provide are not fully prepared for production environments, this is one of the reasons why.

Best regards.

Tatiana

unread,
Mar 14, 2019, 1:09:30 PM3/14/19
to ica-ato...@googlegroups.com
Ricardo,

you need to change your Dockerfile in order to install AtoM, as José said before.  Do you know how to do this? If you don't, maybe I can help you. Let me know.

Best regards.  
Tatiana Canelhas

You received this message because you are subscribed to a topic in the Google Groups "AtoM Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/ica-atom-users/vKuufhhf0Sg/unsubscribe.
To unsubscribe from this group and all its topics, send an email to ica-atom-user...@googlegroups.com.

To post to this group, send email to ica-ato...@googlegroups.com.
Visit this group at https://groups.google.com/group/ica-atom-users.

Ricardo Pinho

unread,
Mar 15, 2019, 6:24:40 AM3/15/19
to ica-ato...@googlegroups.com
Thank you Radda and Tatiana,
Yes, if I change the original Dockerfile the compose runs successfully.

If you don't see any inconveniency, in the mean time (we wait for the merging), I may suggest to include in the manual (wiki):

Just after the line:
git clone -b stable/2.4.x https://github.com/artefactual/atom.git atom
cd atom
Add something like:
"Replace Dockerfile"
mv docker/Dockerfile  atom/docker/Dockerfile_orig

I've tried the version AtoM 2.4.x version with the PHP 7.2 and it seems to work fine.
Besides the following side effect:
Deprecated: Function create_function() is deprecated in /atom/src/vendor/symfony/lib/config/sfConfigHandler.class.php on line 78
Deprecated: Function create_function() is deprecated in /atom/src/vendor/symfony/lib/config/sfConfigHandler.class.php on line 78
Deprecated: Function create_function() is deprecated in /atom/src/vendor/symfony/lib/config/sfConfigHandler.class.php on line 99
Deprecated: Function create_function() is deprecated in /atom/src/vendor/symfony/lib/config/sfConfigHandler.class.php on line 78
Deprecated: Function create_function() is deprecated in /atom/src/vendor/symfony/lib/config/sfConfigHandler.class.php on line 78


Finally, If I may, my opinion has a user and advice to Artefactual is to invest seriously on a Docker production install for the next release: 2.5!!!
It will certainly l spare the user (and support channel) many problems on the install and configuration phase.

Cheers,
Ricardo Pinho



For more options, visit https://groups.google.com/d/optout.


--
Ricardo Pinho
Reply all
Reply to author
Forward
0 new messages