Re: --initdb

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



At 8:13 AM -0500 12/1/06, James Olin Oden wrote:
>On 11/30/06, Jeff Johnson <n3npq.jbj@xxxxxxxxx> wrote:
>> On 11/30/06, Tony Nelson <tonynelson@xxxxxxxxxxxxxxxxx> wrote:
>> > Does "rpm --initdb" ever delete database files, specifically the Packages
>> > file?  Is it safe to do "rpm --initdb ; rpm --rebuilddb"?  I want to get
>> > straight what "rpm --initdb" does, so I don't give bad advice.
>> >
>> > I had read that --initdb created a fresh, new database, as implied by "man
>> > rpm", wiping out the old database.  Others have disagreed, and it seems
>> > that they are right.  I looked casually at the RPM source code for
>>--initdb
>> > (stopping when it called through a function pointer), and it looks like
>> > --initdb only tries to open / create the database file(s), and won't
>> > replace existing files.  I ran "rpm -vv --initdb --dbpath
>> > /my/broken/database", and it only mentioned the Packages file.
>>
>> The only current use in rpm for --initdb is to conform to the doco
>> so that I don't have to waste time and energy explaining to users why
>>--initdb
>> hasn't been needed for years and years.
>>
>Which is to say rpm uses a lazy algorithm to create the initial rpm
>database, such that you never have to explicitly call --initdb which
>historically was used to create the initial rpm database.   In other
>words, rpm creates the initial rpm database automatically.

Yes.  The confusion is that some people think, and can read the RPM man
page to say, that --initdb will remove the current RPM database and replace
it with a new empty database.  Possibly RPM used to do it that way?
Anyway, RH BZ 218057.
-- 
____________________________________________________________________
TonyN.:'    The Great Writ     <mailto:tonynelson@xxxxxxxxxxxxxxxxx>
      '      is no more.             <http://www.georgeanelson.com/>

_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/rpm-list

[Index of Archives]     [RPM Ecosystem]     [Linux Kernel]     [Red Hat Install]     [PAM]     [Red Hat Watch]     [Red Hat Development]     [Red Hat]     [Gimp]     [Yosemite News]     [IETF Discussion]

  Powered by Linux