Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #258407

Editing /etc/rc.local [was: How to run a command / script on startup automatically in linux?]

From <tomas@tuxteam.de>
Newsgroups linux.debian.user
Subject Editing /etc/rc.local [was: How to run a command / script on startup automatically in linux?]
Date 2023-05-16 06:40 +0200
Message-ID <GvUDD-9dRT-1@gated-at.bofh.it> (permalink)
References <GvKkV-97s9-3@gated-at.bofh.it> <GvKuB-97vG-3@gated-at.bofh.it> <GvMd3-98Be-1@gated-at.bofh.it> <GvMwp-98HY-3@gated-at.bofh.it> <GvNC9-99A8-13@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

Changed $SUBJECT, because already way off track.

On Mon, May 15, 2023 at 11:05:07PM +0200, Vincent Lefevre wrote:
> On 2023-05-15 15:56:17 -0400, Greg Wooledge wrote:

[editing /etc/rc.local is a bad idea]

> > That's incorrect.
> 
> It is correct, as shown by the following command:
> 
> zira:~> dlocate etc/rc.local
> initscripts: /etc/rc.local
> 
> Ditto with "apt-file search etc/rc.local".

I'm with Greg here. /etc/rc.local is package-provided, but it is
a conffile [1], [2]:

  tomas@trotzki:~$ dpkg --status initscripts
  Package: initscripts
  Status: install ok installed
  Priority: optional
  [...]
  Conffiles:
   /etc/default/devpts 725336081392e54776899acd2bff6e39
   [...]
   /etc/rc.local 12fe1992accd3a3977b4d8985ebeea9e
  [...]

It's there for you, the system administrator to edit and change.
The packaging system is explicitly designed to cope with that
situation (technically it keeps a fingerprint of the pristine
file and checks that on updates giving you, the sysadmin, the
chance to forward-port your changes).

Cheers

[1] https://www.debian.org/doc/manuals/maint-guide/dother.en.html#conffiles
[2] https://raphaelhertzog.com/2010/09/21/debian-conffile-configuration-file-managed-by-dpkg/
-- 
tomás

Back to linux.debian.user | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

How to run a command / script on startup automatically in linux? "Susmita/Rajib" <bkpsusmitaa@gmail.com> - 2023-05-15 19:40 +0200
  Re: How to run a command / script on startup automatically in linux? Greg Wooledge <greg@wooledge.org> - 2023-05-15 19:50 +0200
    Re: How to run a command / script on startup automatically in  linux? Charles Curley <charlescurley@charlescurley.com> - 2023-05-15 20:50 +0200
      Re: How to run a command / script on startup automatically in linux? Greg Wooledge <greg@wooledge.org> - 2023-05-15 21:00 +0200
        Re: How to run a command / script on startup automatically in linux? <tomas@tuxteam.de> - 2023-05-16 06:30 +0200
    Re: How to run a command / script on startup automatically in linux? Vincent Lefevre <vincent@vinc17.net> - 2023-05-15 21:40 +0200
      Re: How to run a command / script on startup automatically in linux? Greg Wooledge <greg@wooledge.org> - 2023-05-15 22:00 +0200
        Re: How to run a command / script on startup automatically in linux? Vincent Lefevre <vincent@vinc17.net> - 2023-05-15 23:10 +0200
          Editing /etc/rc.local [was: How to run a command / script on startup  automatically in linux?] <tomas@tuxteam.de> - 2023-05-16 06:40 +0200
            Re: Editing /etc/rc.local [was: How to run a command / script on  startup automatically in linux?] Vincent Lefevre <vincent@vinc17.net> - 2023-05-16 11:50 +0200
  Re: How to run a command / script on startup automatically in  linux? Charles Curley <charlescurley@charlescurley.com> - 2023-05-15 20:00 +0200
    Re: How to run a command / script on startup automatically in linux? Max Nikulin <manikulin@gmail.com> - 2023-05-16 04:40 +0200
      Re: How to run a command / script on startup automatically in linux? Max Nikulin <manikulin@gmail.com> - 2023-05-16 09:10 +0200
  Re: How to run a command / script on startup automatically in linux? Christoph Brinkhaus <c.brinkhaus@t-online.de> - 2023-05-15 20:10 +0200
  Re: How to run a command / script on startup automatically in linux? <tomas@tuxteam.de> - 2023-05-15 20:30 +0200
    Re: How to run a command / script on startup automatically in  linux? Charles Curley <charlescurley@charlescurley.com> - 2023-05-15 20:50 +0200
    Re: How to run a command / script on startup automatically in  linux? Joe <joe@jretrading.com> - 2023-05-15 21:40 +0200
  Re: How to run a command / script on startup automatically in linux? "Susmita/Rajib" <bkpsusmitaa@gmail.com> - 2023-05-16 07:50 +0200
    Re: How to run a command / script on startup automatically in linux? Vincent Lefevre <vincent@vinc17.net> - 2023-05-16 12:10 +0200
    Re: How to run a command / script on startup automatically in linux? Greg Wooledge <greg@wooledge.org> - 2023-05-16 13:20 +0200
    Re: How to run a command / script on startup automatically in linux? "Susmita/Rajib" <bkpsusmitaa@gmail.com> - 2023-05-16 14:10 +0200
      Re: How to run a command / script on startup automatically in linux? "Susmita/Rajib" <bkpsusmitaa@gmail.com> - 2023-05-18 08:10 +0200

csiph-web