0

The old question is below. The problem was ftp transfer mode wasn't binary.

But now i have another issue.

Running hiphop compiled file gives following error (The one compiled on another computer).

"error while loading shared libraries: libmemcached.so.7:cannot open shared object file:No such file or directory."

But native compiled one works with no trouble.

How can i link or load such library? Can anybody help me out?


I'm using ubuntu 11.04 on both home and vps server. I followed this (https://github.com/facebook/hiphop-php/wiki/Building-and-Installing-on-Ubuntu-11.04) instruction to set facebook's hiphop up. And i did achived to compile my php sources to executable binary on both server and home pc.

But if i send the binary file to server which s compiled from home pc it doesn't run and prompts as "can not execute binary file".

But server can run the binary file compiled in itself.

Why i just can't run this home compiled file on server. (It runs at home)

  • Home OS is ubuntu 11.04 64 bit same as the server.And hiphop compiler (so the libraries) were installed on both. – Emre Kanca Sep 28 '11 at 19:02

2 Answers2

0

Are your desktop and server using the same architecture? Binaries compiled on a 64-bit system will not run on a 32-bit OS, and binaries compiled on a 32-bit OS will require the ia32-libs package to be installed on a 64-bit system.

  • Server is (Ubuntu 11.04 x86_64 - Ubuntu 11.04 64bit base.) openvz.And home is 64bit too. – Emre Kanca Sep 28 '11 at 18:57
  • How do you send the files over to the server? – hakre Sep 28 '11 at 19:02
  • I send by ftp then mark (allow executing file as program) from permissions tab – Emre Kanca Sep 28 '11 at 19:06
  • 1
    either the binary is incompatible (can not execute, wrong compile command) or the files get modified when you transfer them (e.g. ASCII mode in FTP probably). You can check if it's a transfer problem by creating checksums of the file on each system and compare them with each other (SHA1, MD5). – hakre Sep 28 '11 at 19:09
  • I changed filezillas transfer mode auto to binary.Now it says "error while loading shared libraries: libmemcached.so.7:cannot open shared object file:No such file or directory." But the other (native) compiled one still have no error. – Emre Kanca Sep 28 '11 at 19:40
0

I figured it out. I created same user name on my vps as i have on my home computer. Gave it sudoers right. (visudo)

And build hiphop in the same directory as i did on my home computer. Now it runs with the new user.