logo logo

 Back to main page

The NWNX Community Forum

 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
[SOLVED] ODBC error after running nwnstartup.sh

 
Post new topic   Reply to topic    nwnx.org Forum Index -> Linux technical support
View previous topic :: View next topic  
Author Message
David



Joined: 30 Mar 2005
Posts: 12
Location: Netherlands

PostPosted: Thu Feb 06, 2014 19:48    Post subject: [SOLVED] ODBC error after running nwnstartup.sh Reply with quote

I've been trying to install a dedicated nwn server on Ubuntu 12.04 LTS 32-bits and ran against an issue I cannot solve myself. After I run nwnstartup.sh, I encounter the following error:

Code:

snowfall@snowfall:~/nwn$ ./nwnstartup.sh

NWNX2lib: Init
NWNX2lib: org SetString() at 81f41b4, new SetString() at b773c37d
NWNX2lib: org GetObj() at 81f40bc, new GetObj() at b773c3a4
* Parsing configuration...
NWN Extender v2.8-dev
(c) 2004 by the APS/NWNX Linux Conversion Group
(c) 2007-2010 by virusman and Acaos
Based on the Win32 version (c) 2003 by Ingmar Stieger (Papillon)
and Jeroen Broekhuizen
visit us at http://www.avlis.org

* Searching for signatures...
* Loading modules...
CHAT plugin registered.
ODMBC_MYSQL plugin registered.
ERROR: dlopen: ./nwnx_odbc.so: libstdc++.so.5: cannot open shared object file: No such file or directory
* NWNX2 activated.
Neverwinter Nights Server
Build:8109
Copyright BioWare Corp 1998-2004

Server: Loading...
Server: Running...

Server: Loading module "deathlands7"................
Server: Module loaded
INIT(S): valid ret=0x082041ec


I did my searching, of course, but only found topics touching mine from people that run a 64-bit environment.

Here's a list of my nwn directory with set rights:
Code:

snowfall@snowfall:~/nwn$ ls -l
total 23224
-rwxr-xr-x  1 snowfall snowfall   966016 Jun  6  2002 chitin.key
drwxr-xr-x  2 snowfall snowfall     4096 Jul  7  2008 data
drwxr-xr-x  2 snowfall snowfall     4096 Jul  7  2008 database
-rwxr-xr-x  1 snowfall snowfall 12764158 Apr 25  2008 dialog.tlk
drwxr-xr-x  2 snowfall snowfall     4096 Jul  7  2008 dmvault
drwxr-xr-x  2 snowfall snowfall     4096 Jul  7  2008 docs
drwxr-xr-x  2 snowfall snowfall     4096 Jul  7  2008 erf
-rwxr-xr-x  1 snowfall snowfall     2345 Oct  1  2004 fixinstall
drwxr-xr-x  2 snowfall snowfall     4096 Jul  7  2008 hak
-rwxr-xr-x  1 snowfall snowfall  1801454 Jul  4  2008 linuxdedserver169.tar.gz
drwxr-xr-x  2 snowfall snowfall     4096 Jul  7  2008 localvault
drwxr-xr-x  2 snowfall snowfall     4096 Jul  7  2008 logs
drwxr-xr-x  2 snowfall snowfall     4096 Feb  6 18:04 logs.0
drwxr-xr-x  2 snowfall snowfall     4096 Feb  6 18:07 modules
drwxr-xr-x  2 snowfall snowfall     4096 Feb  6 16:46 nwm
-rwxr-xr-x  1 snowfall snowfall      381 Feb  6 18:04 nwn.ini
-rwxr-xr-x  1 snowfall snowfall      381 Jun 18  2003 nwn.ini~
-rwxr-xr-x  1 snowfall snowfall     1124 Feb  6 18:45 nwnplayer.ini
-rwxr-xr-x  1 snowfall snowfall      376 Feb  6 18:08 nwnstartup.sh
-rwxr-xr-x  1 snowfall snowfall      372 Feb  6 17:58 nwnstartup.sh~
drwxr-xr-x 14 snowfall snowfall     4096 Feb  6 15:36 nwnx
-rwxr-xr-x  1 snowfall snowfall     2004 Feb  6 16:56 nwnx2.ini
-rwxr-xr-x  1 snowfall snowfall     2004 Feb  6 16:27 nwnx2.ini~
-rwxr-xr-x  1 snowfall snowfall   700480 Feb  5 22:25 nwnx2.so
-rwxr-xr-x  1 snowfall snowfall    53893 Feb  6 15:35 nwnx_chat.so
-rwxrwxr-x  1 snowfall snowfall  1310202 Feb  5 23:44 nwnx_odbc.so
-rwxr-xr-x  1 snowfall snowfall    67067 Feb  6 15:54 nwnx_odmbc_mysql.so
-rwxr-xr-x  1 snowfall snowfall  4464553 Jul  3  2008 nwserver
drwxr-xr-x  2 snowfall snowfall     4096 Jul  7  2008 override
-rwxr-xr-x  1 snowfall snowfall   197120 Feb 27  2002 Patchw32.dll
drwxr-xr-x  2 snowfall snowfall     4096 Jul  7  2008 portraits
-rwxr-xr-x  1 snowfall snowfall     8234 Dec 16  2003 readme.linuxserver.txt
drwxr-xr-x  2 snowfall snowfall     4096 Jul  7  2008 saves
drwxr-xr-x  3 snowfall snowfall     4096 Feb  6 18:10 servervault
drwxr-xr-x  2 snowfall snowfall     4096 Jul  7  2008 temp
drwxr-xr-x  3 snowfall snowfall     4096 Jul  7  2008 utils
-rwxr-xr-x  1 snowfall snowfall   319748 May 27  2003 xp1.key
-rwxr-xr-x  1 snowfall snowfall   565004 Nov 11  2003 xp2.key
-rwxr-xr-x  1 snowfall snowfall   148110 May 15  2008 xp2patch.key
-rwxr-xr-x  1 snowfall snowfall   276827 May 15  2008 xp3.key


