public inbox for [email protected]help / color / mirror / Atom feed
Re: Bash profile 3+ messages / 3 participants [nested] [flat]
* Re: Bash profile @ 2025-02-15 19:17 Yongye Serkfem <[email protected]> 2025-02-15 21:02 ` Re: Bash profile Ron Johnson <[email protected]> 2025-02-15 21:09 ` Re: Bash profile Adrian Klaver <[email protected]> 0 siblings, 2 replies; 3+ messages in thread From: Yongye Serkfem @ 2025-02-15 19:17 UTC (permalink / raw) To: Ron Johnson <[email protected]>; +Cc: pgsql-generallists.postgresql.org <[email protected]> I am upgrading from version 12.7 to 15.7 On Sat, Feb 15, 2025, 2:15 PM Ron Johnson <[email protected]> wrote: > On Sat, Feb 15, 2025 at 2:01 PM Yongye Serkfem <[email protected]> wrote: > >> Hi Everyone! >> I would appreciate any assistance with configuring the bash profile to >> run two different postgresql versions. Specifically V12.7 and 15.7 >> > > Create a bash function that exports PGDATA to the relevant directory, > based on the parameter you pass. > Add as much error checking (to ensure that the parameter you passed > actually points to a real data dir and that the postmaster is running. How > you do that depends on whether it's Debian-based, RH-based or something > else. > > We, for example, have standardized on data directories in the format: > /Database/<MajorVer>/data > > Thus, something as simple as this would work for us: > pgswitch() { export PGDATA=/Database/${1}/data ; } > > -- > Death to <Redacted>, and butter sauce. > Don't boil me, I'm still alive. > <Redacted> lobster! > ^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Bash profile 2025-02-15 19:17 Re: Bash profile Yongye Serkfem <[email protected]> @ 2025-02-15 21:02 ` Ron Johnson <[email protected]> 1 sibling, 0 replies; 3+ messages in thread From: Ron Johnson @ 2025-02-15 21:02 UTC (permalink / raw) To: pgsql-generallists.postgresql.org <[email protected]> So? Honestly, your question has zero to do with Postgresql. Its basic Linux configuration. Before the migration, PGDATA and PATH should point to the v12 "stuff", and after the migration they should point to the v15 "stuff". It's that simple. On Sat, Feb 15, 2025 at 2:17 PM Yongye Serkfem <[email protected]> wrote: > I am upgrading from version 12.7 to 15.7 > > On Sat, Feb 15, 2025, 2:15 PM Ron Johnson <[email protected]> wrote: > >> On Sat, Feb 15, 2025 at 2:01 PM Yongye Serkfem <[email protected]> >> wrote: >> >>> Hi Everyone! >>> I would appreciate any assistance with configuring the bash profile to >>> run two different postgresql versions. Specifically V12.7 and 15.7 >>> >> >> Create a bash function that exports PGDATA to the relevant directory, >> based on the parameter you pass. >> Add as much error checking (to ensure that the parameter you passed >> actually points to a real data dir and that the postmaster is running. How >> you do that depends on whether it's Debian-based, RH-based or something >> else. >> >> We, for example, have standardized on data directories in the format: >> /Database/<MajorVer>/data >> >> Thus, something as simple as this would work for us: >> pgswitch() { export PGDATA=/Database/${1}/data ; } >> >> -- >> Death to <Redacted>, and butter sauce. >> Don't boil me, I'm still alive. >> <Redacted> lobster! >> > -- Death to <Redacted>, and butter sauce. Don't boil me, I'm still alive. <Redacted> lobster! ^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Bash profile 2025-02-15 19:17 Re: Bash profile Yongye Serkfem <[email protected]> @ 2025-02-15 21:09 ` Adrian Klaver <[email protected]> 1 sibling, 0 replies; 3+ messages in thread From: Adrian Klaver @ 2025-02-15 21:09 UTC (permalink / raw) To: Yongye Serkfem <[email protected]>; Ron Johnson <[email protected]>; +Cc: pgsql-generallists.postgresql.org <[email protected]> On 2/15/25 11:17, Yongye Serkfem wrote: > I am upgrading from version 12.7 to 15.7 You are going to have to explain what, in your situation, BASH has to do with the upgrade process. Generally migrations depend on Postgres programs and are not shell specific. > > > On Sat, Feb 15, 2025, 2:15 PM Ron Johnson <[email protected] > <mailto:[email protected]>> wrote: > > On Sat, Feb 15, 2025 at 2:01 PM Yongye Serkfem <[email protected] > <mailto:[email protected]>> wrote: > > Hi Everyone! > I would appreciate any assistance with configuring the bash > profile to run two different postgresql versions. Specifically > V12.7 and 15.7 > > > Create a bash function that exports PGDATA to the relevant > directory, based on the parameter you pass. > Add as much error checking (to ensure that the parameter you passed > actually points to a real data dir and that the postmaster is > running. How you do that depends on whether it's Debian-based, > RH-based or something else. > > We, for example, have standardized on data directories in the format: > /Database/<MajorVer>/data > > Thus, something as simple as this would work for us: > pgswitch() { export PGDATA=/Database/${1}/data ; } > > -- > Death to <Redacted>, and butter sauce. > Don't boil me, I'm still alive. > <Redacted> lobster! > -- Adrian Klaver [email protected] ^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2025-02-15 21:09 UTC | newest] Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2025-02-15 19:17 Re: Bash profile Yongye Serkfem <[email protected]> 2025-02-15 21:02 ` Ron Johnson <[email protected]> 2025-02-15 21:09 ` Adrian Klaver <[email protected]>
This inbox is served by agora; see mirroring instructions for how to clone and mirror all data and code used for this inbox