DBD::Sybase - Segmentation Fault
Bonjour à tous,
je suis sur debian 3.1 avec Perl 5.8.4 et une install de sybase 11-9.
J'ai plusieurs questions à poser concernant l'installation et la configuration des DBD::.
- En règle générale, l'installation d'un DBD::* sur une machine implique t'elle d'avoir le SGBD installé (ou une partie) sur cette même machine. Par exemple, pour installer DBD::Sybase, est ce qu'il faut avoir un Sybase qui tourne en local, ou un client ...?
Ou le DBD:: se suffit à lui même ?
- J'ai installé sur la debian le DBD::Sybase. Voila l'output de la manip :
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
|
ROCK:/app/tempdbd/DBD-Sybase-1.07# perl Makefile.PL
Sybase OpenClient 11.1.1 found.
By default DBD::Sybase 1.05 and later use the 'CHAINED' mode (where available)
when 'AutoCommit' is turned off. Versions 1.04 and older instead managed
the transactions explicitly with a 'BEGIN TRAN' before the first DML
statement. Using the 'CHAINED' mode is preferable as it is the way that
Sybase implements AutoCommit handling for both its ODBC and JDBC drivers.
Use 'CHAINED' mode by default (Y/N) [Y]: y
Running in threaded mode - looking for _r libraries...
No thread-safe Sybase libraries found
The DBD::Sybase module need access to a Sybase server to run the tests.
To clear an entry please enter 'undef'
Sybase server to use (default: SYBASE):
User ID to log in to Sybase (default: sa):
Password (default: undef):
Sybase database to use on SYBASE (default: undef): master
* Writing login information, including password, to file PWD.
Multiple copies of Driver.xst found in: /usr/local/lib/perl/5.8.4/auto/DBI/ /usr/lib/perl5/auto/DBI/ at Makefile.PL line 59
Using DBI 1.53 (for perl 5.008004 on i386-linux-thread-multi) installed in /usr/local/lib/perl/5.8.4/auto/DBI/
Writing Makefile for DBD::Sybase
ROCK:/app/tempdbd/DBD-Sybase-1.07# make
cc -c -I/app/sybase/include -DNO_THREADS -I/usr/local/lib/perl/5.8.4/auto/DBI -D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS -DDEBIAN -fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -DVERSION=\"1.07\" -DXS_VERSION=\"1.07\" -fPIC "-I/usr/lib/perl/5.8/CORE" Sybase.c
cc -c -I/app/sybase/include -DNO_THREADS -I/usr/local/lib/perl/5.8.4/auto/DBI -D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS -DDEBIAN -fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -DVERSION=\"1.07\" -DXS_VERSION=\"1.07\" -fPIC "-I/usr/lib/perl/5.8/CORE" dbdimp.c
Running Mkbootstrap for DBD::Sybase ()
chmod 644 Sybase.bs
rm -f blib/arch/auto/DBD/Sybase/Sybase.so
LD_RUN_PATH="/app/sybase/lib" cc -L/app/sybase/lib -shared -L/usr/local/lib Sybase.o dbdimp.o -o blib/arch/auto/DBD/Sybase/Sybase.so -L/app/sybase/lib -lct -lcs -lsybtcl -lcomn -lintl -lblk -ldl -lm
chmod 755 blib/arch/auto/DBD/Sybase/Sybase.so
cp Sybase.bs blib/arch/auto/DBD/Sybase/Sybase.bs
chmod 644 blib/arch/auto/DBD/Sybase/Sybase.bs
Manifying blib/man3/DBD::Sybase.3
ROCK:/app/tempdbd/DBD-Sybase-1.07# make install
Installing /usr/local/lib/perl/5.8.4/auto/DBD/Sybase/Sybase.so
Files found in blib/arch: installing files in blib/lib into architecture dependent library tree
Writing /usr/local/lib/perl/5.8.4/auto/DBD/Sybase/.packlist
Appending installation info to /usr/local/lib/perl/5.8.4/perllocal.pod
ROCK:/app/tempdbd/DBD-Sybase-1.07# |
- une fois tout ca fait, j'ai essayé de faire tourné un ptit code sample de PERL, pour voir...
le code :
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
|
#!/bin/perl
use strict;
use DBI;
use Getopt::Long;
$| = 1;
#get params
my $host = '';
my $user = 'sa';
my $pass = '';
my $database = 'master';
my $instance = 'Default';
my @data;
#GetOptions ("instance=s" => \$instance,
# "user=s" => \$user,
# "pass=s" => \$pass,
# );
my $string = 'dbi:Sybase:server=Default;database=master';
#connect
my $dbh=DBI->connect('dbi:Sybase:server='.$instance.';database=master','sa',''); |
et le problème, c'est que j'ai un énorme :
SEGMENTATION FAULT... comme résultat.
Mon problème majeur, c'est que je ne suis pas sur du tout que le DBD::Sybase soit configuré comme il se doit.
Donc, je voudrais un coup de main pour vérifier cette config.
Merci à tous :D
Meme probleme sous fedora 6
Bonjour,
J'ai moi aussi un probleme de lancement avec Fedora 6 et sybase 12-5.
J'ai lu tout les post possible sur le net, et même le site de Mickael ne m'a pas aidé :(
Voici mon erreur lorsque je lance RUN_sybase en tant que sybase user :
-bash-3.1$ ./RUN_sybase
00:00000:00000:2007/05/06 00:04:19.17 kernel Adaptive Server Enterprise Express Edition (Limits: 1 Engine, 2GB Memory, 5GB Disk space).
00:00000:00000:2007/05/06 00:04:19.17 kernel Using config area from primary master device.
00:00000:00000:2007/05/06 00:04:19.18 kernel os_find_good_keyfile: Could not open file /home/sybase/ASE-12_5/sybase.krg: File exists
00:00000:00000:2007/05/06 00:04:19.18 kernel kbcreate: couldn't get shmid for kernel region.
00:00000:00000:2007/05/06 00:04:19.18 kernel kistartup: could not create shared memory
./RUN_sybase: line 16: 2357 Segmentation fault /home/sybase/ASE-12_5/bin/dataserver -d/home/sybase/data/master.dat -e/home/sybase/ASE-12_5/install/sybase.log -c/home/sybase/ASE-12_5/sybase.cfg -M/home/sybase/ASE-12_5 -ssybase
***************************************************
Et lorsque sur lance avec root :
[root@cl-t057-080cl install]# ./RUN_sybase
00:00000:00000:2007/05/06 00:06:40.55 kernel Adaptive Server Enterprise Express Edition (Limits: 1 Engine, 2GB Memory, 5GB Disk space).
00:00000:00000:2007/05/06 00:06:40.55 kernel Using config area from primary master device.
00:00000:00000:2007/05/06 00:06:40.56 kernel os_create_keyfile: Removed old segment /home/sybase/ASE-12_5/sybase.krg
00:00000:00000:2007/05/06 00:06:40.56 kernel Internal run-time model set for Linux - Native
00:00000:00000:2007/05/06 00:06:40.56 kernel Using 1024 file descriptors.
00:00000:00000:2007/05/06 00:06:40.56 kernel Adaptive Server Enterprise/12.5.2/EBF 12123/P/Linux Intel/Enterprise Linux/ase1252/1839/32-bit/OPT(Express Edition)/Fri Aug 13 08:27:18 2004
00:00000:00000:2007/05/06 00:06:40.56 kernel Confidential property of Sybase, Inc.
00:00000:00000:2007/05/06 00:06:40.56 kernel Copyright 1987, 2004
00:00000:00000:2007/05/06 00:06:40.56 kernel Sybase, Inc. All rights reserved.
00:00000:00000:2007/05/06 00:06:40.56 kernel Unpublished rights reserved under U.S. copyright laws.
00:00000:00000:2007/05/06 00:06:40.56 kernel
00:00000:00000:2007/05/06 00:06:40.56 kernel This software contains confidential and trade secret information of Sybase,
00:00000:00000:2007/05/06 00:06:40.56 kernel Inc. Use, duplication or disclosure of the software and documentation by
00:00000:00000:2007/05/06 00:06:40.56 kernel the U.S. Government is subject to restrictions set forth in a license
00:00000:00000:2007/05/06 00:06:40.56 kernel agreement between the Government and Sybase, Inc. or other written
00:00000:00000:2007/05/06 00:06:40.56 kernel agreement specifying the Government's rights to use the software and any
00:00000:00000:2007/05/06 00:06:40.56 kernel applicable FAR provisions, for example, FAR 52.227-19.
00:00000:00000:2007/05/06 00:06:40.56 kernel Sybase, Inc. One Sybase Drive, Dublin, CA 94568, USA
00:00000:00000:2007/05/06 00:06:40.56 kernel ASE booted on Linux release 2.6.20-1.2948.fc6 version #1 SMP Fri Apr 27 18:53:15 EDT 2007.
00:00000:00000:2007/05/06 00:06:40.56 kernel Using '/home/sybase/ASE-12_5/sybase.cfg' for configuration information.
00:00000:00000:2007/05/06 00:06:40.56 kernel Logging ASE messages in file '/home/sybase/ASE-12_5/install/sybase.log'.
00:00000:00000:2007/05/06 00:06:40.57 kernel Platform TCP network is forced to IPv4-only.
00:00000:00000:2007/05/06 00:06:40.57 kernel SQL Server booted with TCP_NODELAY enabled.
00:00000:00000:2007/05/06 00:06:40.57 kernel SSL Plus v3.0.8 security modules loaded successfully.
00:00000:00000:2007/05/06 00:06:40.57 kernel Network and device connection limit is 1014.
00:00000:00000:2007/05/06 00:06:40.64 server Number of blocks left for proc headers: 3232.
00:00000:00000:2007/05/06 00:06:40.64 server Proc header memory allocated 1616 pages for each per engine cache
00:00000:00000:2007/05/06 00:06:40.66 server Size of the 16K memory pool: 8192 Kb
00:00000:00000:2007/05/06 00:06:40.66 server Memory allocated for the default data cache cachelet 1: 8192 Kb
00:00000:00000:2007/05/06 00:06:40.66 kernel Extended cache size '0' is invalid. Provide the appropriate size value.
00:00000:00000:2007/05/06 00:06:40.66 kernel Enabling (RT) Posix asynchronous disk I/O strategy.
00:00000:00000:2007/05/06 00:06:40.66 kernel Initializing virtual device 0, '/home/sybase/data/master.dat' with dsync 'on'.
00:00000:00000:2007/05/06 00:06:40.66 kernel Virtual device 0 started using asynchronous i/o.
00:00000:00000:2007/05/06 00:06:40.66 kernel Worker Thread Manager is not enabled for use in SQL Server.
00:00000:00000:2007/05/06 00:06:40.66 kernel Either the config parameter 'use security services' is set to 0, or ASE does not support use of external security mechanisms on this platform. The Security Control Layer will not be initialized. No external security mechanisms will be supported.
00:00000:00000:2007/05/06 00:06:40.66 kernel Unix interval timer enabled for sysclk interrupts.
00:00000:00000:2007/05/06 00:06:40.66 kernel Unable to load LDAP dynamic library: '/home/sybase//home/sybase/lib3p/libnspr3.so'.
00:00000:00000:2007/05/06 00:06:40.66 kernel engine 0, os pid 2363 online
00:00000:00000:2007/05/06 00:06:40.66 kernel current process (0x0) infected with 11
00:00000:00000:2007/05/06 00:06:40.66 kernel kechkfault: engine 0: scheduler infected with signal 11
00:00000:00000:2007/05/06 00:06:40.68 kernel pc 0x87e22ed ucbacktrace+0x89(0x0,0x1,0x930b084,0x0,0x0)
00:00000:00000:2007/05/06 00:06:40.68 kernel pc 0x87f529e keipanic+0x5e(0xc378,0x0,0xb,0x930b084,0x37667a8)
00:00000:00000:2007/05/06 00:06:40.68 kernel pc 0x87f380c kechkfault+0x48(0xb,0x0,0x0,0x0,0x11ef60)
00:00000:00000:2007/05/06 00:06:40.68 kernel pc 0x880174c kisignal+0x78(0xb,0x37667bc,0x376683c,0xb,0x0)
00:00000:00000:2007/05/06 00:06:40.68 kernel pc 0x677440 (0x0,0x0,0x0,0x1077900,0x5)
00:00000:00000:2007/05/06 00:06:40.68 kernel pc 0x895eed31 init_dummy+0x80994d31(0x0,0x1077900,0x5,0x1,0x5374616b)
00:00000:00000:2007/05/06 00:06:40.68 kernel end of stack trace, kernel service process: kpid 0
00:00000:00000:2007/05/06 00:06:40.68 kernel ueshutdown: exiting
00:00000:00000:2007/05/06 00:06:40.68 kernel Abnormal exit detected - SQL Server process level execution bindings will be cleared on startup.
./RUN_sybase: line 16: 2363 Segmentation fault /home/sybase/ASE-12_5/bin/dataserver -d/home/sybase/data/master.dat -e/home/sybase/ASE-12_5/install/sybase.log -c/home/sybase/ASE-12_5/sybase.cfg -M/home/sybase/ASE-12_5 -ssybase
[root@cl-t057-080cl install]#
****************************************************
Une idée ?
Merci !