Question

In my home folder in Linux I have several config files that have "rc" as a file name extension:

$ ls -a ~/|pcregrep 'rc$'
.bashrc
.octaverc
.perltidyrc
.screenrc
.vimrc

What does the "rc" in these names mean?

Était-ce utile?

La solution

It looks like one of the following:

  • run commands
  • resource control
  • run control
  • runtime configuration

Also I've found a citation:

The ‘rc’ suffix goes back to Unix's grandparent, CTSS. It had a command-script feature called "runcom". Early Unixes used ‘rc’ for the name of the operating system's boot script, as a tribute to CTSS runcom.

Autres conseils

Runtime Configuration normally if it's in the config directory. I think of them as resource files. If you see rc in file name this could be version i.e. Release Candidate.

Edit: No, I take it back officially... "run commands"

[Unix: from runcom files on the CTSS system 1962-63, via the startup script /etc/rc]

Script file containing startup instructions for an application program (or an entire operating system), usually a text file containing commands of the sort that might have been invoked manually once the system was running but are to be executed automatically each time the system starts up.

Thus, it would seem that the "rc" part stands for "runcom", which I believe can be expanded to "run commands". In fact, this is exactly what the file contains, commands that bash should run.

Quoted from What does “rc” in .bashrc stand for?

I learnt something new! :)

In the context of Unix-like systems, the term rc stands for the phrase "run commands". It is used for any file that contains startup information for a command. It is believed to have originated somewhere in 1965 from a runcom facility from the MIT Compatible Time-Sharing System (CTSS).

Reference: https://en.wikipedia.org/wiki/Run_commands

In Unix world, RC stands for "Run Control".

http://www.catb.org/~esr/writings/taoup/html/ch10s03.html

To understand rc files, it helps to know that Ubuntu boots into several different runlevels. They are 0-6, 0 being "halt", 1 being "single-user", 2 being "multi-user"(the default runlevel), etc. This system has now been outdated by the Upstart and initd programs in most Linux Distros. It is still maintained for backwards compatibility.

Within the /etc directory are several folders labeled "rc0.d, rc1.d" etc, through rc6.d. These are the directories the kernel refers to to know which init scripts it should run for that runlevel. They are symbolic links to the system service scripts residing in the /etc/init.d directory.

In the context you are using it, it would appear that you are listing any files with rc in the name. The code in these files will set the way the services/tasks startup and run when initialized.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top