【发布时间】:2017-05-03 03:08:54
【问题描述】:
我有一个用于填充数据库的 ec2 实例。我有一个 python 脚本,我通过输入:
nohup python populate_db.py &。这有效,数据库开始填充。但是,如果我离开 ssh 会话,然后在运行时尝试重新加入,我会在添加 vvv 标志时得到以下输出:
OpenSSH_7.4p1, OpenSSL 1.0.2k 26 Jan 2017
debug1: Reading configuration data /home/me/.ssh/config
debug1: Reading configuration data /etc/ssh/ssh_config
debug2: resolving "ec2-xx-xxx-xxx-x.compute-1.amazonaws.com" port 22
debug2: ssh_connect_direct: needpriv 0
debug1: Connecting to ec2-xx-xxx-xxx-x.compute-1.amazonaws.com
[xx.xxx.xxx.x] port 22.
debug1: Connection established.
debug1: key_load_public: No such file or directory
debug1: identity file .ssh/ec2key.pem type -1
debug1: key_load_public: No such file or directory
debug1: identity file .ssh/ec2key.pem-cert type -1
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_7.4
ssh_exchange_identification: read: Connection reset by peer
此外,我的 cloudwatch 日志似乎停止记录,并且 CPU 使用率在飙升到最高 80% 后下降到 6% 左右,所以感觉好像有什么东西可能要崩溃了。
有没有办法找出问题所在/解决这个问题?
【问题讨论】:
-
尝试使用
screen而不是nohup。
标签: amazon-web-services ssh amazon-ec2