Find the answer to your Linux question:
Page 1 of 2 1 2 LastLast
Results 1 to 10 of 12
Hi all Linux users, I have downloaded a new software into my Linux Cluster. It contains source code, documentations and executable programs. I wanted to run one of the programs, ...
  1. #1
    Just Joined!
    Join Date
    Apr 2009
    Posts
    12

    cannot execute binary file

    Hi all Linux users,

    I have downloaded a new software into my Linux Cluster. It contains source code, documentations and executable programs. I wanted to run one of the programs, however an error message appeared which I couldn't figure out.

    I'm going to show the contents of a perl script file and a text file which are needed to execute a program named "convertf". Both files are provided by the software.

    perl script named "example.perl":

    #!/usr/bin/perl
    $parfile="par.EIGENSTRAT.PED";
    system("../bin/convertf -p $parfile");


    text file named "par.EIGENSTRAT.PED":

    genotypename: example.eigenstratgeno
    snpname: example.snp
    indivname: example.ind
    outputformat: PED
    genotypeoutname: example.ped
    snpoutname: example.pedsnp
    indivoutname: example.pedind

    The command I submitted at shell prompt:
    [phoebe@calypso ~EigenSoft/CONVERTF]$ ./example.perl

    The error message appeared: ../bin/convertf: ../bin/convertf: cannot execute binary file

    Does anyone know why?

    Thanks in advance for your help,
    Phoebe

  2. #2
    Just Joined! neirons's Avatar
    Join Date
    Nov 2006
    Location
    Latvia, Liepaja
    Posts
    18
    ../bin/convertf are executable? That means, the file have setted to be executable?
    Open terminal and execute that command: ls -l ../bin
    -rwxr--r-- 1 username groupname filesize date&time convertf
    On first columnt You can see file attributes. File must be executable for Owner. If not use command chmod. Example:
    chmod a+x ../bin/convertf (You must be root for that)

  3. #3
    Just Joined!
    Join Date
    Apr 2009
    Posts
    12
    Thanks neirons for your reply!

    after I excecuting command: ls -l ../bin
    it showed that the file attribute was -rwxr--xr-x,
    then I executed the chmod command as you suggested, the file attribute was still the same as before, it didn't change.

    Do you know why?

    Thanks!

  4. #4
    Just Joined! neirons's Avatar
    Join Date
    Nov 2006
    Location
    Latvia, Liepaja
    Posts
    18
    Quote Originally Posted by phoebekong View Post
    Thanks neirons for your reply!

    after I excecuting command: ls -l ../bin
    it showed that the file attribute was -rwxr--xr-x,
    then I executed the chmod command as you suggested, the file attribute was still the same as before, it didn't change.

    Do you know why?

    Thanks!
    There can be different reasons. Is very hard to imagine, what exactly.

    This software are "EIGENSOFT version 3.0, March 2009" ??

    I had to tray on my own computer. And result are different problems. But not about executing. There is more problems...

  5. #5
    Just Joined!
    Join Date
    Apr 2009
    Posts
    12
    yeah, it is EIGENSOFT v3.0! I downloaded it from here
    Software

    I have one colleague using this software as well. She encountered the same problem when using the same cluster as I do. However she said it worked running in another cluster!

    If I really couldn't figure out this error, I will probably run in another cluster,

    thanks a lot for your reply !

    Best,
    Phoebe

  6. #6
    Just Joined! neirons's Avatar
    Join Date
    Nov 2006
    Location
    Latvia, Liepaja
    Posts
    18
    Hi,

    What kind of Linux/Unix You have?

    Tnx for answer

  7. #7
    Just Joined!
    Join Date
    Apr 2009
    Posts
    12
    I'm using RedHat Linux.

    I found out that the problem that my colleague encountered was different from mine (She had problem running another executable). She didn't have problem to run the convertf program while using the the same cluster as I do.

    I hope we could find out the reason.

  8. #8
    Linux Enthusiast
    Join Date
    Aug 2006
    Location
    Portsmouth, UK
    Posts
    539
    possibly no-exec permisions on the /home ( I'm assuming the ~EigenSoft is in /home ) directory.
    You can use the mount command to check ( make sure there is no "noexec" )

    Code:
    [<user>@centos5 ~]$ mount | grep home
    /dev/hda3 on /home type ext3 (rw)
    My /tmp partitions is no execute:

    Code:
    [<user>@centos5 ~]$ mount | grep tmp
    /dev/hda5 on /tmp type ext3 (rw,noexec,nosuid)
    tmpfs on /dev/shm type tmpfs (rw)
    RHCE #100-015-395
    Please don't PM me with questions as no reply may offend, that's what the forums are for.

  9. #9
    Just Joined!
    Join Date
    Apr 2009
    Posts
    12
    Yes, the EigenSoft is in my /home directory.
    I tried the mount command, here is what was displayed,

    [phoebe@calypso ~]$ mount | grep home
    rhea:/ab/homes on /home type nfs (rw,rsize=8192,wsize=8192,bg,nointr,hard)
    192.168.2.107:/data on /home/aday/data type nfs (rw,rsize=8192,wsize=8192,bg,nointr,hard)

    It looks like there is no "noexec".

    A friend told me that this might caused by the reason that systems couldn't find the executable prg. There is a prg which was in the EIGENSOFT, I execute it in the same directory: ./progname. It did work.

    Refer back to theperl script, the following function,
    system("../bin/convertf -p $parfile")
    It called the convertf program in different directory. Do you think this command make it not working?

    I appreciate your comment.

    Thanks.

  10. #10
    Linux Enthusiast
    Join Date
    Aug 2006
    Location
    Portsmouth, UK
    Posts
    539
    The error message appeared: ../bin/convertf: ../bin/convertf: cannot execute binary file
    Well this says that it's looking for the convertf script / program one directory back in the directory bin i.e.

    If your in /home/EigenSoft/CONVERTF it will be looking for convertf in /home/EigenSoft/bin

    perl script named "example.perl":

    #!/usr/bin/perl
    $parfile="par.EIGENSTRAT.PED";
    system("../bin/convertf -p $parfile");
    I notice that this is an example, have you read the readme / documentation ?
    RHCE #100-015-395
    Please don't PM me with questions as no reply may offend, that's what the forums are for.

Page 1 of 2 1 2 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...