I'm honestly clueless as what to do next and would welcome any suggestion from the community. Thank you in advance.


Last edited by David on Thu Feb 06, 2014 22:30; edited 1 time in total
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
eeriegeek



Joined: 07 Jan 2008
Posts: 59

PostPosted: Thu Feb 06, 2014 20:17    Post subject: Reply with quote

Hey,

Run the command "locate libstdc++.so" on your system and show the output. Have you build your own NWNX or downloaded a pre-built one? I suspect you have a pre-built one that may be built against an older version of the C++ library that doesn't exist on your system. If so, you will likely need to build your own NWNX (not too hard) or find someone who has already built one for ubuntu 12.

Update: see this: http://nwnx.org/phpBB2/viewtopic.php?t=2152 Smile
Back to top
View user's profile Send private message
David



Joined: 30 Mar 2005
Posts: 12
Location: Netherlands

PostPosted: Thu Feb 06, 2014 21:03    Post subject: Reply with quote

I was just taking a look at that topic, eeriegeek. During my first attempt at installing nwnx, I used this guide: http://www.nwnx.org/index.php?id=doc_nwnx_linux. The one made by Squatting Monk, the one you linked, did a better job in my opinion. When I run nwnstartup.sh now, I get the following output:

Code:

snowfall@snowfall:~/nwn$ ./nwnstartup.sh

NWNX2lib: Init
NWNX2lib: org SetString() at 81f41b4, new SetString() at b76dc36d
NWNX2lib: org GetObj() at 81f40bc, new GetObj() at b76dc394
* Parsing configuration...
NWN Extender v2.8-dev
(c) 2004 by the APS/NWNX Linux Conversion Group
(c) 2007-2010 by virusman and Acaos
Based on the Win32 version (c) 2003 by Ingmar Stieger (Papillon)
and Jeroen Broekhuizen   
visit us at http://www.avlis.org

