Question:
What is Linux executable file extension, for example windows executable files are EXE, what is it in linux?
user
2011-12-16 08:14:47 UTC
What is Linux executable file extension, for example windows executable files are EXE, what is it in linux?
Four answers:
Kevin Lain
2011-12-16 08:23:36 UTC
File extensions don;t really mean much in Linux, if you remove .txt or .jpg or whatever the os will still work out what kind of file it is.



You don't generally have binary extensions in Linux. It's not like Windows where you download random files off the internet then run them.



If you ls /bin or /usr/bin you'll see no file extensions.



.sh is for a bash script

.pl is for a perl script

.deb is a debian package, it's basically a zip file, it's not an executable, same for .rpm

None of them are binaries...
sigurdson
2016-11-09 05:50:50 UTC
Executable File Extensions
Connie
2011-12-16 12:23:22 UTC
Executable files are not indicated by the extension in Linux.

They are indicated by having an "Executable" flag set on the file descriptor.



So an executable file will not run unless this bit is set on the permissions for that file.

Right click on a file and choose properties and then permissions...

Along with this information, the file descriptor also contains information about who owns a file, and who can execute the file...just because a file is executable, if you do not have permission to run it, you won't be able to.



The computer can be made to automatically open a particular file type using a particular file...so files ending in .pl can be automatically run using PERL...but even this is unnecessary as scripts that that need to be run using a particular program declare which program should be used in the first line in the file...
James
2011-12-16 08:17:41 UTC
Any file that has the .sh, .pl, .deb (for Debian based systems), .rpm (for Red Hat based systems), or .bin are executable files and are generally installer files.


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...