zoukankan      html  css  js  c++  java
  • gitlab 创建SSH Keys 报500错

    gitlab 创建SSH Keys 报500错 看了一下日志 root@322323:/home/git/gitlab/log# cat production.log

    Errno::ENOMEM (Cannot allocate memory - ssh):
      lib/gitlab/popen.rb:23:in `popen'
      lib/gitlab/key_fingerprint.rb:42:in `explicit_fingerprint_algorithm?'
      lib/gitlab/key_fingerprint.rb:21:in `block in fingerprint'
      lib/gitlab/key_fingerprint.rb:15:in `fingerprint'
      app/models/key.rb:77:in `generate_fingerprint'
      app/controllers/profiles/keys_controller.rb:21:in `create'
      lib/gitlab/middleware/go.rb:16:in `call'

    google 了一翻:http://stackoverflow.com/questions/26777690/gitlab-500-error-when-adding-removing-ssh-key

    root@904eb945eb34:/home/git/gitlab/log# free -h
                 total       used       free     shared    buffers     cached
    Mem:          1.8G       1.7G        66M        14M       1.7M       169M
    -/+ buffers/cache:       1.6G       237M
    Swap:           0B         0B         0B
    [root@iZ23arpt7f0Z data]# mkdir /swapfile
    [root@iZ23arpt7f0Z data]# cd /swapfile
    [root@iZ23arpt7f0Z swapfile]# dd if=/dev/zero of=swap bs=1024 count=2000000
    2000000+0 records in
    2000000+0 records out
    2048000000 bytes (2.0 GB) copied, 36.5222 s, 56.1 MB/s
    [root@iZ23arpt7f0Z swapfile]# mkswap -f  swap
    Setting up swapspace version 1, size = 1999996 KiB
    no label, UUID=fd976699-b7e4-471f-82fb-8d784793d82f
    [root@iZ23arpt7f0Z swapfile]# swapon swap
    swapon: /swapfile/swap: insecure permissions 0644, 0600 suggested.
    [root@iZ23arpt7f0Z swapfile]# free -h
                  total        used        free      shared  buff/cache   available
    Mem:           1.8G        1.5G         62M         14M        263M        159M
    Swap:          1.9G          0B        1.9G

    这下就ok了

  • 相关阅读:
    SQL语句优化(转)
    ConcurrentHashMap源码分析
    centos 上安装gearman
    从与UCenter集成的过程中,看到Discuz的不开放
    UCenter实现同步登陆
    讨人喜欢的 MySQL replace into 用法(insert into 的增强版)
    Truncate Table
    mysql中key 、primary key 、unique key 与index区别
    PHP登录时限
    用Fragment实现如新浪微博一样的底部菜单的切换
  • 原文地址:https://www.cnblogs.com/jackluo/p/5670129.html
Copyright © 2011-2022 走看看