I had implemented a few  HA services using pacemaker+drbd on Centos 7.2.
I like to implement the the same for gitlab-ce to have 1st and 2nd VM write 
shared drbd disk/filesystem via network.(See R1)
/var/opt/gitlab, /etc/gitlab and /var/log/gitlab are all reside on drbd 
drive mounted as /pub dir. following are the links pointing to shard drbd 
drive /pub

[root@re02 ~]# ls -ld /etc/gitlab /var/log/gitlab /var/opt/gitlab
lrwxrwxrwx 1 root root 22 Jun 13 12:42 /etc/gitlab -> /pub/gitlab/etc/gitlab
lrwxrwxrwx 1 root root 26 Jun 13 12:30 /var/log/gitlab -> 
/pub/gitlab/var/log/gitlab
lrwxrwxrwx 1 root root 26 Jun 13 12:36 /var/opt/gitlab -> 
/pub/gitlab/var/opt/gitlab
[root@re02 ~]# ls -ld /pub/gitlab/*/*/*
-rw-------  1 root root 35792 Jun 12 07:36 /pub/gitlab/etc/gitlab/gitlab.rb
-rw-------  1 root root 35904 Jun 10 17:41 /pub/gitlab/etc/gitlab/gitlab.rb~
-rw-------  1 root root 35904 Jun 12 06:44 
/pub/gitlab/etc/gitlab/gitlab.rb.orig
-rw-------  1 root root  6347 Jun 13 14:06 
/pub/gitlab/etc/gitlab/gitlab-secrets.json
drwxr-xr-x  2 root root  4096 Jun 10 17:25 /pub/gitlab/etc/gitlab/ssl
drwxr-xr-x 12 git  root  4096 Jun 13 12:30 /pub/gitlab/var/log/gitlab
drwxr-xr-x 13 root root  4096 Jun 13 14:06 /pub/gitlab/var/opt/gitlab
[root@re02 ~]#


I shutdown the 1st VM cleanly to relase /pub and failed over /pub to 2nd 
VM. But I can not startup gitlab-ce instance on 2nd VM. Even I tried to run 
"gitlab-ctl reconfigure", it hang at unicorn_sleep.

    @@ -1 +1,4 @@
    +#!/bin/sh
    +echo "Received TERM from runit, sending to process group (-PID)"
    +kill -- -$(cat /opt/gitlab/service/unicorn/supervise/pid)
    - change mode from '' to '0755'
    - change owner from '' to 'root'
    - change group from '' to 'root'
  * link[/opt/gitlab/init/unicorn] action create
    - create symlink at /opt/gitlab/init/unicorn to 
/opt/gitlab/embedded/bin/sv
  * link[/opt/gitlab/service/unicorn] action create
    - create symlink at /opt/gitlab/service/unicorn to 
/opt/gitlab/sv/unicorn
  * ruby_block[supervise_unicorn_sleep] action run



Anyone can give some pointer why reconfigure hang on 2nd VM with data from 
1st VM ?

Currently I plan to do fail-over manually. Once I got more understanding of 
gitlab-ctl and runsvcdir systemd serivice.
I will attempt to write the OCF agent for gitlab-ce service.

R1. 
https://gitlab.com/gitlab-org/gitlab-ce/raw/master/doc/administration/img/high_availability/active-passive-diagram.png


On Tuesday, April 28, 2015 at 9:43:17 PM UTC-5, Kendall Green wrote:
>
> Does anyone have solution for how to manage HA for GitLab CE?
>  
> Here's the challenges, currently with old version GitLab non-omnibus 
> install on mysql 5.1, and needs to be upgraded soon, non-omnibus and setup 
> with high-availability. 
>
> I will probably need to upgrade again, without using omnibus, or 
> postgresql. Are there any documents specific for this?
>
> I attempted this before discovering that I can't use pgsql, I had followed 
> procedures in docs for converting database to pgsql and upgraded with 
> omnibus to latest version. That appeared to work correctly despite LDAP 
> config part and some odd index already exists output for converting to 
> postgresql. The issue is, this embedded redis and postgres doesn't have HA 
> / clustering for gitlab, and I have to use mysql instead of pgsql. 
>
> I think this means that I will need to take my existing old gitlab on 
> mysql innodb, convert to ndb(unsure of) for HA, and attempt a custom setup 
> for both redis cluster and mysql_cluster, and the data on nfs... I'm not 
> sure if there are any database issues with MySQL_Cluster, and GitLab, or if 
> there are any related docs or anyone can reply with best approach at HA 
> with latest release GitLab using MySQL database and redis cluster as it 
> relates to the application.
>
> Thank you!
>
> -Kendall Green
>
>   
>
> On Thursday, October 11, 2012 at 9:54:53 AM UTC-7, Steve Pereira wrote:
>>
>> Does anyone have any experience with configuring Gitlab to be highly 
>> available? I'd like to have 2 Gitlab servers behind something like HAproxy 
>> in order to have a seamless failover in place.
>>
>> If this is something more people are interested in I'd be happy to share 
>> my findings here if I have to set it up from scratch. 
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"GitLab" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to gitlabhq+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/gitlabhq/30fab2c3-21e1-4c5b-8dbf-d042fde878af%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to