libtermcap and Debian 3.1

rjshelq
Posts: 82
Joined: Thu Nov 17, 2005 3:25 pm

libtermcap and Debian 3.1

Post by rjshelq »

Hi,

The server that I'm on is running Debian 3.1, and the Webinator 5.1 install fails due to lack of libtermcap.

I'm on a shared server, which means that I have no permissions in the directories belonging to root, such as /usr.

So, I have two questions:

1) On the Debain web site, they say:

If you want to compile a program that claims to need termcap, why not try ncurses's termcap emulation instead? It's as simple as linking with ncurses instead of libtermcap (i.e. replace the '-ltermcap' with '-lncurses' in the makefile). Ncurses' termcap emulation routines translate terminfo entries to termcap entries on the fly, so you don't even need an /etc/termcap file.

... so, is it possible for Webinator 5.1 to use ncurses? If so, what specifically needs to be changed?

2) If ncurses can't be used, is there a way that a non-root user can install libtermcap (as available on your ftp site) to run properly with webinator 5.1?

thanks,
Richard
User avatar
mark
Site Admin
Posts: 5519
Joined: Tue Apr 25, 2000 6:56 pm

libtermcap and Debian 3.1

Post by mark »

Set the environment variable LD_LIBRARY_PATH to the directory with the libraries.

LD_LIBRARY_PATH=/the/path/to/custom/libs
export LD_LIBRARY_PATH
rjshelq
Posts: 82
Joined: Thu Nov 17, 2005 3:25 pm

libtermcap and Debian 3.1

Post by rjshelq »

Thanks... but it seems that it may not be possible for me, as a user (non-root), to set the LD_LIBRARY_PATH variable on my shared server.

My server is using kernel 2.6.16.20, so I put the libtermcap.so.2 library for the 2.6 kernel (from your ftp site) at /home/xxxx/etc/webinator_dir/lib, and then tried:

env LD_LIBRARY_PATH=/home/xxxx/etc/webinator_dir/lib ./install

but that failed to find the libtermcap library.

so then I tried:

env LD_LIBRARY_PATH=/home/xxxx/etc/webinator_dir/lib
export LD_LIBRARY_PATH
./install

but that also failed to find the libtermcap library.

Is there a way solve this problem by compiling the code with a switch set to tell the linker where the library is?
or by linking with ncurses?
User avatar
mark
Site Admin
Posts: 5519
Joined: Tue Apr 25, 2000 6:56 pm

libtermcap and Debian 3.1

Post by mark »

Did you download the 2.6l2.3 version of webinator?

It's linked with both ncurses and termcap. I'm not sure of the whys and wherefores but it generally needs both.

Most systems will ignore LD_LIBRARY_PATH if the program is setuid. Try installing it as the web server user after removing modifying the install to not setuid.
Change
chmod u=rwxs,go=rx
chmod u+s
to
chmod u=rwx,go=rx
chmod u-s
respectively whereever they occur.
rjshelq
Posts: 82
Joined: Thu Nov 17, 2005 3:25 pm

libtermcap and Debian 3.1

Post by rjshelq »

version 2.612.3??? I'm not sure what that version is... the version of Webinator that I downloaded is called Webinator-5.1.tar.gz. Is there another version number that I should look for?

I tried the chmod revisions that you suggested, along with LD_LIBRARY_PATH, but I still get the error messge that libtermcap.so.2 cannot be found.

Debian offers a "compatability package" that will install libtermcap.so.2 ... but, the Debian web site says:

"The termcap-compat package provides the libtermcap.so.2 and /etc/termcap files which are required to run non-Debian, binary-only termcap-based programs. Since libc6-based programs are hopefully "modern" enough to be linked with ncurses (or slang), this package only provides a libc5-based libtermcap library.

You need this package if a program (that you cannot recompile) fails to run with the error message "...: can't load library 'libtermcap.so.2'" or complains about a missing /etc/termcap file.

The termcap-compat package isn't meant to be used to compile programs therefore it doesn't provide all the necessary files for compilation. If you want to compile a program that claims to need termcap, why not try ncurses's termcap emulation instead?"

I could beg and plead to try to get my web-host to add that package if it would solve the problem. Do you think that the libtermcap.so.2 that Debian described above would be satisfactory for the needs of the Webinator 5.1 install?
User avatar
mark
Site Admin
Posts: 5519
Joined: Tue Apr 25, 2000 6:56 pm

libtermcap and Debian 3.1

Post by mark »

2.612.3 is how it's listed on the download site as there are several versions for linux.

