简体   繁体   English

保持OrientDB服务器在AWS EC2上运行

[英]Keep OrientDB server running on AWS EC2

I recently downloaded and managed to start an OrientDB server/database on an AWS EC2 Linux 14.04 (I think the name is) server for an application I want to set up. 我最近下载并设法在我要设置的应用程序的AWS EC2 Linux 14.04(我认为是)服务器上启动OrientDB服务器/数据库。 I started OrientDB "as usual" by running ./server.sh in the terminal via SSH link to the EC2 server. 我通过与EC2服务器的SSH链接在终端中运行./server.sh来“照常”启动OrientDB。 All works fine and I can query the database while at the computer. 一切正常,我可以在计算机上查询数据库。 But as soon as I leave my computer and the SSH link is broken (for example when closing the computer), so is the database, ie it stops. 但是,一旦我离开计算机并且SSH链接断开(例如,关闭计算机时),数据库也将断开,即数据库停止。

Is there a way to go around this or do I have to set up the database in some other way? 有没有办法解决这个问题,还是必须以其他方式设置数据库?

OrientDB is provided as AWS AMI. OrientDB是作为AWS AMI提供的。 Take a look to 看看

http://orientdb.com/orientdb-amazon-web-services/ http://orientdb.com/orientdb-amazon-web-services/

If you want to DIY, follow the instructions provided on 如果您想自己动手做,请按照

http://orientdb.com/docs/last/Unix-Service.html http://orientdb.com/docs/last/Unix-Service.html

Update: new link to doc: 更新:doc的新链接:

https://orientdb.com/docs/last/admin/Unix-Service.html https://orientdb.com/docs/last/admin/Unix-Service.html

Hope this helps 希望这可以帮助

您可以尝试在退出0之前将server.sh的完整路径放入/etc/rc.local并重新启动实例

Before running the server, run the command: 在运行服务器之前,请运行以下命令:

screen 屏幕

This will create a persistent environment which will allow your process to keep running after you disconnect. 这将创建一个持久的环境,使您的进程在断开连接后继续运行。

When you reconnect, you can use this command to reconnect to that environment: 重新连接时,可以使用以下命令重新连接到该环境:

screen -r 屏幕-r

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM