Sample Exam Questions

From the objective of OSS-DB Exam Silver
- Operation management - Installation method

Sample Question

1.37

Choose all of the correct descriptions for creating a new database cluster.

  1. It can be created from the psql command by executing the CREATE CLUSTER statement.
  2. It can be created by executing the initdb command from the OS command prompt.
  3. You can create it by executing the pg_ctl initdb command from the OS command prompt.
  4. For security reasons, files to be created are not permitted to be read except by the user who executed the command.
  5. For security reasons, OS administrator user (root on Linux) should create it.

※This sample exam is different from those that appear in the actual OSS-DB Exam.
2019/05/21

Answer and Explanation

To create a new database cluster, run the initdb command from the OS command prompt. Alternatively, you can create it by specifying the initdb option with the pg_ctl command.

For security reasons, database clusters can not read or write except for the user (database administrator user who executed initdb) who created the database cluster.  Permissions on Linux are set to 600 for all files and 700 for all directories. Of course, other users can also read and write data in the database using the psql command etc. However, this is realized by communicating with a server program that operates under the authority of the database administrator user.

Database administration commands such as initdb and pg_ctl do not operate under the authority of the OS administrator user (root). In Linux, the root user can execute the database management command using the init script, but internally, after switching to the permission of the postgres user, the pg_ctl command is issued.

Therefore, the correct answer is B, C, D.