Unix Technical Forum

Re: how to create backup copies

This is a discussion on Re: how to create backup copies within the pgsql Interfaces Pgadmin Support forums, part of the PostgreSQL category; --> > -----Original Message----- > From: pgadmin-support-owner@postgresql.org > [mailto gadmin-support-owner@postgresql.org] On Behalf Of Andrus > Sent: 17 April 2006 16:35 ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Interfaces Pgadmin Support

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-17-2008, 08:24 PM
Dave Page
 
Posts: n/a
Default Re: how to create backup copies



> -----Original Message-----
> From: pgadmin-support-owner@postgresql.org
> [mailtogadmin-support-owner@postgresql.org] On Behalf Of Andrus
> Sent: 17 April 2006 16:35
> To: pgadmin-support@postgresql.org
> Subject: Re: [pgadmin-support] how to create backup copies
>
> > Well, pgAgent creates and deletes the file as it should.

> Can you try
> > it with your AV disabled though please? The log shows some

> interaction
> > between it and pgAgent (though I'm not sure what exactly).

>
> I stopped Symantec antivirus process but the error message is
> still the same.
> Filemon log included.


:-(

Do you mind if I send you a custom built pgagent.exe? I want to remove
the cleanup code in this particular failure case so it leaves the
temporary file/directory behind for examination.

A couple of other things - what OS/service pack level is this, and was
your service user (postgres?) created by the pgInstaller PostgreSQL
distribution? If now, what user rights have your assigned (logon as a
server/batch job etc?).

Regards, Dave.

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

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-17-2008, 08:24 PM
Andrus
 
Posts: n/a
Default Re: how to create backup copies

> Do you mind if I send you a custom built pgagent.exe? I want to remove
> the cleanup code in this particular failure case so it leaves the
> temporary file/directory behind for examination.


Yes, I can run it.

It may be reasonable to add button to Step window which runs the step and
displays output
in window like in backup/restore commands.

> A couple of other things - what OS/service pack level is this,


Microsoft Windows 2000
5.00.2195
Service Pack 4

> and was
> your service user (postgres?) created by the pgInstaller PostgreSQL
> distribution?


I created postgres user manually since pgInstaller does not run from RDP
client
(Magnus wrote in pgsql.general that this issue will be addressed in 8.1.4)

> If now, what user rights have your assigned (logon as a
> server/batch job etc?).


Active Directory "Member Of" page shows that user postgres is member of the
following groups:

Account Operators
MYCOMPANY
Domain Computers
Domain Controllers
Domain Users
Pre-Windows 2000 Compatible Access
Server Operators
Users

Andrus.


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 04-17-2008, 08:24 PM
Andreas Pflug
 
Posts: n/a
Default Re: how to create backup copies

Dave Page wrote:
>
>
> :-(
>
> Do you mind if I send you a custom built pgagent.exe? I want to remove
> the cleanup code in this particular failure case so it leaves the
> temporary file/directory behind for examination.


How about a debug option for that.

Regards,
Andreas

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

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 04-17-2008, 08:24 PM
Andrus
 
Posts: n/a
Default Re: how to create backup copies

> Yes, I can run it.

I entered to the step definition window

c:\mydir\mysubdir\mybackup.bat

and ran pgagent.

1_1.bat file now remains and contains line

c:\mydir\mysubdir\mybackup.bat

I executed from cmd line

runas /user:mydomain\postgres cmd

cd "C:\Document and settings\ postgres\Local Settings\temp\pda48EB.tmp"

1_1.bat


and pg_dump.exe creates backup file


So running 1_1.bat manually as user postgres works OK.

Andrus.


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 04-17-2008, 08:24 PM
Andrus
 
Posts: n/a
Default Re: how to create backup copies

> I entered to the step definition window
>
> c:\mydir\mysubdir\mybackup.bat
>
> and ran pgagent.
>
> 1_1.bat file now remains and contains line
>
> c:\mydir\mysubdir\mybackup.bat
>
> I executed from cmd line
>
> runas /user:mydomain\postgres cmd
>
> cd "C:\Document and settings\ postgres\Local Settings\temp\pda48EB.tmp"
>
> 1_1.bat
>
>
> and pg_dump.exe creates backup file
>
>
> So running 1_1.bat manually as user postgres works OK.


Application log contains

Could'nt execute script C:\DOCUME~1\postgres\.... GetLastError() returned
183, errno = 0

Andrus.


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 04-17-2008, 08:24 PM
Andrus
 
Posts: n/a
Default Re: how to create backup copies


> Application log contains
>
> Could'nt execute script C:\DOCUME~1\postgres\.... GetLastError() returned
> 183, errno = 0


From

http://msdn.microsoft.com/library/de...c_._wpopen.asp

Note If used in a Windows program, the _popen function returns an invalid
file pointer that will cause the program to hang indefinitely. _popen works
properly in a Console application. To create a Windows application that
redirects input and output, see Creating a Child Process with Redirected
Input and Output in the Platform SDK

Andrus.



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 05:50 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
www.UnixAdminTalk.com