* Searching for signatures...
* Loading modules...
EVENTS plugin registered.
VISIBILITY plugin registered.
NAMES plugin registered.
FUNCS plugin registered.
TMI plugin registered.   
CHAT plugin registered. 
FUNCSEXT plugin registered.
SYSTEM plugin registered.
RESMAN plugin registered.
FUNCTIONS plugin registered.
HASHSET plugin registered.
RESET plugin registered.
AREAS plugin registered.
PROFILER plugin registered.
WEAPONS plugin registered.
ODMBC_MYSQL plugin registered.
FIXES plugin registered.
STRUCTS plugin registered.
SPELLS plugin registered.
EXTEND plugin registered.
DMACTIONS plugin registered.
ERROR: ODBC: OnCreate() failed.
TWEAKS plugin registered.
DEFENSES plugin registered.
MNX plugin registered.   
* NWNX2 activated.
Neverwinter Nights Server
Build:8109
Copyright BioWare Corp 1998-2004

Server: Loading...
Server: Running...

Server: Loading module "deathlands7".........
Server: Module loaded
INIT(S): valid ret=0x082041ec
* Library ODBC!SPACER does not exist.
* Library ODBC!EXEC does not exist.


Something is still not right. I am not getting an 'OnCreate() failed' error.

Ouput 'locate libstdc++.so':
Code:

snowfall@snowfall:~/nwn$ locate libstdc++.so
/usr/lib/gcc/i686-linux-gnu/4.6/libstdc++.so
/usr/lib/i386-linux-gnu/libstdc++.so.6
/usr/lib/i386-linux-gnu/libstdc++.so.6.0.16
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
David



Joined: 30 Mar 2005
Posts: 12
Location: Netherlands

PostPosted: Thu Feb 06, 2014 21:27    Post subject: Reply with quote

I disabled nwnx_odmbc_mysql.so, a module that came with compiling nwnx and installed, instead, nwnx_odbc.so. This module didn't come on its own after compiling; I had to get it myself from http://www.nwnx.org/index.php?id=nwnx2. This got rid of the 'OnCreate() failed' error. Persistent variables aren't stored in the database yet, though. So there must be something else I'm not doing right. I'll keep working on it and will post whatever I find out in this topic.

Update: I tried installing the pwdata table while inside the aps_demo.mod. It said it'd worked, but after logging in on the database the table wasn't there. The nwnx_odbc.txt logging looks as follow:
Code:

NWNX2 ODBC2 version 1.0.1 for Linux.
(c) 2005-2006 dumbo (dumbo@nm.ru)
(c) 2006-2010 virusman (virusman@virusman.ru)
MySQL engine is supported
Plugin link: B77964C0
Plugin link: B77964C0
o SCO located at 82d9c44.
o RCO located at 82d9b60.
o Connect successful.
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
David



Joined: 30 Mar 2005
Posts: 12
Location: Netherlands

PostPosted: Thu Feb 06, 2014 22:30    Post subject: [SOLVED] ODBC error after running nwnstartup.sh Reply with quote

Alright, I got everything working:
1) I installed nwnx with mysql through this guide: http://nwnx.org/phpBB2/viewtopic.php?t=2152;
2) I changed localhost in nwnstartup.sh to 127.0.0.1;
3) I removed the nwnx_odmbc_mysql.so module and replaced it with nwnx_odbc.so, which I got here: http://www.nwnx.org/index.php?id=doc_nwnx_linux;
4) I did not use aps_demo to create the pwdata table, but did so myself!

Good luck folks, I'll continue working on my server now.
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
eeriegeek



Joined: 07 Jan 2008
Posts: 59

PostPosted: Fri Feb 07, 2014 2:54    Post subject: Reply with quote

This confuses lots of people including me the first time around.

What you want to do is _rename_ the new shared library file that you just built (nwnx_odmbc_mysql.so) to (nwnx_odbc.so). Under linux it's should just be:

Code:
mv nwnx_odmbc_mysql.so nwnx_odbc.so


The reason for this is that NWNX expects the active database adapter to be named nwnx_odbc.so, but in order to build multiple potential adaptors the build system gives them alternate names. You may also find you have a nwnx_odmbc_sqlite.so as well for instance. If you wanted to use sqlite instead of mysql, you would rename nwnx_odmbc_sqlite.so to nwnx_odbc.so replacing your current one. If you're a unix wiz, you can also use hard or symbolic links to make the nwnx_odbc.so file name point to the correct database adaptor shared library.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    nwnx.org Forum Index -> Linux technical support All times are GMT + 2 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group