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

Re: where are the data and log folders of postgresql 8.3 on debian sid?



On Fri, Dec 05, 2008 at 06:28:03PM -0900, Ken Irving wrote:
> On Sat, Dec 06, 2008 at 10:03:04AM +0800, ????????? wrote:
> > I have installed postgresql 8.3 from debian package, and i'm reading
> > the official document from postgresql, the document says after
> > installing the database, it needs to create data folder and specify
> > log file to initiate the database, like this:
> > ---------------
> > mkdir /usr/local/pgsql/data
> > chown postgres /usr/local/pgsql/data
> > su - postgres
> > /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data
> > /usr/local/pgsql/bin/postgres -D /usr/local/pgsql/data >logfile 2>&1 &
> > -----------------
> > but i cannot find the folder in my debian installation, i think they
> > are at some location else, where is it? thanks

Taking another look at this, the instructions show to create a 
directory for your data owned by the postgres user, and then to
run a couple of commands on it, initdb and postgres.  My guess
would be that those would be found in /usr/bin/ and so in the 
root user's path, but in any case should be in some bin/ directory 
somewhere.  

Some things to try...

    man initdb
    man postgres
    man -k postgres
    dpgk -L PACKAGE_NAME | grep bin/

Or wait a day and use locate initdb, if for some reason you want to know
where it is.  Maybe there's something under /var/, e.g., if the debian
package has configured a default location for the database.

In any case, you're not starting from scratch (as the upstream docs
probably assume), you're using debian!

Ken

-- 
Ken Irving


Reply to: