有没有办法在没有pg_dump的情况下迁移postgresql db?

时间:2018-05-11 07:17:48

标签: linux postgresql crash database-backups

原来的postgres服务器是在ubuntu上运行的,但机器崩溃了,无法启动。

我尝试在安装了postgres的Ubuntu live上挂载磁盘,然后将data_directory更改为我挂载的oringinal data_directoty的路径,但是失败了。 运行systemctl start postgresql时没有错误消息,但是当我尝试使用psql登录时,显示

psql: could not connect to server: No such file or directory
    Is the server running locally and accepting
    connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"?

似乎服务器未启用。我该如何解决?

或者有没有其他方法可以在不启动原始计算机的情况下获取数据库?

0 个答案:

没有答案
相关问题