[系統] Postgresql 手動搬移 Tablespace?

作者: wangks (歐巴桑的歐巴)   2014-04-30 16:47:35
資料庫名稱: Postgresql
資料庫版本: 9.X
作業平台: MS Windows Server 2008
問題描述:
資料庫變太大
想買新的硬碟直接加上去
但舊的硬碟還想留著(因為上面有別的系統在用)
想說既然預設的DATA File都可以指定不同的路徑下起動
應該有什麼方式可以把舊硬碟的檔案直接搬到新硬碟
只是重新指定這個Tablespace的location就好了
DB Shutdown

Move Tablespace's Files

Change Control File ←←← 這個怎麼做?

DB Startup
謝謝
作者: JuliaTsai (Julia)   2014-05-02 20:29:00
網路上文章少有環境是Windows的,In /etc/init.d/postgresql file,change the value of PGDATA variable to new可以試試看,修改前先備份,有備份有保庇
作者: wangks (歐巴桑的歐巴)   2014-05-06 10:07:00
data\global 下,有個檔案: pg_internal.init 是 binary 檔

Links booklink

Contact Us: admin [ a t ] ucptt.com