Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
74a263ed
Commit
74a263ed
authored
Sep 27, 1999
by
Bruce Momjian
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix to give super user and createdb user proper update catalog rights.
parent
30659d43
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
36 additions
and
6 deletions
+36
-6
doc/FAQ_Solaris
doc/FAQ_Solaris
+25
-2
src/backend/commands/user.c
src/backend/commands/user.c
+4
-2
src/bin/createuser/createuser.sh
src/bin/createuser/createuser.sh
+7
-2
No files found.
doc/FAQ_Solaris
View file @
74a263ed
...
@@ -3,7 +3,7 @@ Frequently Asked Questions (FAQ) for PostgreSQL V6.5
...
@@ -3,7 +3,7 @@ Frequently Asked Questions (FAQ) for PostgreSQL V6.5
Sun Solaris Specific
Sun Solaris Specific
TO BE READ IN CONJUNCTION WITH THE NORMAL FAQ
TO BE READ IN CONJUNCTION WITH THE NORMAL FAQ
=======================================================
=======================================================
last updated: Thu Sep 2
11:4
0:00 CET 1999
last updated: Thu Sep 2
1 9:3
0:00 CET 1999
current maintainer: Marc Liyanage (liyanage@access.ch)
current maintainer: Marc Liyanage (liyanage@access.ch)
original author: Marc Liyanage (liyanage@access.ch)
original author: Marc Liyanage (liyanage@access.ch)
...
@@ -19,6 +19,10 @@ Contents:
...
@@ -19,6 +19,10 @@ Contents:
1.4) Why am I getting "Can't tell what username to use" errors
1.4) Why am I getting "Can't tell what username to use" errors
when I try to run initdb?
when I try to run initdb?
A) Contributors
Notes:
Notes:
- The commands given here are for the bash shell. If you use
- The commands given here are for the bash shell. If you use
...
@@ -125,7 +129,7 @@ maximum segment size kernel parameter is set too low. The solution
...
@@ -125,7 +129,7 @@ maximum segment size kernel parameter is set too low. The solution
is to put something like the following line into /etc/system and
is to put something like the following line into /etc/system and
reboot the system.
reboot the system.
set shmsys:shminfo_shmmax=0x
f
fffffff
set shmsys:shminfo_shmmax=0x
7
fffffff
Excellent info regarding shared memory under Solaris can be found here:
Excellent info regarding shared memory under Solaris can be found here:
http://www.sunworld.com/swol-09-1997/swol-09-insidesolaris.html
http://www.sunworld.com/swol-09-1997/swol-09-insidesolaris.html
...
@@ -140,3 +144,22 @@ Put something like this into the .bash_profile startup script
...
@@ -140,3 +144,22 @@ Put something like this into the .bash_profile startup script
of the postgres user (see also step 17 in the INSTALL file):
of the postgres user (see also step 17 in the INSTALL file):
export USER=postgres
export USER=postgres
----------------------------------------------------------------------
Section A: Contributors
----------------------------------------------------------------------
- Jose Luis Rodriguez Garcia
Suggested to change the shmmax parameter in 1.3 from 0xffffffff to 0x7fffffff
because the value is a signed integer in Solaris versions prior to 2.6.
src/backend/commands/user.c
View file @
74a263ed
...
@@ -5,7 +5,7 @@
...
@@ -5,7 +5,7 @@
*
*
* Copyright (c) 1994, Regents of the University of California
* Copyright (c) 1994, Regents of the University of California
*
*
* $Id: user.c,v 1.3
4 1999/09/18 19:06:41 tgl
Exp $
* $Id: user.c,v 1.3
5 1999/09/27 16:44:50 momjian
Exp $
*
*
*-------------------------------------------------------------------------
*-------------------------------------------------------------------------
*/
*/
...
@@ -172,12 +172,14 @@ DefineUser(CreateUserStmt *stmt, CommandDest dest)
...
@@ -172,12 +172,14 @@ DefineUser(CreateUserStmt *stmt, CommandDest dest)
snprintf
(
sql
,
SQL_LENGTH
,
snprintf
(
sql
,
SQL_LENGTH
,
"insert into %s (usename,usesysid,usecreatedb,usetrace,"
"insert into %s (usename,usesysid,usecreatedb,usetrace,"
"usesuper,usecatupd,passwd,valuntil) "
"usesuper,usecatupd,passwd,valuntil) "
"values('%s',%d,'%c','f','%c','
f
',%s%s%s,%s%s%s)"
,
"values('%s',%d,'%c','f','%c','
%c
',%s%s%s,%s%s%s)"
,
ShadowRelationName
,
ShadowRelationName
,
stmt
->
user
,
stmt
->
user
,
max_id
+
1
,
max_id
+
1
,
(
stmt
->
createdb
&&
*
stmt
->
createdb
)
?
't'
:
'f'
,
(
stmt
->
createdb
&&
*
stmt
->
createdb
)
?
't'
:
'f'
,
(
stmt
->
createuser
&&
*
stmt
->
createuser
)
?
't'
:
'f'
,
(
stmt
->
createuser
&&
*
stmt
->
createuser
)
?
't'
:
'f'
,
((
stmt
->
createdb
&&
*
stmt
->
createdb
)
||
(
stmt
->
createuser
&&
*
stmt
->
createuser
))
?
't'
:
'f'
,
havepassword
?
"'"
:
""
,
havepassword
?
"'"
:
""
,
havepassword
?
stmt
->
password
:
"NULL"
,
havepassword
?
stmt
->
password
:
"NULL"
,
havepassword
?
"'"
:
""
,
havepassword
?
"'"
:
""
,
...
...
src/bin/createuser/createuser.sh
View file @
74a263ed
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
#
#
#
#
# IDENTIFICATION
# IDENTIFICATION
# $Header: /cvsroot/pgsql/src/bin/createuser/Attic/createuser.sh,v 1.1
2 1999/07/30 18:09:49
momjian Exp $
# $Header: /cvsroot/pgsql/src/bin/createuser/Attic/createuser.sh,v 1.1
3 1999/09/27 16:44:56
momjian Exp $
#
#
# Note - this should NOT be setuid.
# Note - this should NOT be setuid.
#
#
...
@@ -215,10 +215,15 @@ then
...
@@ -215,10 +215,15 @@ then
fi
fi
fi
fi
if
[
"
$CANCREATE
"
=
"t"
-o
"
$CANADDUSER
"
=
"t"
]
then
CANCATUPD
=
"t"
else
CANCATUPD
=
"f"
fi
QUERY
=
"insert into pg_shadow
\
QUERY
=
"insert into pg_shadow
\
(usename, usesysid, usecreatedb, usetrace, usesuper, usecatupd)
\
(usename, usesysid, usecreatedb, usetrace, usesuper, usecatupd)
\
values
\
values
\
('
$NEWUSER
',
$SYSID
, '
$CANCREATE
', 'f', '
$CANADDUSER
','
f
')"
('
$NEWUSER
',
$SYSID
, '
$CANCREATE
', 'f', '
$CANADDUSER
','
$CANCATUPD
')"
RES
=
`
$PSQL
-c
"
$QUERY
"
template1
`
RES
=
`
$PSQL
-c
"
$QUERY
"
template1
`
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment