<div dir="ltr"><div>Hi Carsten,</div><div><br></div><div>I had the same problems as Joop, here, too, the psql -q helped.</div><div><br></div><div>See this post for another one who had the problem. Strangely enough I could not find any hint in the bacula community repositories.</div><div><br></div><div>Why does it take so long (over a year) </div><div><br></div><div>Regards,</div><div>Sebastian</div><div><br></div><div>On Tue, 02 Sep 2025 18:03:07 +0200 Carsten Leonhardt <<a href="mailto:leo@debian.org">leo@debian.org</a>> wrote:</div>> Control: unmerge -1<br>> Control: reopen -1<br>> <br>> Hi Joop,<br>> <br>> actually, we fixed the escaping, but this is the first time we hear<br>> about the "-q" parameter problem.<br>> <br>> We'll need to investigate that. <br>> <br>> Regards<br>> <br>> Carsten<br>> <br>> <br>> Carsten Leonhardt <<a href="mailto:leo@debian.org">leo@debian.org</a>> writes:<br>> <br>> > Control: forcemerge 1108272 -1<br>> ><br>> > Hi Joop,<br>> ><br>> > thanks for your report. We have already addressed this in version<br>> > 15.0.3-4, which unfortunately is not in the current Debian stable<br>> > release (c.f. bug #1108272).<br>> ><br>> > We highly recommend letting dbconfig-common handle the databases.<br>> ><br>> > Regards<br>> ><br>> > Carsten<br>> ><br>> ><br>> > Joop Boonen <<a href="mailto:joop.boonen@credativ.de">joop.boonen@credativ.de</a>> writes:<br>> ><br>> >> Package: bacula-director-pgsql<br>> >><br>> >>  Version: 15.0.3-3<br>> >><br>> >> When I invoke<br>> >><br>> >>  sudo -u postgres /usr/share/bacula-director/update_postgresql_tables -d <bacula_database><br>> >> The Baculadatabase isnt' upgraded due to a few "errors" in the script.<br>> >><br>> >><br>> >><br>> >> The First error the psql dump is created without a -q, this causes that header data ends up in the file. Because of this the restore fails.<br>> >><br>> >><br>> >><br>> >> Secondly the postgresql do $$ is not correctly escaped. Therefore bash replaces the $$ to the current process id.<br>> >><br>> >><br>> >><br>> >><br>> >><br>> >><br>> >><br>> >><br>> >>   I suggest the following patch:<br>> >><br></div>