Command to run (execute) bin files in Linux

Q. I have downloaded a file from internet that ends with .bin extension. Documentation says just run bin file. What command I need to type in order to run bin files in Linux.

A. .bin files are Linux self extracting binary files. For example Java or Flash are two examples of these types of file. Just type following two commands to run .bin files:

Run .bin file in Linux / UNIX

Change the permission of the file you downloaded to be executable. Type the following command:
$ chmod +x file.bin

Start the installation process or run .bin file.Type the following command:
./file.bin

For example if .bin file name is application.bin. Type:
$ chmod +x application.bin
$ ./application.bin

Another example for Java Linux self extracting binary file:
# chmod +x jre-1_5_0-linux-i586.bin
# ./jre-1_5_0-linux-i586.bin

Want to read Linux tips and tricks, but don't have time to check our blog everyday? Subscribe to our daily email newsletter to make sure you don't miss a single tip/tricks. Subscribe to our weekly newsletter here!

{ 14 comments… read them below or add one }

1 darthpooky 07.07.08 at 10:50 pm

if that doesn’t work try sudo ./file.bin on debian
or su ./file.bin on other distros

2 saraswathi 07.13.08 at 3:30 am

resubmitting to be notified of a reply by email.

Hello ,
I was trying to extract from the java bin file. I could change the mode, but when I say ./filename.bin ( according to your last example), it says file not found although I am just cutting and pasting the file name and it is in the same directory.

[saras@node032 ~]$ chmod +x ./java_ee_sdk-5_05-linux.bin
[saras@node032 ~]$ ./java_ee_sdk-5_05-linux.bin
./java_ee_sdk-5_05-linux.bin: error while loading shared libraries: libstdc++.so.5: cannot open shared object file: No such file or directory
[saras@node032 ~]$
can you help please ? thanks

saras

3 vivek 07.13.08 at 8:47 am

yu need to install libstdc++ package to solve this problem. Use yum under centos/fedora/redhat or apt-get under debian/ubuntu Linux.

4 saraswathi 07.13.08 at 7:01 pm

Thanks Vivek.
I managed to unzip it. I have a unrelated question on running java on a cluster. Where can I ask the question. I was not sure if I should ask about it here.

saras

5 vivek 07.13.08 at 9:13 pm

Try out forum

6 vishal 08.19.08 at 4:35 am

while executing a bin file i am getting the message : End-of-central-directory signature not found.

pls help

7 pratik 11.21.08 at 3:53 pm

i get the following erroe while running the ./Googleearthlinux.bin command that is the fllowing
Verifying archive integrity…Error in MD5 checksums: 97ca3ea1d8c49adb873a8a13114463b4 is different from 33fdc468b730cef74ac8f5cc4dc83259

what to do now?

8 vivek 11.21.08 at 4:03 pm

pratik,

Your file is corrupted. Delete current file and download fresh file again.

9 Andrej 12.15.08 at 4:36 pm

Hi,
I have a Synology 207+ at home running on Linux and the ARM architecture.
Now I want to install JRE so I can make Jetty run in order to be able to use Java servlets and jsp files in my webpage.
Now when trying to install j2re-1_4_2_19-linux-i586.bin I get an error:
380: /usr/bin/sum: Permission Denied
expr: syntax error
expr: syntax error
Extracting…
./install.sfx.15986: ./install.sfx.15986: 1: Syntax error: “(” unexpected
Done.

What does this mean? I’m not sure if I downloaded the proper JRE. Does someone know how to fix this? thanks

10 fatimah 12.24.08 at 6:44 am

I have to run a UNIX shell script . What command I need to type in order to run UNIX shell files in Linux?

11 Pate 01.04.09 at 10:16 pm

When I normally klik the .bin file it opens with kate (text editor). I have tried to run the command, but it only opens mozilla and types it in the url section. What is wrong? I have installed libstdc++6

12 Rick Flores 02.21.09 at 12:04 am

Hey guys,
I was trying to install SiteMinder Policy Server on CentOS 5.2. I already chmod+x’d it. As I executed the .bin file I received this error. I have googled it and this error is not mentioned in the install manual. I would appreciate some advise.

Rick Flores

[root@localhost SiteMinder Policy Server]# ./ca-ps-12.0-sp1-linux.bin
Preparing to install…
Extracting the JRE from the installer archive…
Unpacking the JRE…
Extracting the installation resources from the installer archive…
Configuring the installer for this system’s environment…

Launching installer…

‘SWING’ UI not supported by VM. Reverting to AWT.
Invocation of this Java Application has caused an InvocationTargetException. This application will now exit. (LAX)

Stack Trace:
java.lang.NoClassDefFoundError
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:140)
at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:62)
at java.awt.Window.init(Window.java:224)
at java.awt.Window.(Window.java:268)
at java.awt.Frame.(Frame.java:398)
at java.awt.Frame.(Frame.java:363)
at com.zerog.ia.installer.LifeCycleManager.g(DashoA8113)
at com.zerog.ia.installer.LifeCycleManager.h(DashoA8113)
at com.zerog.ia.installer.LifeCycleManager.a(DashoA8113)
at com.zerog.ia.installer.Main.main(DashoA8113)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at com.zerog.lax.LAX.launch(DashoA8113)
at com.zerog.lax.LAX.main(DashoA8113)
This Application has Unexpectedly Quit: Invocation of this Java Application has caused an InvocationTargetException. This application will now exit. (LAX)

13 Srinivasa kp 05.15.09 at 11:38 am

Hi,
Sometimes you need to change the file name and then install.

Srinivasa.k.p

14 Ziga 06.02.09 at 7:19 pm

Hi!
I am new to linux.My situation:
ziga@ziga-laptop:~$ chomd +x./math.bin
ziga@ziga-laptop:~$ /home/ziga/math/…/emlin701/math.bin
bash: /home/ziga/math/…/emlin701/math.bin: cannot execute binary file
What can i do? Is there an option to transform an .bin into an .iso file?
Thanks for your help.

Leave a Comment

You can use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Tagged as: , , , , ,

Previous post: Howto: UNIX or Linux convert DOS newlines CR-LF to Unix/Linux format

Next post: Howto: Linux detect or find out a dual-core cpu