What file on FreeBSD acts like autoexec.bat?

Oliver Fromme olli at lurza.secnetix.de
Mon Sep 29 07:39:38 UTC 2008


Mike Price <bipolor at gmail.com> wrote:
 > What file on FreeBSD acts like autoexec.bat?
 > Also please leave the full path%

The file that probably comes closest is /etc/rc.local
(you have to create it, it doesn't exist by default).

Actually FreeBSD's rc system allows much more flexible
scripting ...  If you're interested, start by reading
the rc(8) manual page.  But if you only need some simple
commands executed upon every boot, just put them in
/etc/rc.local and you're done.

Note, however, that you have to use sh(1) shell command
syntax, not COMMAND.COM syntax.  ;-)

By the way, the file that corresponds to config.sys on
a FreeBSD system is /etc/rc.conf (see the rc.conf(5)
manual page for details).

Best regards
   Oliver

-- 
Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing b. M.
Handelsregister: Registergericht Muenchen, HRA 74606,  Geschäftsfuehrung:
secnetix Verwaltungsgesellsch. mbH, Handelsregister: Registergericht Mün-
chen, HRB 125758,  Geschäftsführer: Maik Bachmann, Olaf Erb, Ralf Gebhart

FreeBSD-Dienstleistungen, -Produkte und mehr:  http://www.secnetix.de/bsd

"A language that doesn't have everything is actually easier
to program in than some that do."
        -- Dennis M. Ritchie


More information about the freebsd-hackers mailing list