If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Sybase > Bizarre problem with OCS-15 on Linux -- not reading interfaces file

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old
Registered User
 
Join Date: Apr 2003
Posts: 64
Bizarre problem with OCS-15 on Linux -- not reading interfaces file

Hello!

I compiled sybtcl on RHEL-5.7 (64bit) by hand. The extension links with the sole library -lsybdb64.

The new extension loads into Tcl-interpreter without a problem, but refuses to connect -- to anything: Server name not found in interface file.

Nothing unusual, huh? Newbies mess up their interfaces files all the time, right?

Well, for one Sybase's own isql continues to work -- for the same server-name on the same shell-prompt (thus, using the same environment variables).

But what's really bizarre is that, according to strace, nothing even attempts to open an interfaces file! If I strace isql-invocation, I see it opening the file up:
Code:
open("/opt/sybase/interfaces", O_RDONLY) = 6
access("/opt/sybase/interfaces", W_OK) = -1 EACCES (Permission denied)
stat64("/opt/sybase/interfaces", {st_mode=S_IFREG|0644, st_size=2317, ...}) = 0
But, when I strace the sybtcl-loading tclsh-process, there is no mention of interfaces-file until the error message...

The same script -- using the same credentials -- connects without a hitch from a FreeBSD system, where sybtcl is compiled against FreeTDS, rather than Sybase/OCS...

Any ideas? Thanks a lot!
__________________
If you ever back up Sybase, you want this backup-server plugin.

Last edited by teterin; 12-06-12 at 23:00.
Reply With Quote
  #2 (permalink)  
Old
Registered User
 
Join Date: Apr 2003
Posts: 64
Stupid, stupid, stupid... I invoked sybconnect with one extra argument for "encoding" (iso1). But -- and this is documented in sybtcl(n) -- that argument is interpreted as the interfaces-file (the encoding goes after that).

FreeTDS cheerfully ignores the interfaces-parameter, apparently, which mislead me into thinking, my code is Ok.

Never mind anybody...

BTW, if you are interested in an RPM spec-file for sybtcl, drop me a note...
__________________
If you ever back up Sybase, you want this backup-server plugin.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On