Обсуждение: Runing DBT2 on Postgresql

Поиск
Список
Период
Сортировка

Runing DBT2 on Postgresql

От
Rohit Goyal
Дата:
Hi All, 

I am trying to install dbt2 on postgresql database.

cmake(configure) command work fine and but make command(build) give an error given below. I have no idea about how to solve it

I have set 
 export LD_LIBRARY_PATH=home/abhi/project/lib:$LD_LIBRARY_PATH
dbt2pgdata = /home/abhi/project/pgsql/DemoDir/
export PATH=$HOME/project/bin:$PATH

CMakeFiles/bin/dbt2-client.dir/src/client.o: In function `startup':
/home/abhi/project/dbt2/src/client.c:344: undefined reference to `pthread_create'
CMakeFiles/bin/dbt2-client.dir/src/listener.o: In function `init_listener':
/home/abhi/project/dbt2/src/listener.c:94: undefined reference to `pthread_attr_setstacksize'
/home/abhi/project/dbt2/src/listener.c:99: undefined reference to `pthread_create'
CMakeFiles/bin/dbt2-client.dir/src/db_threadpool.o: In function `db_threadpool_init':
/home/abhi/project/dbt2/src/db_threadpool.c:226: undefined reference to `pthread_attr_setstacksize'
/home/abhi/project/dbt2/src/db_threadpool.c:230: undefined reference to `pthread_create'
CMakeFiles/bin/dbt2-client.dir/src/common.o: In function `get_think_time':
/home/abhi/project/dbt2/src/common.c:149: undefined reference to `log'
CMakeFiles/bin/dbt2-client.dir/src/libpq/dbc_common.o: In function `commit_transaction':
/home/abhi/project/dbt2/src/libpq/dbc_common.c:25: undefined reference to `PQexec'
/home/abhi/project/dbt2/src/libpq/dbc_common.c:26: undefined reference to `PQresultStatus'
/home/abhi/project/dbt2/src/libpq/dbc_common.c:27: undefined reference to `PQerrorMessage'
/home/abhi/project/dbt2/src/libpq/dbc_common.c:29: undefined reference to `PQclear'
CMakeFiles/bin/dbt2-client.dir/src/libpq/dbc_common.o: In function `_connect_to_db':
/home/abhi/project/dbt2/src/libpq/dbc_common.c:44: undefined reference to `PQconnectdb'
/home/abhi/project/dbt2/src/libpq/dbc_common.c:45: undefined reference to `PQstatus'
/home/abhi/project/dbt2/src/libpq/dbc_common.c:48: undefined reference to `PQerrorMessage'
/home/abhi/project/dbt2/src/libpq/dbc_common.c:49: undefined reference to `PQfinish'
CMakeFiles/bin/dbt2-client.dir/src/libpq/dbc_common.o: In function `_disconnect_from_db':
/home/abhi/project/dbt2/src/libpq/dbc_common.c:58: undefined reference to `PQfinish'

Please guide me through !!

Regards,
Rohit Goyal

Re: Runing DBT2 on Postgresql

От
Peter Geoghegan
Дата:
On Wed, Apr 23, 2014 at 2:33 AM, Rohit Goyal <rhtgyl.87@gmail.com> wrote:
> I am trying to install dbt2 on postgresql database.
>
> cmake(configure) command work fine and but make command(build) give an error
> given below. I have no idea about how to solve it

ld has become less tolerant of certain flag orderings over time in
certain distros. The following tweak may be used as a quick-and-dirty
work around:

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6a128e3..f6a796b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -11,6 +11,7 @@ SET(DBT2_CLIENT bin/dbt2-client)SET(DBT2_DATAGEN bin/dbt2-datagen)SET(DBT2_DRIVER
bin/dbt2-driver)SET(DBT2_TXN_TESTbin/dbt2-transaction-test)
 
+set(CMAKE_EXE_LINKER_FLAGS "-Wl,--no-as-needed")
## Check for large file support by using 'getconf'.


-- 
Peter Geoghegan



Re: Runing DBT2 on Postgresql

От
Rohit Goyal
Дата:
Hi Peter/All, 

Can you please elaborate a bit in details the steps? where are how to run these steps?

Regards,
Rohit Goyal


On Thu, Apr 24, 2014 at 6:57 AM, Peter Geoghegan <pg@heroku.com> wrote:
On Wed, Apr 23, 2014 at 2:33 AM, Rohit Goyal <rhtgyl.87@gmail.com> wrote:
> I am trying to install dbt2 on postgresql database.
>
> cmake(configure) command work fine and but make command(build) give an error
> given below. I have no idea about how to solve it

ld has become less tolerant of certain flag orderings over time in
certain distros. The following tweak may be used as a quick-and-dirty
work around:

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6a128e3..f6a796b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -11,6 +11,7 @@ SET(DBT2_CLIENT bin/dbt2-client)
 SET(DBT2_DATAGEN bin/dbt2-datagen)
 SET(DBT2_DRIVER bin/dbt2-driver)
 SET(DBT2_TXN_TEST bin/dbt2-transaction-test)
+set(CMAKE_EXE_LINKER_FLAGS "-Wl,--no-as-needed")

 #
 # Check for large file support by using 'getconf'.


--
Peter Geoghegan



--
Regards,
Rohit Goyal

Re: Runing DBT2 on Postgresql

От
Rohit Goyal
Дата:
Hi Everyone, 

Sorry, i got this now. :)

Regards,
Rohit Goyal


On Thu, Apr 24, 2014 at 4:24 PM, Rohit Goyal <rhtgyl.87@gmail.com> wrote:
Hi Peter/All, 

Can you please elaborate a bit in details the steps? where are how to run these steps?

Regards,
Rohit Goyal


On Thu, Apr 24, 2014 at 6:57 AM, Peter Geoghegan <pg@heroku.com> wrote:
On Wed, Apr 23, 2014 at 2:33 AM, Rohit Goyal <rhtgyl.87@gmail.com> wrote:
> I am trying to install dbt2 on postgresql database.
>
> cmake(configure) command work fine and but make command(build) give an error
> given below. I have no idea about how to solve it

ld has become less tolerant of certain flag orderings over time in
certain distros. The following tweak may be used as a quick-and-dirty
work around:

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6a128e3..f6a796b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -11,6 +11,7 @@ SET(DBT2_CLIENT bin/dbt2-client)
 SET(DBT2_DATAGEN bin/dbt2-datagen)
 SET(DBT2_DRIVER bin/dbt2-driver)
 SET(DBT2_TXN_TEST bin/dbt2-transaction-test)
+set(CMAKE_EXE_LINKER_FLAGS "-Wl,--no-as-needed")

 #
 # Check for large file support by using 'getconf'.


--
Peter Geoghegan



--
Regards,
Rohit Goyal



--
Regards,
Rohit Goyal

Re: Runing DBT2 on Postgresql

От
Rohit Goyal
Дата:



On Thu, Apr 24, 2014 at 6:57 AM, Peter Geoghegan <pg@heroku.com> wrote:
On Wed, Apr 23, 2014 at 2:33 AM, Rohit Goyal <rhtgyl.87@gmail.com> wrote:
> I am trying to install dbt2 on postgresql database.
>
> cmake(configure) command work fine and but make command(build) give an error
> given below. I have no idea about how to solve it

ld has become less tolerant of certain flag orderings over time in
certain distros. The following tweak may be used as a quick-and-dirty
work around:

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6a128e3..f6a796b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -11,6 +11,7 @@ SET(DBT2_CLIENT bin/dbt2-client)
 SET(DBT2_DATAGEN bin/dbt2-datagen)
 SET(DBT2_DRIVER bin/dbt2-driver)
 SET(DBT2_TXN_TEST bin/dbt2-transaction-test)
+set(CMAKE_EXE_LINKER_FLAGS "-Wl,--no-as-needed")

 #
 # Check for large file support by using 'getconf'.


--
Peter Geoghegan


Hi Peter/All,

I installed the dbt-2 benchmark by implementing the change you mentioned. Now, I am trying to follow the readme_postgresql for running test on postgresql, but facing an error in understanding changes in dbt2_profile.  Can you explain my next step:

Could you tel me what to write in how to 
set environment variables, see examples/dbt2_profile and proceed further. Please help me and give me some link to run the test.

I cant find bin/pgsql/pgsql_profile.in file also and when i tried to "Create a 1 warehouse database by running bin/pgsql/dbt2-pgsql-build-db
and put the data files in '/tmp/data':	dbt2-pgsql-build-db -w 1"
I got the error that dbt2-pgsql-build-db not found.

Please guide!!
--
 
Regards,
Rohit Goyal