Page 1 of 2

postgres service wont start

PostPosted: Fri Apr 25, 2008 6:57 pm
by mattgoody
This is the 2nd time this has happened. The first time i reinstalled pgsql 8.3 but since it happened again, and im planning on using the computer it happens on as a poker db server, i figured i would try to figure out what the problem was. Anyway, today when i tried to open PT3 the log file said it could not connect to the db so i checked it out and the postgres service was not running. I tried to start it but after about 2 minutes it gave me the message "The PostgreSQL Database Server 8.3 service on Local Computer started and then stopped. Some services stop automatically if they have no work to do, for example, the Performance Logs and Alerts service." The status in the services window is blank and if i open the services window right after i log into windows, the status says "Starting" but then i refresh and it goes blank. Im running XP 64bit. Oh, and i think this MIGHT happen only after like power outages, not sure if that would matter at all. If the only solution is reinstalling pg so be it, just looking for suggestions.

Thanks,
Matt

O yeah, no postgres.exe processes are running obv.

Re: postgres service wont start

PostPosted: Sat Apr 26, 2008 10:31 am
by mattgoody
I checked the application logs and found that this error happens everytime i try to start the service:
2008-04-26 14:27:15 GMT FATAL: data directory "C:/WINDOWS/system32/ConfigDir" does not exist
I created the directory, but the same error still happens. Any ideas?

Re: postgres service wont start

PostPosted: Sat Apr 26, 2008 11:51 am
by APerfect10
Did you manually install PostgreSQL? It sounds like it did not install properly and is looking for your database in the default ConfigDir whereas it should be located in your /PostgreSQl/<version>/data/base directory...

Is PostgreSQL working at all? That error message makes it seem like it would not work...

Best regards,

Derek

Re: postgres service wont start

PostPosted: Sat Apr 26, 2008 1:01 pm
by mattgoody
It is not working at all. It was working tho and suddenly started giving me this error. I did make a custom tablespace in a seperate drive where my poker dbs are. Is there anyway to tell it to look somewhere else?

Edit: Ok i fixed it. Somehow in my postgres.conf file the location of the data directory and config files were set to 'ConfigDir' . I have no idea why or how this happened and i definitely did not do it myself. Thanks for pointing me in the right direction!

-Matt

Re: postgres service wont start

PostPosted: Sun Apr 27, 2008 12:47 am
by APerfect10
mattgoody wrote:It is not working at all. It was working tho and suddenly started giving me this error. I did make a custom tablespace in a seperate drive where my poker dbs are. Is there anyway to tell it to look somewhere else?

Edit: Ok i fixed it. Somehow in my postgres.conf file the location of the data directory and config files were set to 'ConfigDir' . I have no idea why or how this happened and i definitely did not do it myself. Thanks for pointing me in the right direction!

-Matt


Well the 'ConfigDir' is the default location for your database; however, when you run initdb (through the installer) it creates your data directory where I mentioned in my previous post. If you manually ran initdb and did not provide a directory than PostgreSQL would try to use the default ConfigDir. I am not sure where things went wrong for you...

-Derek

Re: postgres service wont start

PostPosted: Tue Jun 24, 2008 4:21 am
by Wildebeest
my postgres service wont start and in my config file it says
FILE LOCATIONS
#------------------------------------------------------------------------------

# The default values of these variables are driven from the -D command-line
# option or PGDATA environment variable, represented here as ConfigDir.

#data_directory = 'ConfigDir' # use data in another directory
# (change requires restart)
#hba_file = 'ConfigDir/pg_hba.conf' # host-based authentication file
# (change requires restart)
#ident_file = 'ConfigDir/pg_ident.conf' # ident configuration file
# (change requires restart)

# If external_pid_file is not explicitly set, no extra PID file is written.
#external_pid_file = '(none)' # write an extra PID file
# (change requires restart)

is there anything wrong with having 'configdir'...cause i didnt understand what was said above

Re: postgres service wont start

PostPosted: Tue Jun 24, 2008 4:45 am
by tarix
APerfect10 wrote:Well the 'ConfigDir' is the default location for your database; however, when you run initdb (through the installer) it creates your data directory where I mentioned in my previous post. If you manually ran initdb and did not provide a directory than PostgreSQL would try to use the default ConfigDir. I am not sure where things went wrong for you...


For what it is worth ... My experience has been that allowing PokerTracker to install Postgres for me has been disastrous. The only way I got things working was to install it myself and then hook PT2 and PT3 to it. If I did it any other way everything would always break. (For example installing PT3 would break PT2. Installing PT2 would break PT3. And upgrading would break them both! :shock: )

Re: postgres service wont start

PostPosted: Tue Jun 24, 2008 6:40 pm
by jrmoneyloser
I'm running Vista and can't for the life of me get postgres to startup. When I Start>PostgreSQL 8.3>'start up service' as administrator, it brings up Start Service window, with "The PostgreSQL Server 8.3 service is starting.....................................................". It then proceeds to simply close after about 90 seconds. When looking at msconfig>Services, it says 'Start Pending' after I try to start it (it is also Start Pending on startup), but it always ends up with a "Stopped" status and won't run. Is this a common problem with an easy fix?

Re: postgres service wont start

PostPosted: Tue Jun 24, 2008 8:09 pm
by keggler
jrmoneyloser wrote:I'm running Vista and can't for the life of me get postgres to startup. When I Start>PostgreSQL 8.3>'start up service' as administrator, it brings up Start Service window, with "The PostgreSQL Server 8.3 service is starting.....................................................". It then proceeds to simply close after about 90 seconds. When looking at msconfig>Services, it says 'Start Pending' after I try to start it (it is also Start Pending on startup), but it always ends up with a "Stopped" status and won't run. Is this a common problem with an easy fix?



you need to look in the operating system's event log to see why the postgres service isn't starting - it maybe a lock on a folder or registry key that another application is holding that's preventing postgres from getting going...


susan

Re: postgres service wont start

PostPosted: Tue Jun 24, 2008 9:50 pm
by jrmoneyloser
Well, navigating thru the system log if new to me, but I did find 16 event errors listed for postgreSQL, all of which read:

"FATAL: bogus data in lock file "postmaster.pid": "

I'm giong to continue searching for solutions for this error.