Skip site navigation (1) Skip section navigation (2)

Postgres service user keeps losing password

From: "Karim Mardhani" <karim(at)zeecore(dot)net>
To: <pgsql-admin(at)postgresql(dot)org>
Subject: Postgres service user keeps losing password
Date: 2005-07-13 05:47:54
Message-ID: 003801c5876e$6a40ef80$0200a8c0@ipsolution1 (view raw, whole thread or download thread mbox)
Lists: pgsql-admin
Hi All:

I am having an interesting problem with the user which starts postmaster as service.

I am using postgres 8.0.1 as backend to my stand alone windows application.  My installation program installs postgres in silent mode and sets it to start as windows service.  Before installing postgres my installation program creates a user by running following script:

net user /add /y postgres mypassword /EXPIRES:NEVER /COMMENT:"PostgreSQL Service Account" /FULLNAME:"Postgres Service Account" 
ntrights -u postgres +r SeServiceLogonRight
ntrights -u postgres +r SeNetworkLogonRight
ntrights -u postgres +r SeInteractiveLogonRight

 After creating the user the installation program installs postgres as windows service by using following command:

So this works fine till the end user actually power cycles the PC rather than shutting it down properly from the start menu.  Basically when the windows starts up after the power cycle the postgres service doesn't start.  The error it gives is 1069 "logon failure".  The only way to fix this is to reset the passward for the user "postgres" to "mypassword" and after that every thing works fine till next power cycle happens.  This has been seen on both windows 2000 and windows xp.  Also I can't even use NET USER command to reset the password.  The password must be reset from "users and password" GUI.

So the question I have is why a power cycle causes the system to lose the passward for this user?  It doesn't happen to any other user.  There are quite a few other users in the system.  Also why can't "net user" utility be used to reset the password.  Does anybody see any thing obvious with the way installation program creates the user?

Any help in this regard would greatly appreciated.



pgsql-admin by date

Next:From: Devrim GUNDUZDate: 2005-07-13 06:27:19
Subject: Re: Help for postgresql binary installation v.8.0.3
Previous:From: Joel FradkinDate: 2005-07-13 04:04:57
Subject: got my odbc working(re-loaded mdac as well as postgres) but it started working after I added a dsn (not using a dsn connection though so odd)

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group