Re: Permission Denied for 'pg_stat_tmp/pgstat.tmp' on Windows server 2003 - postgresql 8.4.6

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

 



Go to the directory in question and have it stop inheriting rights from
the parent (security tab > advanced), let it remove all the permissions
when you apply it, then assign "everyone" full to see if it helps. I
have a feeling it's your AV though since it's happening elsewhere.

Process Monitor:
http://technet.microsoft.com/en-us/sysinternals/bb896645 will help see
if your AV is accessing it if you think that's an issue. Would be
interesting to see what is going on with that file when those errors
start happening. Funky security issues like that aren't normal,
especially if you're having that happen elsewhere. 

I would run postgres as the service account that it creates with the
installer and just make sure the root directories have explicit
permissions for that service account instead of running as
administrator. 

-----Original Message-----
From: pgsql-admin-owner@xxxxxxxxxxxxxx
[mailto:pgsql-admin-owner@xxxxxxxxxxxxxx] On Behalf Of Brian Fehrle
Sent: Wednesday, May 11, 2011 5:54 PM
To: pgsql-admin@xxxxxxxxxxxxxx
Subject:  Permission Denied for 'pg_stat_tmp/pgstat.tmp' on
Windows server 2003 - postgresql 8.4.6

Hi list,
     I've been doing a ton of searching on this issue, but haven't found

any information as to why I'm getting this error, and I'm convinced this

is an issue with Windows Server 2003 (or the antivirus), but thought I'd

try my luck here to see if anyone has seen this problem and knows a fix.

Unfortunately, moving off of windows onto a real OS isn't an option, so 
I need to make due with what I have.

PostgreSQL version: 8.4.6
OS: Windows Server 2003 Web Edition, Service Pack 2 (sorry)
Disk File System: NTFS


In my PostgreSQL server log, I am receiving tons of the following line:
2011-05-11 18:24:30 EDT LOG:  could not open temporary statistics file 
"pg_stat_tmp/pgstat.tmp": Permission denied

And by tons, I mean several hundred per minute. This is odd because the 
file was created by the administrator account, and the database is 
running as the administrator account.

When I try to look at the pg_stat_tmp/pgstat.tmp file's in the windows 
properties GUI, the "security" tab that should be there is nonexistent. 
It's there for any other file, and allows me to set permissions and 
ownerships of the file, but for this one it's gone.

If I reboot the entire machine, this file is no longer locked down like 
this. I've verified that the file can be accessed, is owned by 
administrator and allows all privileges to the administrator account 
before I start the database. When I start the database, everything looks

fine, however within about half an hour, the log file prints out more 
"permission denied" lines and the security tab in the files properties 
disappears.

This behavior has happened to two other files on this server, neither of

which had anything to do with the postgres cluster, so I don't think 
it's bound to just the contents of my postgresql data directory.

I have set up the antivirus (immunet 3.0 - clamav, only one i could find

that would run on a server version of windows for free) to ignore these 
directories and files, however I'm unsure how I could verify that it's 
indeed ignoring these files, or if it is mucking around with them.

This is just one issue of many I have been having while running 
postgresql on Windows Server 2003 (none of them postgres's fault), but 
it's the main one that I haven't developed a workaround for yet. Any 
suggestions, or helpful info is greatly appreciated.

- Brian F

-- 
Sent via pgsql-admin mailing list (pgsql-admin@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

-- 
Sent via pgsql-admin mailing list (pgsql-admin@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux