Giter Site home page Giter Site logo

docker-pxc's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

mdfeng k00p nfntynl

docker-pxc's Issues

pxc-server not starting when using persistent storage

Hello!
First of all thanks for your work on the rancher catalog PXC-Cluster! It is really handy!
And now for my issue.

Cluster starts fine except when using host mount or volume driver share with pxc-data volumes.

Following my docker-compose.yml:

pxc-clustercheck:
image: flowman/percona-xtradb-cluster-clustercheck:v2.0
net: "container:pxc"
labels:
io.rancher.container.hostname_override: container_name
volumes_from:
- 'pxc-data'
pxc-server:
image: flowman/percona-xtradb-cluster:5.6.28-1
net: "container:pxc"
environment:
MYSQL_ROOT_PASSWORD: <pass>
PXC_SST_PASSWORD: <pass>
labels:
io.rancher.container.hostname_override: container_name
volumes_from:
- 'pxc-data'
entrypoint: bash -x /opt/rancher/start_pxc
pxc-data:
image: flowman/percona-xtradb-cluster:5.6.28-1
net: none
environment:
MYSQL_ALLOW_EMPTY_PASSWORD: "yes"
volumes:
- /data/mysql:/var/lib/mysql
- /etc/mysql/conf.d
- /docker-entrypoint-initdb.d
command: /bin/true
labels:
io.rancher.container.start_once: true
pxc:
image: flowman/percona-xtradb-cluster-confd:v0.2.0
labels:
io.rancher.sidekicks: pxc-clustercheck,pxc-server,pxc-data
io.rancher.container.hostname_override: container_name
io.rancher.scheduler.affinity:container_label_soft_ne: io.rancher.stack_service.name=$${stack_name}/$${service_name}
volumes_from:
- 'pxc-data'
When I try using any persistent volume I get this error:

03/08/2016 10:37:03MySQL init process done. Ready for start up.
03/08/2016 10:37:03
03/08/2016 10:37:042016-08-03 13:37:04 0 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead.
03/08/2016 10:37:042016-08-03 13:37:04 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
03/08/2016 10:37:042016-08-03 13:37:04 0 [Note] mysqld (mysqld 5.6.28-76.1-56) starting as process 1 ...
03/08/2016 10:37:052016-08-03 13:37:05 1 [Note] WSREP: Read nil XID from storage engines, skipping position init
03/08/2016 10:37:052016-08-03 13:37:05 1 [Note] WSREP: wsrep_load(): loading provider library '/usr/lib/libgalera_smm.so'
03/08/2016 10:37:052016-08-03 13:37:05 1 [Note] WSREP: wsrep_load(): Galera 3.14(r53b88eb) by Codership Oy <[email protected]> loaded successfully.
03/08/2016 10:37:052016-08-03 13:37:05 1 [Note] WSREP: CRC-32C: using hardware acceleration.
03/08/2016 10:37:052016-08-03 13:37:05 1 [Note] WSREP: Found saved state: 00000000-0000-0000-0000-000000000000:-1
03/08/2016 10:37:052016-08-03 13:37:05 1 [ERROR] WSREP: Failed to open file '/var/lib/mysql//galera.cache': 1 (Operation not permitted)
03/08/2016 10:37:05 at galerautils/src/gu_fdesc.cpp:constructor_common():138
03/08/2016 10:37:052016-08-03 13:37:05 1 [ERROR] WSREP: wsrep::init() failed: 7, must shutdown
03/08/2016 10:37:052016-08-03 13:37:05 1 [ERROR] Aborting
03/08/2016 10:37:05
03/08/2016 10:37:052016-08-03 13:37:05 1 [Note] Binlog end
03/08/2016 10:37:052016-08-03 13:37:05 1 [Note] mysqld: Shutdown complete

And then PXC-server instance stops.

Scalling does not work

@Flowman Tried to scale the service but got a bunch of containers with postfix of 1 instead of 4 (after 3). It did deploy the containers to an empty host fine.
Everything else went to running except for the mysql process initializing forever.

Not sure if this catalog is just meant to be use with 3 with no scalling featured built in mind.

[WIP] Creating or migrating this image to alpine

Instead of opening a PR, I've decided to open a issue so we can discuss openly.

Dockerfile

FROM alpine:3.3
LABEL authors="Peter Szalatnay <[email protected]>, José Moreira <[email protected]>"

ENV \
    PERCONA_SOURCE_CODE="https://github.com/percona/percona-xtradb-cluster/archive/5.7.tar.gz" \
    BASE_APKS="curl ca-certificates" \
    BUILD_APKS="tar build-base pwgen openssl bsd-compat-headers libstdc++=5.3.0-r0 libaio gnutls ncurses-libs readline-dev libxml2 boost alpine-sdk cmake ncurses-dev gnutls-dev curl-dev libxml2-dev libaio-dev linux-headers bison boost-dev=1.59.0-r0"

RUN \
    echo http://nl.alpinelinux.org/alpine/edge/main >> /etc/apk/repositories && \
    apk add $BASE_APKS $BUILD_APKS && \
    update-ca-certificates && \
    mkdir -p /tmp/percona && \
    curl -L $PERCONA_SOURCE_CODE | tar xvzf - --directory /tmp/percona --strip-components=1 && \
    cd /tmp/percona && \
    cmake . && \
    make && \
    apk del $BUILD_APKS

#WIP

PATCHES:

configure.cmake

IF(HAVE_KQUEUE AND HAVE_EVFILT_TIMER)
  SET(HAVE_KQUEUE_TIMERS 1 CACHE INTERNAL "Have kqueue timer-related filter")
ELSEIF(HAVE_TIMER_CREATE AND HAVE_TIMER_SETTIME)
-  IF(HAVE_SIGEV_THREAD_ID OR HAVE_SIGEV_PORT)
+#  IF(HAVE_SIGEV_THREAD_ID OR HAVE_SIGEV_PORT)
    SET(HAVE_POSIX_TIMERS 1 CACHE INTERNAL "Have POSIX timer-related functions")
-  ENDIF()
+#  ENDIF()
ENDIF()

Questions about alpine branch, etcd and percona-xtrabackup

Hello @Flowman,

I used your "old" template from rancher community catalog, but it's old and not maintained.

So I searched for newer mysql-cluster and found your alpine branch and custom catalog. It's updated some month ago. Could you describe the difference to the old image?

  1. Is the alpine branch stable / maintained?
  2. Why etcd is used (would be nice to know ;) )
  3. Is percona-xtrabackup integrated for automatic database backups? How could it used?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.