I would suspect that the termcap-compat package would make things work.

There are way too many distributions of linux to ever hope to build for them all. RedHat, for better or worse, is dominant and binaries built there work on many distros.
rjshelq
Posts: 82
Joined: Thu Nov 17, 2005 3:25 pm

libtermcap and Debian 3.1

Post by rjshelq »

I have 2.412.2 (the server is 32 bit, Linux 2.6.18.2) Is that the proper version?

The Debian libtermcap.so.2 package is now installed, and the installation seemed to run fine:

Checking install dir...Ok
Checking tar file...Ok
Unpacking Webinator files...Ok
Checking for existing version..........Ok
Checking files...Ok
Configuring and installing Webinator files:
INFO: 1 patch made
INFO: 1 patch made
INFO: 1 patch made
INFO: 2 patches made
INFO: 1 patch made
INFO: 1 patch made
INFO: 1 patch made
INFO: 1 patch made
Cleaning up temp files...done

But then it failed to make the texis symlink. So I quit the installation and copied the texis symlink into my cgi-bin.


Then, running the installtest via web-browser
http://wahiduddin.net/cgi-bin/texis/ins ... html?-dump

gets the reply:

Texis Web Script (Vortex) Copyright © 1996-2006 Thunderstone - EPI, Inc.
Unknown Version 5.01.1162154767 20061029 (i686-unknown-linux2.4.9-64-32)

Error
011 Texis Monitor process failed to create license segment
000 Cannot get config settings

The monitor log says:

200 2006-11-16 18:59:43 (1961) Texis Monitor version 05.01.1162154767 starting
011 2006-11-16 18:59:43 (1961) Could not create license segment: No space left on device/No such file or directory

The vortex log says:

011 2006-11-16 18:59:46 Texis Monitor process failed to create license segment
000 2006-11-16 18:59:46 Cannot get config settings

ipcs -a gives me:

------ Shared Memory Segments --------
key shmid owner perms bytes nattch status
0x00000000 0 www-data 644 46 0

------ Semaphore Arrays --------
key semid owner perms nsems

------ Message Queues --------
key msqid owner perms used-bytes messages


What file or directory is the monitor message "No space left on device" referring to?

Do you have any ideas of what the problem is?
User avatar
mark
Site Admin
Posts: 5519
Joined: Tue Apr 25, 2000 6:56 pm

libtermcap and Debian 3.1

Post by mark »

That would generally mean there was no shared mem or it was all used already. Possibly a problem with the shared server environment. Ask the hoster if you can get more shared mem, at least a meg.
rjshelq
Posts: 82
Joined: Thu Nov 17, 2005 3:25 pm

libtermcap and Debian 3.1

Post by rjshelq »

In your earlier suggestion you said:

" Try installing it as the web server user after removing modifying the install to not setuid.
Change
chmod u=rwxs,go=rx
chmod u+s
to
chmod u=rwx,go=rx
chmod u-s
respectively whereever they occur."

I don't understand what you mean by "installing it as the web server user". How do I do that? (sorry, I'm not much of a Linux-head yet)

I modified the install script as you suggested, and ran it from my bash shell. The program seemed to install fine, it put the link in the cgi-bin, and now has an allocation in shared memory that says:

0xdbaccee5 0 wahiduddin666 202980 1

The monitor log says:

200 2006-11-20 15:30:05 (6627) Texis Monitor version 05.01.1162154767 starting
200 2006-11-20 15:30:06 (6661) Database Monitor on /home/1702/etc/webinator_dir/texis/testdb/ starting

That all seems quite encouraging, but when I try to access via my web browser, the vortex log says:

002 2006-11-20 15:32:06 /webinator/dowalk: Cannot open source file: No such file or directory

What next?
rjshelq
Posts: 82
Joined: Thu Nov 17, 2005 3:25 pm

libtermcap and Debian 3.1

Post by rjshelq »

p.s. the web browser command

http://wahiduddin.net/cgi-bin/texis/ins ... html?-dump

did in fact seem to work ok, and gave me a whole page of info:

Texis Web Script (Vortex) Copyright © 1996-2006 Thunderstone - EPI, Inc.
Free Webinator Version 5.01.1162154767 20061029 (i686-unknown-linux2.4.9-64-32)

Environment
..... blah blah blah... this all looks ok....

Command line
texis -dump

Variables
$urlroot='/cgi-bin/texis/installtest'
$pathroot='/installtest'
$sourcepath='/home/1702/domains/wahiduddin.net/html/installtest'
Post Reply