Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitae61ef3

Browse files
committed
Cleanup -is flag to -l for SSL. Another PERL variable name fix. Clean
up debugging options for postmaster and postgres programs. postmaster-d is no longer optional. Documentation updates.
1 parent5ce158c commitae61ef3

File tree

6 files changed

+46
-39
lines changed

6 files changed

+46
-39
lines changed

‎doc/src/sgml/ref/postmaster.sgml

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!--
2-
$Header: /cvsroot/pgsql/doc/src/sgml/ref/postmaster.sgml,v 1.5 1999/08/06 13:50:31 thomas Exp $
2+
$Header: /cvsroot/pgsql/doc/src/sgml/ref/postmaster.sgml,v 1.6 1999/10/08 04:28:42 momjian Exp $
33
Postgres documentation
44
-->
55

@@ -23,9 +23,9 @@ Postgres documentation
2323
<date>1999-07-20</date>
2424
</refsynopsisdivinfo>
2525
<synopsis>
26-
postmaster [ -B <replaceable class="parameter">nBuffers</replaceable> ] [ -D <replaceable class="parameter">DataDir</replaceable> ] [ -i ]
26+
postmaster [ -B <replaceable class="parameter">nBuffers</replaceable> ] [ -D <replaceable class="parameter">DataDir</replaceable> ] [ -i ] [ -l ]
2727
postmaster [ -B <replaceable class="parameter">nBuffers</replaceable> ] [ -D <replaceable class="parameter">DataDir</replaceable> ] [ -N <replaceable class="parameter">nBackends</replaceable> ] [ -S ]
28-
[ -d [ <replaceable class="parameter">DebugLevel</replaceable> ] [ -i ] [ -o <replaceable class="parameter">BackendOptions</replaceable> ] [ -p <replaceable class="parameter">port</replaceable> ]
28+
[ -d [ <replaceable class="parameter">DebugLevel</replaceable> ] [ -i ] [ -l ] [ -o <replaceable class="parameter">BackendOptions</replaceable> ] [ -p <replaceable class="parameter">port</replaceable> ]
2929
postmaster [ -n | -s ] ...
3030
</synopsis>
3131

@@ -102,7 +102,7 @@ postmaster [ -n | -s ] ...
102102
<term>-d [ <replaceable class="parameter">DebugLevel</replaceable> ]</term>
103103
<listitem>
104104
<para>
105-
The optional argument <replaceable class="parameter">DebugLevel</replaceable>
105+
This argument <replaceable class="parameter">DebugLevel</replaceable>
106106
determines the amount of debugging output the backend servers will
107107
produce.
108108
If <replaceable class="parameter">DebugLevel</replaceable>
@@ -130,6 +130,17 @@ postmaster [ -n | -s ] ...
130130
</listitem>
131131
</varlistentry>
132132

133+
<varlistentry>
134+
<term>-l</term>
135+
<listitem>
136+
<para>
137+
This enables SSL socket communication. The <term>-i</term> option
138+
is also required.
139+
You have to have compiled with SSL enabled to use this option.
140+
</para>
141+
</listitem>
142+
</varlistentry>
143+
133144
<varlistentry>
134145
<term>-o <replaceable class="parameter">BackendOptions</replaceable></term>
135146
<listitem>

‎src/backend/postmaster/postmaster.c

Lines changed: 15 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
*
1111
*
1212
* IDENTIFICATION
13-
* $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.123 1999/10/0802:16:22 vadim Exp $
13+
* $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.124 1999/10/0804:28:43 momjian Exp $
1414
*
1515
* NOTES
1616
*
@@ -412,7 +412,7 @@ PostmasterMain(int argc, char *argv[])
412412
DataDir=getenv("PGDATA");/* default value */
413413

414414
opterr=0;
415-
while ((opt=getopt(nonblank_argc,argv,"A:a:B:b:D:di::m:MN:no:p:Ss"))!=EOF)
415+
while ((opt=getopt(nonblank_argc,argv,"A:a:B:b:D:d:ilm:MN:no:p:Ss"))!=EOF)
416416
{
417417
switch (opt)
418418
{
@@ -459,27 +459,21 @@ PostmasterMain(int argc, char *argv[])
459459
DataDir=optarg;
460460
break;
461461
case'd':
462-
463462
/*
464463
* Turn on debugging for the postmaster and the backend
465464
* servers descended from it.
466465
*/
467-
if ((optind<nonblank_argc)&&*argv[optind]!='-')
468-
{
469-
DebugLvl=atoi(argv[optind]);
470-
optind++;
471-
}
472-
else
473-
DebugLvl=1;
466+
DebugLvl=atoi(optarg);
474467
pg_options[TRACE_VERBOSE]=DebugLvl;
475468
break;
476469
case'i':
477470
NetServer= true;
471+
break;
478472
#ifdefUSE_SSL
479-
if (optarg&& !strcasecmp(optarg,"s"))
480-
SecureNetServer= true;
481-
#endif
473+
case'l':
474+
SecureNetServer= true;
482475
break;
476+
#endif
483477
case'm':
484478
/* Multiplexed backends no longer supported. */
485479
break;
@@ -581,6 +575,12 @@ PostmasterMain(int argc, char *argv[])
581575
}
582576

583577
#ifdefUSE_SSL
578+
if (!NetServer&&SecureNetServer)
579+
{
580+
fprintf(stderr,"For SSL, you must enable TCP/IP connections.\n",
581+
argv[0]);
582+
exit(1);
583+
}
584584
InitSSL();
585585
#endif
586586

@@ -689,7 +689,7 @@ usage(const char *progname)
689689
fprintf(stderr,"\t-d [1|2|3]\tset debugging level\n");
690690
fprintf(stderr,"\t-i \t\tlisten on TCP/IP sockets as well as Unix domain socket\n");
691691
#ifdefUSE_SSL
692-
fprintf(stderr," \t-is\t\tlisten onTCP/IP sockets as above, but only SSL connections\n");
692+
fprintf(stderr," \t-l\t\tforTCP/IP sockets, listen only on SSL connections\n");
693693
#endif
694694
fprintf(stderr,"\t-N nprocs\tset max number of backends (1..%d, default %d)\n",
695695
MAXBACKENDS,DEF_MAXBACKENDS);
@@ -1669,22 +1669,18 @@ BackendStartup(Port *port)
16691669
staticvoid
16701670
split_opts(char**argv,int*argcp,char*s)
16711671
{
1672-
inti=*argcp;
1673-
16741672
while (s&&*s)
16751673
{
16761674
while (isspace(*s))
16771675
++s;
16781676
if (*s=='\0')
16791677
break;
1680-
argv[i++]=s;
1678+
argv[(*argcp)++]=s;
16811679
while (*s&& !isspace(*s))
16821680
++s;
16831681
if (*s)
16841682
*s++='\0';
16851683
}
1686-
1687-
*argcp=i;
16881684
}
16891685

16901686
/*

‎src/backend/tcop/postgres.c

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.131 1999/10/06 21:58:08 vadim Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.132 1999/10/08 04:28:45 momjian Exp $
1111
*
1212
* NOTES
1313
* this is the "main" module of the postgres backend and
@@ -130,7 +130,7 @@ boolExitAfterAbort = false;
130130

131131
externintNBuffers;
132132

133-
staticintEchoQuery=0;/* default don't echo */
133+
staticboolEchoQuery=false;/* default don't echo */
134134
time_ttim;
135135
charpg_pathname[256];
136136
FILE*StatFp;
@@ -901,7 +901,7 @@ PostgresMain(int argc, char *argv[], int real_argc, char *real_argv[])
901901
char*DBDate=NULL;
902902
externintoptind;
903903
externchar*optarg;
904-
externshortDebugLvl;
904+
externintDebugLvl;
905905

906906
/*
907907
* Set default values for command-line options.
@@ -1017,13 +1017,13 @@ PostgresMain(int argc, char *argv[], int real_argc, char *real_argv[])
10171017
break;
10181018

10191019
case'd':/* debug level */
1020-
DebugLvl=(short)atoi(optarg);
1020+
DebugLvl=atoi(optarg);
10211021
if (DebugLvl >=1)
1022-
Verbose=DebugLvl;
1022+
Verbose=true;
10231023
if (DebugLvl >=2)
10241024
DebugPrintQuery= true;
10251025
if (DebugLvl >=3)
1026-
DebugPrintQuery=DebugLvl;
1026+
DebugPrintQuery=true;
10271027
if (DebugLvl >=4)
10281028
{
10291029
DebugPrintParse= true;
@@ -1157,7 +1157,7 @@ PostgresMain(int argc, char *argv[], int real_argc, char *real_argv[])
11571157
*Q - set Quiet mode (reduce debugging output)
11581158
* ----------------
11591159
*/
1160-
Verbose=0;
1160+
Verbose=false;
11611161
break;
11621162

11631163
case'S':
@@ -1443,7 +1443,7 @@ PostgresMain(int argc, char *argv[], int real_argc, char *real_argv[])
14431443
*/
14441444
if (Verbose)
14451445
{
1446-
if (Verbose==1)
1446+
if (Verbose)
14471447
{
14481448
TPRINTF(TRACE_VERBOSE,"started: host=%s user=%s database=%s",
14491449
remote_host,userName,DBName);
@@ -1455,7 +1455,7 @@ PostgresMain(int argc, char *argv[], int real_argc, char *real_argv[])
14551455
TPRINTF(TRACE_VERBOSE,"\tRemoteHost = %s",remote_host);
14561456
TPRINTF(TRACE_VERBOSE,"\tRemotePort = %d",remote_port);
14571457
TPRINTF(TRACE_VERBOSE,"\tDatabaseName = %s",DBName);
1458-
TPRINTF(TRACE_VERBOSE,"\tVerbose= %d",Verbose);
1458+
TPRINTF(TRACE_VERBOSE,"\tDebug Level= %d",DebugLvl);
14591459
TPRINTF(TRACE_VERBOSE,"\tNoversion = %c",Noversion ?'t' :'f');
14601460
TPRINTF(TRACE_VERBOSE,"\ttimings = %c",ShowStats ?'t' :'f');
14611461
TPRINTF(TRACE_VERBOSE,"\tdates = %s",
@@ -1508,7 +1508,7 @@ PostgresMain(int argc, char *argv[], int real_argc, char *real_argv[])
15081508
if (!IsUnderPostmaster)
15091509
{
15101510
puts("\nPOSTGRES backend interactive interface ");
1511-
puts("$Revision: 1.131 $ $Date: 1999/10/06 21:58:08 $\n");
1511+
puts("$Revision: 1.132 $ $Date: 1999/10/08 04:28:45 $\n");
15121512
}
15131513

15141514
/*

‎src/backend/utils/init/globals.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/utils/init/globals.c,v 1.37 1999/09/27 20:27:09 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/utils/init/globals.c,v 1.38 1999/10/08 04:28:48 momjian Exp $
1111
*
1212
* NOTES
1313
* Globals used all over the place should be declared here and not
@@ -63,7 +63,7 @@ boolTransactionInitWasProcessed = false;
6363

6464
boolIsUnderPostmaster= false;
6565

66-
shortDebugLvl=0;
66+
intDebugLvl=0;
6767

6868
intDateStyle=USE_POSTGRES_DATES;
6969
boolEuroDates= false;

‎src/include/miscadmin.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
*
1212
* Copyright (c) 1994, Regents of the University of California
1313
*
14-
* $Id: miscadmin.h,v 1.43 1999/10/06 21:58:13 vadim Exp $
14+
* $Id: miscadmin.h,v 1.44 1999/10/08 04:28:52 momjian Exp $
1515
*
1616
* NOTES
1717
* some of the information in this file will be moved to
@@ -59,7 +59,7 @@ extern bool TransactionInitWasProcessed;
5959

6060
externboolIsUnderPostmaster;
6161

62-
externshortDebugLvl;
62+
externintDebugLvl;
6363

6464
/* Date/Time Configuration
6565
*

‎src/interfaces/Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
#
88
#
99
# IDENTIFICATION
10-
# $Header: /cvsroot/pgsql/src/interfaces/Makefile,v 1.26 1999/10/0800:15:49 momjian Exp $
10+
# $Header: /cvsroot/pgsql/src/interfaces/Makefile,v 1.27 1999/10/0804:28:57 momjian Exp $
1111
#
1212
#-------------------------------------------------------------------------
1313

@@ -50,7 +50,7 @@ perl5/Makefile: perl5/Makefile.PL
5050

5151
install-perl5: perl5/Makefile
5252
$(MAKE) -C perl5 clean
53-
cd perl5&& POSTGRES_HOME="$(POSTGRESDIR)"perl Makefile.PL
53+
cd perl5&& POSTGRES_HOME="$(POSTGRESDIR)"$(PERL) Makefile.PL
5454
$(MAKE) -C perl5 all
5555
@if [-w`sed -n -e's/^ *INSTALLSITELIB *= *//p' perl5/Makefile` ];then\
5656
$(MAKE)$(MFLAGS) -C perl5 install;\

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp