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了

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值