lcd 36% ssh
ssh: Cannot find ELF
Killed
There are numerous messages on the net about this problem with
other programs. So it's not specific to OpenSSH.
sshd is running fine.
lcd 34% printenv LD_LIBRARY_PATH
/usr/lib:/usr/local/lib:/opt/SUNWspro/lib
Any pointers very much appreciated.
Anne M. Hammond
University of Colorado at Boulder
What does "file `which ssh`" show?
--
________________________________________________________________________
Alan Coopersmith al...@alum.calberkeley.org
http://soar.Berkeley.EDU/~alanc/ aka: Alan.Coo...@Sun.COM
Working for, but definitely not speaking for, Sun Microsystems, Inc.
> lcd 36% ssh
> ssh: Cannot find ELF
> Killed
It might be Gnu strip going berserk.
Put /usr/ccs/bin/strip before Gnu strip in your $PATH
or replace stripprog="${STRIPPROG-strip}"
by stripprog=/usr/ccs/bin/strip in "install-sh" in your
OpenSSH-sources.
IIRC, running Gnu strip twice a time on your binary
fixed it too.
strip was Gnu strip:
lcd 11% which strip
/usr/local/bin/strip
I did make clean, and compiled using Sun's cc, and the error
message is gone.
But I'd like to discover what causes this. I'll compile
again and replace stripprog.
Anne
I love egcs, but given the choice I'd always use the Forte tools.
(extra tools like fpversion...)
-Andrew Mueller
http://www.synecdoche.net/~andy
Strip is used to save filesystem and memory space after
the object file has been tested and is ready for installation.
As you can see, the resultant file is about 20% the size of
the original:
-rwxr-xr-x 1 root 4359576 Jul 18 15:12 ./ssh
-rwxr-xr-x 1 root 933876 Jul 18 15:15 ssh (installed version)
To solve this problem of the executable not containing the
full information, use /usr/ccs/bin/strip instead of
/usr/local/bin/strip. Either setenv PATH so that /usr/ccs/bin
is first, or edit install-sh:
#stripprog="${STRIPPROG-strip}"
stripprog=/usr/ccs/bin/strip
You can diagnose this by running the ldd utility on the object
file in the compile directory, and on the installed directory:
lcd 255# ldd ./ssh
libz.so => /usr/local/lib/libz.so
libsocket.so.1 => /usr/lib/libsocket.so.1
libnsl.so.1 => /usr/lib/libnsl.so.1
libc.so.1 => /usr/lib/libc.so.1
libdl.so.1 => /usr/lib/libdl.so.1
libmp.so.2 => /usr/lib/libmp.so.2
/usr/platform/SUNW,Ultra-4/lib/libc_psr.so.1
lcd 256# ldd /usr2/newssh/bin/ssh
ldd: /usr2/newssh/bin/ssh: file has insecure interpreter ELF
This is an ls of the object file in the compile directory, and
in the installion directory, when /usr/ccs/bin/strip is used.
/usr/ccs/bin/strip actually creates a smaller executable than
gnu's strip:
-rwxr-xr-x 1 root 4359576 Jul 18 15:12 ./ssh
-rwxr-xr-x 1 root 891380 Jul 19 12:57 /usr2/newssh/bin/ssh
LD_LIBRARY_PATH does not have anything to do with this problem.
There may be options to gnu's strip, but I haven't investigated
this.
Another fix is to run gnu strip twice on the object file.
I haven't tried this. Also since make install doesn't do this,
using /usr/ccs/bin/strip seems a better solution.
Thanks to Tino Reinhardt for solving this problem.
Anne Hammond
Strip is used to save filesystem and memory space after
the object file has been tested and is ready for installation.
As you can see, the resultant file is about 20% the size of
the original:
-rwxr-xr-x 1 root 4359576 Jul 18 15:12 ./ssh
-rwxr-xr-x 1 root 933876 Jul 18 15:15 ssh (installed version)
To solve this problem of the executable not containing the
full information, use /usr/ccs/bin/strip instead of
/usr/local/bin/strip. Either setenv PATH so that /usr/ccs/bin
is first, or edit install-sh:
#stripprog="${STRIPPROG-strip}"
stripprog=/usr/ccs/bin/strip
You can diagnose this by running the ldd utility on the object
file in the compile directory, and on the installed binary:
lcd 255# ldd ./ssh
libz.so => /usr/local/lib/libz.so
libsocket.so.1 => /usr/lib/libsocket.so.1
libnsl.so.1 => /usr/lib/libnsl.so.1
libc.so.1 => /usr/lib/libc.so.1
libdl.so.1 => /usr/lib/libdl.so.1
libmp.so.2 => /usr/lib/libmp.so.2
/usr/platform/SUNW,Ultra-4/lib/libc_psr.so.1
lcd 256# ldd /usr2/newssh/bin/ssh
ldd: /usr2/newssh/bin/ssh: file has insecure interpreter ELF
Below is an ls of the object file in the compile directory, and
in the installion directory, when /usr/ccs/bin/strip is used.
/usr/ccs/bin/strip actually creates a smaller executable than
gnu's strip:
-rwxr-xr-x 1 root 4359576 Jul 18 15:12 ./ssh
-rwxr-xr-x 1 root 891380 Jul 19 12:57 /usr2/newssh/bin/ssh
LD_LIBRARY_PATH does not have anything to do with this problem.
There may be options to gnu's strip, but I haven't investigated
this.
Another fix is to run gnu strip twice on the object file.
I didn't try this. Since make install doesn't run strip twice,