Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
postgres-lambda-diff
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jakob Huber
postgres-lambda-diff
Commits
4504a1bc
Commit
4504a1bc
authored
15 years ago
by
Bruce Momjian
Browse files
Options
Downloads
Patches
Plain Diff
On Win32, pg_upgrade cannot sent any server log output to the log file
because of file access limitations on that platform.
parent
477c01b0
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
contrib/pg_upgrade/server.c
+9
-9
9 additions, 9 deletions
contrib/pg_upgrade/server.c
with
9 additions
and
9 deletions
contrib/pg_upgrade/server.c
+
9
−
9
View file @
4504a1bc
...
@@ -4,7 +4,7 @@
...
@@ -4,7 +4,7 @@
* database server functions
* database server functions
*
*
* Copyright (c) 2010, PostgreSQL Global Development Group
* Copyright (c) 2010, PostgreSQL Global Development Group
* $PostgreSQL: pgsql/contrib/pg_upgrade/server.c,v 1.
8
2010/07/
06 19:18:55
momjian Exp $
* $PostgreSQL: pgsql/contrib/pg_upgrade/server.c,v 1.
9
2010/07/
13 20:03:32
momjian Exp $
*/
*/
#include
"pg_upgrade.h"
#include
"pg_upgrade.h"
...
@@ -181,9 +181,9 @@ start_postmaster(migratorContext *ctx, Cluster whichCluster, bool quiet)
...
@@ -181,9 +181,9 @@ start_postmaster(migratorContext *ctx, Cluster whichCluster, bool quiet)
}
}
/*
/*
* On Win32, we can't send both
server
output and pg_ctl output to the
* On Win32, we can't send both
pg_upgrade
output and pg_ctl output to the
* same file because we get the error: "The process cannot access the file
* same file because we get the error: "The process cannot access the file
* because it is being used by another process." so we have to send
pg_ctl
* because it is being used by another process." so we have to send
all other
* output to 'nul'.
* output to 'nul'.
*/
*/
snprintf
(
cmd
,
sizeof
(
cmd
),
snprintf
(
cmd
,
sizeof
(
cmd
),
...
@@ -191,11 +191,11 @@ start_postmaster(migratorContext *ctx, Cluster whichCluster, bool quiet)
...
@@ -191,11 +191,11 @@ start_postmaster(migratorContext *ctx, Cluster whichCluster, bool quiet)
"-o
\"
-p %d -c autovacuum=off "
"-o
\"
-p %d -c autovacuum=off "
"-c autovacuum_freeze_max_age=2000000000
\"
"
"-c autovacuum_freeze_max_age=2000000000
\"
"
"start >>
\"
%s
\"
2>&1"
SYSTEMQUOTE
,
"start >>
\"
%s
\"
2>&1"
SYSTEMQUOTE
,
bindir
,
ctx
->
logfile
,
datadir
,
port
,
bindir
,
#ifndef WIN32
#ifndef WIN32
ctx
->
logfile
);
ctx
->
logfile
,
datadir
,
port
,
ctx
->
logfile
);
#else
#else
DEVNULL
);
DEVNULL
,
datadir
,
port
,
DEVNULL
);
#endif
#endif
exec_prog
(
ctx
,
true
,
"%s"
,
cmd
);
exec_prog
(
ctx
,
true
,
"%s"
,
cmd
);
...
@@ -235,11 +235,11 @@ stop_postmaster(migratorContext *ctx, bool fast, bool quiet)
...
@@ -235,11 +235,11 @@ stop_postmaster(migratorContext *ctx, bool fast, bool quiet)
snprintf
(
cmd
,
sizeof
(
cmd
),
snprintf
(
cmd
,
sizeof
(
cmd
),
SYSTEMQUOTE
"
\"
%s/pg_ctl
\"
-l
\"
%s
\"
-D
\"
%s
\"
%s stop >> "
SYSTEMQUOTE
"
\"
%s/pg_ctl
\"
-l
\"
%s
\"
-D
\"
%s
\"
%s stop >> "
"
\"
%s
\"
2>&1"
SYSTEMQUOTE
,
"
\"
%s
\"
2>&1"
SYSTEMQUOTE
,
bindir
,
ctx
->
logfile
,
datadir
,
fast
?
"-m fast"
:
""
,
bindir
,
#ifndef WIN32
#ifndef WIN32
ctx
->
logfile
);
ctx
->
logfile
,
datadir
,
fast
?
"-m fast"
:
""
,
ctx
->
logfile
);
#else
#else
DEVNULL
);
DEVNULL
,
datadir
,
fast
?
"-m fast"
:
""
,
DEVNULL
);
#endif
#endif
exec_prog
(
ctx
,
fast
?
false
:
true
,
"%s"
,
cmd
);
exec_prog
(
ctx
,
fast
?
false
:
true
,
"%s"
,
cmd
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment