当前位置:Gxlcms > 数据库问题 > Postgresql 数据库迁移步骤

Postgresql 数据库迁移步骤

时间:2021-07-01 10:21:17 帮助过:392人阅读

 

1.操作位置:迁移数据库源(旧数据库主机)

找到PostgreSql 的data目录   关闭数据库进程

打包 tar -zcvf pgdatabak.tar.gz data/

------------------------------------------------------------------

2.通过winScp 或者 CRT 等工具拷贝到    迁移目标源(新主机--需安装postgresql)  同样的data目录 关闭数据库进程

解压  tar -zxvf pgdatabak.tar.gz -C /usr/local/postgres/

重新授权 执行命令  chown -R postgres.postgres data/

Postgresql 数据库迁移步骤

标签:gre   --   操作   步骤   postgres   目录   postgre   命令   cal   

人气教程排行