Where is initdb?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jerome Lyles

    Where is initdb?

    Hello List,

    I have installed Postgresql 7.4 on a Suse 9.0 system using apt.
    I cannot do this:

    /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data

    Because there is no "/pgsql/bin/initdb" nor /pgsql/bin/ on my system.
    Since apt did not create these directories how can I do it manually?
    Thanks,
    Jerome



    ---------------------------(end of broadcast)---------------------------
    TIP 8: explain analyze is your friend

  • Martín Marqués

    #2
    Re: Where is initdb?

    Mensaje citado por Jerome Lyles <susemail@hawai i.rr.com>:
    [color=blue]
    > Hello List,
    >
    > I have installed Postgresql 7.4 on a Suse 9.0 system using apt.
    > I cannot do this:
    >
    > /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data
    >
    > Because there is no "/pgsql/bin/initdb" nor /pgsql/bin/ on my system.
    > Since apt did not create these directories how can I do it manually?[/color]

    You don't. Normal rpm packagers put binaries in /usr/bin and not in
    /usr/local/pgsql/bin.

    Try this:

    $ initdb -D /var/lib/pgsql/data

    Or, just try to start the database with the init script:

    # /etc/init.d/postgresql start

    If it's like the one I have here on Fedora, it should run initdb automatically if
    the Cluster hasn't been built yet.

    --
    select 'mmarques' || '@' || 'unl.edu.ar' AS email;
    -------------------------------------------------------
    Martín Marqués | Programador, DBA
    Centro de Telemática | Administrador
    Universidad Nacional
    del Litoral
    -------------------------------------------------------

    ---------------------------(end of broadcast)---------------------------
    TIP 4: Don't 'kill -9' the postmaster

    Comment

    • Peter Eisentraut

      #3
      Re: Where is initdb?

      Jerome Lyles wrote:[color=blue]
      > I have installed Postgresql 7.4 on a Suse 9.0 system using apt.
      > I cannot do this:
      >
      > /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data[/color]

      Just run

      /etc/init.d/postgresql start

      and it will be taken care of. Read the README files in
      /usr/share/doc/packages/postgresql-* to learn about how the packages
      are layed out.


      ---------------------------(end of broadcast)---------------------------
      TIP 5: Have you checked our extensive FAQ?



      Comment

      • Jeremiah Jahn

        #4
        Re: Where is initdb?

        although it will be taken care of, make sure that initdb sets the local
        language to C or your string indexes will not be used.. Unless this has
        been fixed and en_US works as as well?


        On Mon, 2004-01-26 at 13:32, Peter Eisentraut wrote:[color=blue]
        > Jerome Lyles wrote:[color=green]
        > > I have installed Postgresql 7.4 on a Suse 9.0 system using apt.
        > > I cannot do this:
        > >
        > > /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data[/color]
        >
        > Just run
        >
        > /etc/init.d/postgresql start
        >
        > and it will be taken care of. Read the README files in
        > /usr/share/doc/packages/postgresql-* to learn about how the packages
        > are layed out.
        >
        >
        > ---------------------------(end of broadcast)---------------------------
        > TIP 5: Have you checked our extensive FAQ?
        >
        > http://www.postgresql.org/docs/faqs/FAQ.html[/color]
        --
        Jeremiah Jahn <jeremiah@cs.ea rlham.edu>


        ---------------------------(end of broadcast)---------------------------
        TIP 3: if posting/reading through Usenet, please send an appropriate
        subscribe-nomail command to majordomo@postg resql.org so that your
        message can get through to the mailing list cleanly

        Comment

        • Martín Marqués

          #5
          Re: Where is initdb?

          Mensaje citado por Jeremiah Jahn <jeremiah@cs.ea rlham.edu>:
          [color=blue]
          > although it will be taken care of, make sure that initdb sets the local
          > language to C or your string indexes will not be used.. Unless this has
          > been fixed and en_US works as as well?[/color]

          I think that if you really need very fast indexes, the first thing to do is read
          the instalation manual and configure very carefully the postgres acount
          (envioronment variables, etc).

          --
          select 'mmarques' || '@' || 'unl.edu.ar' AS email;
          -------------------------------------------------------
          Martín Marqués | Programador, DBA
          Centro de Telemática | Administrador
          Universidad Nacional
          del Litoral
          -------------------------------------------------------

          ---------------------------(end of broadcast)---------------------------
          TIP 8: explain analyze is your friend

          Comment

          • Jeremiah Jahn

            #6
            Re: Where is initdb?

            I think it's fair to say that out of the box and RPM install should not
            result in indexes not being used because the LANG is set to something
            other than 'C'. I'm all for reading the manual and tuning later, but
            that is something that can't be changed without a complete
            dump/initdb/restore. It's just always seemed kind of misleading to me..

            -jj-


            On Mon, 2004-01-26 at 13:51, Martín Marqués wrote:[color=blue]
            > Mensaje citado por Jeremiah Jahn <jeremiah@cs.ea rlham.edu>:
            >[color=green]
            > > although it will be taken care of, make sure that initdb sets the local
            > > language to C or your string indexes will not be used.. Unless this has
            > > been fixed and en_US works as as well?[/color]
            >
            > I think that if you really need very fast indexes, the first thing to do is read
            > the instalation manual and configure very carefully the postgres acount
            > (envioronment variables, etc).[/color]
            --
            Jeremiah Jahn <jeremiah@cs.ea rlham.edu>


            ---------------------------(end of broadcast)---------------------------
            TIP 8: explain analyze is your friend

            Comment

            • Peter Eisentraut

              #7
              Re: Where is initdb?

              Jeremiah Jahn wrote:[color=blue]
              > although it will be taken care of, make sure that initdb sets the
              > local language to C or your string indexes will not be used.. Unless
              > this has been fixed and en_US works as as well?[/color]

              It has been fixed. Be sure to read the documentation about details.


              ---------------------------(end of broadcast)---------------------------
              TIP 1: subscribe and unsubscribe commands go to majordomo@postg resql.org

              Comment

              • Martín Marqués

                #8
                Re: Where is initdb?

                Mensaje citado por Jeremiah Jahn <jeremiah@cs.ea rlham.edu>:
                [color=blue]
                > I think it's fair to say that out of the box and RPM install should not
                > result in indexes not being used because the LANG is set to something
                > other than 'C'. I'm all for reading the manual and tuning later, but
                > that is something that can't be changed without a complete
                > dump/initdb/restore. It's just always seemed kind of misleading to me..[/color]

                The question is which should be the default? For me it's better to have
                LANG=es_AR, just because I will have REAL string ordering in a query like this:

                SELECT varfield FROM sometable ORDER BY varfield;

                That would work great with 'C' locale if varfield didn't contain caracters like á,
                é, í, ó, ú, ñ.

                --
                select 'mmarques' || '@' || 'unl.edu.ar' AS email;
                -------------------------------------------------------
                Martín Marqués | Programador, DBA
                Centro de Telemática | Administrador
                Universidad Nacional
                del Litoral
                -------------------------------------------------------

                ---------------------------(end of broadcast)---------------------------
                TIP 3: if posting/reading through Usenet, please send an appropriate
                subscribe-nomail command to majordomo@postg resql.org so that your
                message can get through to the mailing list cleanly

                Comment

                • Jerome Lyles

                  #9
                  Re: Where is initdb?

                  How would I check this?
                  Jerome


                  On Monday 26 January 2004 09:43 am, Jeremiah Jahn wrote:[color=blue]
                  > although it will be taken care of, make sure that initdb sets the local
                  > language to C or your string indexes will not be used.. Unless this has
                  > been fixed and en_US works as as well?
                  >
                  > On Mon, 2004-01-26 at 13:32, Peter Eisentraut wrote:[color=green]
                  > > Jerome Lyles wrote:[color=darkred]
                  > > > I have installed Postgresql 7.4 on a Suse 9.0 system using apt.
                  > > > I cannot do this:
                  > > >
                  > > > /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data[/color]
                  > >
                  > > Just run
                  > >
                  > > /etc/init.d/postgresql start
                  > >
                  > > and it will be taken care of. Read the README files in
                  > > /usr/share/doc/packages/postgresql-* to learn about how the packages
                  > > are layed out.
                  > >
                  > >
                  > > ---------------------------(end of broadcast)---------------------------
                  > > TIP 5: Have you checked our extensive FAQ?
                  > >
                  > > http://www.postgresql.org/docs/faqs/FAQ.html[/color][/color]


                  ---------------------------(end of broadcast)---------------------------
                  TIP 8: explain analyze is your friend

                  Comment

                  • Jerome Lyles

                    #10
                    Re: Where is initdb?

                    On Monday 26 January 2004 06:29 pm, Uwe C. Schroeder wrote:[color=blue]
                    > How about
                    >
                    > locate initdb
                    >[/color]
                    It's there now. It turns out I had to also install postgresql-server.
                    [color=blue]
                    > On Monday 26 January 2004 10:37 am, Jerome Lyles wrote:[color=green]
                    > > Hello List,
                    > >
                    > > I have installed Postgresql 7.4 on a Suse 9.0 system using apt.
                    > > I cannot do this:
                    > >
                    > > /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data
                    > >
                    > > Because there is no "/pgsql/bin/initdb" nor /pgsql/bin/ on my system.
                    > > Since apt did not create these directories how can I do it manually?
                    > > Thanks,
                    > > Jerome
                    > >
                    > >
                    > >
                    > > ---------------------------(end of broadcast)---------------------------
                    > > TIP 8: explain analyze is your friend[/color]
                    >
                    > --
                    > UC[/color]


                    ---------------------------(end of broadcast)---------------------------
                    TIP 4: Don't 'kill -9' the postmaster

                    Comment

                    Working...