Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Where can I find the source code for Linux utilities and daemons. Basically I want to know the repository of source codes other than the Linux kernel.

share|improve this question

You can find that on GNU's Savannah. For example here's coreutils.

share|improve this answer

Each distribution likely has "source" packages which include any changes they've mde to the various utilities -- you can download and install these on your system to read through the source and/or change & recompile it to your heart's content.

You may also want to consider looking at the source trees for the BSD operating systems (these can be downloaded from each project, as well as various web interfaces for perusing the code & history of changes, for example The FreeBSD project's CVSWeb).

share|improve this answer

I would suggest freebsd's source code and ports tree, but you have asked about linux.

Last time I have use it, a while ago, I could recompile anytime any of the userland applications like: ps, df, ls, netstat, sockstat, sendmail, etc. In freebsd I could donwload from portstree the source code, modify it, build and install. Also, it was easy for me to include custom patches.

This is one feature I miss in linux. It was so easy and fast to recompile the kernel, or just the whole OS, any application or service. Of course, this feature exists in linux also, but is not that automated as in freebsd.

This is just how i feel it and I might be wrong. I don;t want to start a linux/bsd war here.


share|improve this answer
-1 The question is about how to do something for a Linux system, not comparing how to do it with FreeBSD. This answer is not applicable. – daveadams Feb 18 '11 at 14:05
But then the correct answer should be: it's not linux source code, it's GNU source code. Linux is only a kernel :-) – DutchUncle Feb 18 '11 at 19:04
Look, it was so easy to me to modify things in the source code. I thought it will help mentioning my experience. – Paul Feb 19 '11 at 5:25

I suspect it's not going to do you much good if you don't understand the difference between utilities, daemons and the kernel.

The answer is the internet.

There is no single repository containing all of the source code for every distribution of Linux.

The official releases of the kernel are available from

Al linux distributions are required by the terms of licencing terms of most of their software to publish the source code (including any modifications) - this functionality is usually available from the package manager - but you didn't say which distribution you are using.

share|improve this answer

In addition to Savannah as pointed out by @Dennis, each distribution typically has its own method of providing source code for various binary packages. For example, in Debian or Ubuntu, you can use apt-get source packagename, which will download the source code for the package you specify to the working directory.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.