2

I am trying to install and run collectd on Solaris 10 x86. I downloaded the Solaris x86 version of the installer. Installed using pkd_add command and chose the default folders.

Now I am trying to run the daemon, but it doesn't seem to work. Here is the problem / error:

bash-3.00# sbin/collectd
bash: sbin/collectd: cannot execute binary file
5
  • have you checked if you have 'x' rights on sbin/collectd ?
    – Coren
    Commented Mar 16, 2012 at 8:57
  • Yes, I have 'x' rights for sbin and collectd Commented Mar 16, 2012 at 9:06
  • 1
    What does file sbin/collectd yield? This error typically comes from using a binary made for another platform (SPARC vs x86, Solaris vs Linux, MacOS vs Linux). Commented Mar 16, 2012 at 22:10
  • @lars-rohrbach Here is what I get: sbin/collectd: ELF 64-bit LSB executable AMD64 Version 1 [SSE2 SSE FXSR FPU], dynamically linked, not stripped Commented Mar 19, 2012 at 11:26
  • See also Getting "Not found" message when running a 32-bit binary on a 64-bit system You have an executable format that your kernel doesn't support. Commented Mar 26, 2012 at 1:01

1 Answer 1

2

Based on your output from file sbin/collectd, you are attempting to execute a binary for AMD64 (also known as x86_64), which I see the collectd website offers in package form for Solaris 10. This will only work on x86_64, not on i386. I suspect that you have i386 (you can double-check with uname -p or uname -a).

Since the collectd folks aren't offering a ready-to-go package for Solaris 10 x86, it seems, the only option would be to compile it from source.

Do you have SUNWspro installed for the Sun cc compiler? I ran into difficulty trying to compile collectd with gcc on Solaris 10 x86, but Sun's cc worked like this:

wget http://collectd.org/files/collectd-5.0.3.tar.bz2
gtar xjf collectd-5.0.3.tar.bz2
cd collectd-5.0.3
./configure CC=/path/to/cc CFLAGS="-m64 -mt -D_POSIX_PTHREAD_SEMANTICS"
make && make install
1
  • 1
    isainfo -v is the Solaris command to determine support for 32-bit/64-bit binaries. Commented Mar 20, 2012 at 23:48

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .