LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   32 bit binaries do not run on 64 bit machine (https://www.linuxquestions.org/questions/linux-software-2/32-bit-binaries-do-not-run-on-64-bit-machine-864378/)

paulsm4 02-27-2011 07:04 PM

Hi -

Here's what I get when I downloaded your "hw32.txt" (renaming it to "hw32.exe"):
Code:

$ ls -l hw32.exe
-rwxr-xr-x 1 paulsm paulsm 4940 Feb 27 17:00 hw32.exe

$ file hw32.exe
hw32.exe: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), for GNU/Linux 2.6.9, dynamically linked (uses shared libs), for GNU/Linux 2.6.9, not stripped

$ ldd hw32.exe
        libc.so.6 => /lib/libc.so.6 (0xb7dcb000)
        /lib/ld-linux.so.2 (0xb7f2f000)

$ chmod +rx hw32.exe

$ ./hw32.exe
Hello World

From my earlier post:
Quote:

1) The initial post seemed to have NOTHING to do with 32- vs 64-bit, and EVERYTHING to do with the correct syntax for invoking a Java program with the correct .jar. Please revisit that at some point before closing this thread.
<= The Java/.jar question is COMPLETELY INDEPENDENT of the 32- vs 64-bit executable question

2) In general, 32-bit apps CAN and DO run without any problem on 64-bit OS's.
...
<= Even if you DIDN'T have the right runtime libraries for your 32-bit .exe...
the symptoms would NOT be what you've described!!!!!

3) Please cut/paste your exact "hello world" source, compile command and command line output now that you've updated your libraries. If anything's wrong, please run "file hw*" and "ldd hw*" on your "hw" executables, and cut/paste the results.
<= I firmly believe you're simply running the wrong .exe somehow.
Please - PLEASE - recompile, execute (with "./hw32" syntax) and cut/paste everything exactly into your next post.

frznchckn 02-27-2011 07:30 PM

Paul,

You'll find all the information you requested in one of the posts of mine in this thread already. Yeah, I ran the correct executable.

All,
Valery and johnsfine's theory seems to be the winning one for now. I'll forward this to red hat on that ticket and see how where it goes. Hopefully this is it. Quite a bit of progress in less than 48 hours.

Thanks! And I'll update when I know something for sure.

frznchckn 02-27-2011 08:41 PM

I went for the Hail Mary and just did the fix for the fix. The binary "hw32" prints "Hello World" to stdout as it should. The java program I was interested in now runs properly.

Thank you all for the help. This was figured out so fast.

I'll leave this open just to confirm with the enterprise support. ;)

corp769 02-27-2011 08:47 PM

Quote:

Originally Posted by frznchckn (Post 4273423)
I went for the Hail Mary and just did the fix for the fix. The binary "hw32" prints "Hello World" to stdout as it should. The java program I was interested in now runs properly.

Thank you all for the help. This was figured out so fast.

I'll leave this open just to confirm with the enterprise support. ;)

Awesome! I have been following the whole thing because the other guys that were helping out knew more than me to troubleshoot that. Mentally noted, thanks to all also.

Cheers,

Josh

frznchckn 02-28-2011 11:46 AM

Thanks
 
RH confirmed that this was the problem and that this security problem was definitely corrected for my RHEL 5 update 6 box.

I'm going to close this. Again, thanks to all of you. We avoided reinstalling this box today which we needed to do because of a compressed project schedule.

Valery Reznic 02-28-2011 12:13 PM

Quote:

Originally Posted by frznchckn (Post 4274157)
RH confirmed that this was the problem and that this security problem was definitely corrected for my RHEL 5 update 6 box.

I'm going to close this. Again, thanks to all of you. We avoided reinstalling this box today which we needed to do because of a compressed project schedule.

I enjoyed investigation your problem - it wasn't ordinary. Always something new to learn.
Have you another one, interesting like this?

Valery.

(By the way, you moved ld.so.cache to ld.so.cache.orig. I guess it's a time to move it back)

frznchckn 02-28-2011 12:20 PM

Thanks for reminding me of that Valery. I had left that on a todo list that I probably would've forgotten.

No, no more interesting problems (thankfully for me). I'm an engineer, I needed this server for CAD work. :)


All times are GMT -5. The time now is 03:17 AM.