1.gitlab升级

# 查看当前版本
head -1 /opt/gitlab/version-manifest.txt
gitlab-ce 8.9.5
grep "^external_url" /etc/gitlab/gitlab.rb
external_url 'http://10.0.0.26'
wget https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7/gitlab-ce-10.0.4-ce.0.el7.x86_64.rpm # 关闭部分gitlab服务
gitlab-ctl stop unicorn
gitlab-ctl stop sidekiq
gitlab-ctl stop nginx
rpm -Uvh gitlab-ce-10.0.4-ce.0.el7.x86_64.rpm

报错,10.x以后开始依赖policycoreutils-python,之前在使用9.x时还没有依赖该项

policycoreutils-python is needed by gitlab-ce-10.0.4-ce.0.el7.x86_64
yum -y install policycoreutils-python rpm -Uvh gitlab-ce-10.0.4-ce.0.el7.x86_64.rpm
gitlab preinstall: Your version of PostgreSQL is no longer supported.
Please upgrade your PostgreSQL version

信息选自GIitLab官网:

从版本10.0开始,GitLab要求PostgreSQL的版本为9.6或更高;对于运行8.15以下版本的用户,这意味着他们必须首先升级到9.5,其中PostgreSQL将自动更新为9.6.

对于运行8.15以下版本的用户,这意味着他们必须首先升级到9.5,其中PostgreSQL将自动更新为9.6.
wget https://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el7/gitlab-ce-9.5.9-ce.0.el7.x86_64.rpm
rpm -Uvh gitlab-ce-9.5.9-ce.0.el7.x86_64.rpm gitlab-ctl reconfigure
gitlab-ctl restart
gitlab-ctl stop unicorn
gitlab-ctl stop sidekiq
gitlab-ctl stop nginx
# 注意:不能把服务全部关闭,尤其是pgsql,gitlab要去备份数据,得连上数据库,除非你跳过备份
touch /etc/gitlab/skip-auto-migration # 接下来就可以开始正式安装了
rpm -Uvh gitlab-ce-10.0.4-ce.0.el7.x86_64.rpm
gitlab-ctl reconfigure
gitlab-ctl restart # 等待30s访问网页

2.汉化

想下载老版本的汉化包,用这条命令:

git clone https://gitlab.com/xhang/gitlab.git -b v10.0.2-zh

# 克隆获取汉化版本库
git clone https://gitlab.com/xhang/gitlab.git
cat gitlab/VERSION # 但我的gitlab版本是10.0.4
11.5.7
gitlab-ctl stop
cd /root/gitlab
git diff v10.0.4 v10.0.4-zh > ../10.0.4-zh.diff
yum -y install patch
patch -d /opt/gitlab/embedded/service/gitlab-rails -p1 < 10.0.4-zh.diff
gitlab-ctl start # 想第二次汉化时,比如生成了一个10.0.6-zh.diff,导入时会各种报错

界面:

3.忘记root密码

gitlab-rails console production
user = User.where(id: 1).first
user.password='yourpassword' # 密码必须至少8个字符
user.save! # 修改成功会返回true
quit # 目前root密码是root-root123456789

关联LDAP可以去这个-大牙啊:http://blog.51cto.com/13520772/2133739

关联LDAP-粽先生:https://www.cnblogs.com/straycats/p/7487780.html#top

升级参考博文:https://www.ilanni.com/?p=13917

gitlab升级-粽先生:https://www.cnblogs.com/straycats/p/7707359.html

gitlab升级、汉化、修改root密码的更多相关文章

  1. centos7安装gitlab并汉化

    一.基础环境准备 1.安装依赖包 [root@gitlab-server ~]#yum install curl policycoreutils openssh-server openssh-clie ...

  2. CentOS7安装GitLab、汉化及使用

    同步首发:http://www.yuanrengu.com/index.php/20171112.html 一.GitLab简介 GitLab是利用Ruby On Rails开发的一个开源版本管理系统 ...

  3. CentOS7安装GitLab、汉化、邮箱配置及使用

    同步首发:http://www.yuanrengu.com/index.php/20171112.html 一.GitLab简介 GitLab是利用Ruby On Rails开发的一个开源版本管理系统 ...

  4. CentOS7安装GitLab、汉化、邮箱配置及使用(转载)

    同步首发: https://www.cnblogs.com/heyonggang/p/7778203.html http://www.yuanrengu.com/index.php/20171112. ...

  5. centos安装gitlab及汉化

    GitLab 是一个用于仓库管理系统的开源项目,使用Git作为代码管理工具,并在此基础上搭建起来的web服务.今天,就记录一下centos部署gitlab及其汉化的操作方法. 1.下载安装 下载地址: ...

  6. mysql8数据库修改root密码,以及创建用户遇到的坑,开启远程登录,用navicat进行mysql的远程连接,mysql8.0默认编码方式,部分参数配置查询命令

    yum 安装MySQL8 echo "删除系统默认或之前可能安装的其他版本的 mysql" for i in $(rpm -qa|grep mysql);do rpm -e $i ...

  7. RedHat/Centos修改root密码

    Linux主机忘记密码,只要你能接触物理主机都可以修改root密码的!   Redhat6.x 5.x  / Centos6.x  5.x 01.开机-空格/enter 02.e-编辑模式 CentO ...

  8. ansible非root用户批量修改root密码

    前言: 由于线上服务器密码长久没有更新,现领导要求批量更换密码.线上的之前部署过salt,但由于各种因素没有正常使用. 使用自动化工具批量修改的计划搁浅了,后来领导给了个python多线程修改密码脚本 ...

  9. phpmyadmin修改root密码

    很多人利用phpmyadmin或者命令行来修改了mysql的root密码,重启 后发现mysql登录错误,这是为什么呢?修改mysql的root的密码要在mysql软件中mysql数据库里修改root ...

  10. mysql修改root密码和设置权限

    整理了以下四种在MySQL中修改root密码的方法,可能对大家有所帮助! 方法1: 用SET PASSWORD命令 mysql -u root mysql> SET PASSWORD FOR ' ...

随机推荐

  1. 中移物联网onenet入门学习笔记2:中移物联的通信格式

    中移物联网硬件接入协议:LWM2M协议,EDP协议,MQTT协议,HTTP协议,TCP透传,MODBUS协议,JT/T808协议,RCMP协议 8种通信协议的区别在哪? 详细比较 EDP:OneNET ...

  2. Leetcode(204) Count Primes

    题目 Description: Count the number of prime numbers less than a non-negative number, n. Credits: Speci ...

  3. LeetCode(189) Rotate Array

    题目 Rotate an array of n elements to the right by k steps. For example, with n = 7 and k = 3, the arr ...

  4. NHibernate N+1问题实例分析和优化

    1.问题的缘起 考察下面的类结构定义 public class Category { string _id; Category _parent; IList<Category> _chil ...

  5. RF操作滚动条(竖拉)

    方式一:window.scrollBy(0, document.body.scrollHeight) 方式二:window.scrollTo(0, document.body.scrollHeight ...

  6. 03-python进阶-爬虫入门-正则

    [urllib and urllib2] 这是两个python的网络模块 内置的 提供很好的网络访问的功能. #!coding:utf-8 import urllib2 res = urllib2.u ...

  7. CF878D D. Magic Breeding bitset

    D. Magic Breeding time limit per test 4 seconds memory limit per test 1024 megabytes input standard ...

  8. JSP内置对象的cookie和session实现简单登录界面

    创建一个index.jsp页面 <%@ page language="java" contentType="text/html; charset=utf-8&quo ...

  9. MacPorts的安装和使用

    1.安装 MacPorts的官方网站:http://www.macports.org/install.php 有dmg安装和源代码安装两种方式,下载dmg格式一步步安装即可 2.使用 更新ports ...

  10. 【bzoj2843】极地旅行社 LCT

    题目描述 不久之前,Mirko建立了一个旅行社,名叫“极地之梦”.这家旅行社在北极附近购买了N座冰岛,并且提供观光服务.当地最受欢迎的当然是帝企鹅了,这些小家伙经常成群结队的游走在各个冰岛之间.Mir ...