# useradd postgres # passwd postgres
$ pg_dumpall -z > db.out
# ps -aux | grep postmaster # kill PID (À§¿¡¼ ãÀº pid ¹øÈ£)
# mv postgresql-6.5.3 pgsql (À̸§À» pgsql·Î ¹Ù²Û´Ù) # chown -R postgres.postgres pgsql (user¿Í groupÀ» ¹Ù²Û´Ù) # cd /usr/local/pgsql/src # vi Makefile.custom (Pentitum pro±Þ À̻󿡼 ÃÖÀûȸ¦ CFLAG+= -m486 À§ÇØ »ý¼ºÇÑ´Ù) # ./configure --with-mb=EUC_KR (ÇÑ±Û »ç¿ëÀ» À§ÇØ) # cd /usr/local/pgsql/doc # make install (¸Ç ÆäÀÌÁö, HTML ¹®¼ÆÄÀÏ ¼³Ä¡) # cd /usr/local/pgsql/src # make all (ÄÄÆÄÀÏ)
# su postgres (postgres °èÁ¤À¸·Î ÀÛ¾÷ÇϱâÀ§ÇØ) $ make install (¼³Ä¡)
# vi /etc/ld.so.conf /usr/local/pgsql/lib # /sbin/ldconfig
°¢ °³ÀÎÀÇ È¯°æº¯¼ö¸¦ ¼³Á¤ÇϱâÀ§ÇØ °³ÀÎÀÇ .bash_profile¿¡ ´ÙÀ½À» Ãß°¡ÇÑ´Ù. (DB¸¦ »ç¿ëÇÒ °èÁ¤ÀÇ È¯°æº¯¼ö¸¦ ¼³Á¤ - postgres °èÁ¤¿¡µµ Àû¿ë½ÃŲ´Ù.) PATH=$PATH:/usr/local/pgsql/bin MANPATH=$MANPATH:/usr/local/pgsql/man PGLIB=/usr/local/pgsql/lib PGDATA=/usr/local/pgsql/data export PATH MANPATH PGLIB PGDATA
°¢ °èÁ¤¿¡¼ ½ÇÇàÇؼ ȯ°æº¯¼ö¸¦ Àû¿ë½ÃŲ´Ù. $ source .bash_profile
postgres°èÁ¤À¸·Î ÀÛ¾÷ÇؾßÇÑ´Ù. $ initdb -e EUC_KR
$ postmaster -i -S -D /usr/local/pgsql/data
$ psql -e template1 < db.out