Bind 9.8.1-P1에서 pgsql 이나 mysql 드라이버와 함께 컴파일할 때
dlz_mysql_driver.o: In function `mysql_get_resultset':
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:279: 
undefined reference to `sdlzh_build_querystring'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:282: 
undefined reference to `sdlzh_build_querystring'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:285: 
undefined reference to `sdlzh_build_querystring'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:288: 
undefined reference to `sdlzh_build_querystring'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:291: 
undefined reference to `sdlzh_build_querystring'
dlz_mysql_driver.o:/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:294: 
more undefined references to `sdlzh_build_querystring' follow
dlz_mysql_driver.o: In function `mysql_create':
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:823: 
undefined reference to `sdlzh_get_parameter_value'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:833: 
undefined reference to `sdlzh_get_parameter_value'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:857: 
undefined reference to `sdlzh_build_sqldbinstance'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:902: 
undefined reference to `sdlzh_get_parameter_value'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:909: 
undefined reference to `sdlzh_get_parameter_value'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:916: 
undefined reference to `sdlzh_get_parameter_value'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:924: 
undefined reference to `sdlzh_get_parameter_value'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:925: 
undefined reference to `sdlzh_get_parameter_value'
dlz_mysql_driver.o:/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:926: 
more undefined references to `sdlzh_get_parameter_value' follow
dlz_mysql_driver.o: In function `mysql_create':
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:963: 
undefined reference to `sdlzh_destroy_sqldbinstance'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:861: 
undefined reference to `sdlzh_build_sqldbinstance'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:865: 
undefined reference to `sdlzh_build_sqldbinstance'
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:870: 
undefined reference to `sdlzh_build_sqldbinstance'
dlz_mysql_driver.o: In function `mysql_destroy':
/root/bind-9.8.1/bin/named/../../contrib/dlz/drivers/dlz_mysql_driver.c:1003: 
undefined reference to `sdlzh_destroy_sqldbinstance'
collect2: ld returned 1 exit status
make[2]: *** [named] Error 1
make[2]: Leaving directory `/root/bind-9.8.1/bin/named'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/root/bind-9.8.1/bin'
make: *** [subdirs] Error 1

이런 에러가 뜨면

diff -u -r1.3 sdlz_helper.c
--- contrib/dlz/drivers/sdlz_helper.c	14 May 2010 06:29:37 -0000	1.3
+++ contrib/dlz/drivers/sdlz_helper.c	5 Sep 2011 17:31:30 -0000
@@ -50,8 +50,6 @@
  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
-#ifdef DLZ
-
 #include <config.h>
 
 #include <dns/log.h>
@@ -527,5 +525,3 @@
 
 	return isc_mem_strdup(mctx, value);
 }
-
-#endif

이 패치를 적용해 주면 된다

9.8.2 때 패치가 적용되서 나온다는 듯..

댓글을 달아 주세요

PostgreSQL 설치

리눅스/Database 2010. 6. 13. 19:02 Posted by Relipmoc
원래 bind (named) 랑 연동할려고 컴파일 해서 올린거지만 결국 실패했... 쓸데없이 시간 날린것 같네요 -_-;
실패라기 보다는 포기지만요 (성공하신분 계시면 트랙뷁이나 댓글좀요 (...))

아무튼 각 배포판에서 패키지로 설치할 수 있지만, (apt-get emerge yum ports etc..)
그냥 컴파일 및 설정하는 방법을 포스팅하도록 하겠습니다.

먼저 http://www.postgresql.org/ 에서 소스를 받고 다음 명령어들을 입력 하시면 됩니다.
(셜명은 안해도 왠만한건 다 명령어 이름보고 아실거라 믿습니다)

# tar xvf postgresql*
# cd postgresql-*
# ./configure --prefix=/usr/local/pgsql --with-ldap --with-libxml  --with-openssl
# make && make install
# cd /usr/local/pgsql
# useradd -s /bin/bash -d /usr/local/pgsql postgres # pgsql 은 root 로 뭘 할려그러면 오류를 뱉기 때문에 유저생성
# passwd postgres
# chown -R postgres.postgres .
# su postgres
$ bin/initdb -D data
$ bin/pg_ctl -D data -l data/postmaster.log start
$ bin/psql template1
psql (9.0beta2)
Type "help" for help.
template1=# alter user postgres with password 'password';
template1=# \q
$ data/pg_hba.conf  ## 여기서 제일 마지막에 있는 trust 를 password 로 바꾸고 저장한다.
$ bin/pg_ctl -D data restart
$ bin/createuser
Enter name of role to add: relip
Shall the new role be a superuser? (y/n) n
Shall the new role be allowed to create databases? (y/n) n
Shall the new role be allowed to create more new roles? (y/n) n
Password:
$ ./createdb -U relip relip
Password:
$ ./psql
Password:
psql (9.0beta2)
Type "help" for help.
postgres=# ALTER USER relip with password 'password';
ALTER ROLE
postgres=# \q
$

명령어만 쭉 나열했지만 아무튼 이걸로 기본적인 설치 및 설정이 끝났습니다. (...)
(TCP 로 접속하는 설정은 다른문서 찾으면 나오니 그거 보시고 하시면 됩니다.)









참 쉽죠?

* MySQL 에는 phpmyadmin 이 있듯이 pgSQL 에는 phppgadmin 이 있습니다. 설치방법은 쉬우니 그냥 생략 (받아서 압축풀기)

'리눅스 > Database' 카테고리의 다른 글

PostgreSQL 설치  (3) 2010.06.13

댓글을 달아 주세요

  1. 🌸𝓝𝓸𝓮𝓵🍒  2010.06.14 17:39 신고  댓글주소  수정/삭제  댓글쓰기

    그리고 rm -rf /usr/local/pgsql 하시면 설치가 최종적으로 완료됩미다.

  2. 0x8606 2010.07.10 15:31  댓글주소  수정/삭제  댓글쓰기

    전설의 Post그래SQL!!
    마이SQL이랑 퍼포먼스 비교한 벤치좀요

  3. Relipmoc 2010.07.18 00:15 신고  댓글주소  수정/삭제  댓글쓰기

    원래는 직접 BMT해보고 싶었는데 그걸 할만할 마땅한 서버가 없네요 -_-
    구글링하면 많이 나올듯