initDB - storage manager issues - Mailing list pgsql-novice

From Tareq Aljabban
Subject initDB - storage manager issues
Date
Msg-id CAGOe0a+WqACpOGjGJNqpMUbODDuoeGKSAKVzUKKynLvT09OH3Q@mail.gmail.com
Whole thread Raw
Responses Re: initDB - storage manager issues  ("Daniel Staal" <DStaal@usa.net>)
List pgsql-novice

I'm writing two alternative storage managers for PostgreSQL. The first implementation worked well. I had a different way of splitting the data over the files, than how the original PG implementation stored them. My first implementation stored files locally in the same table space used by the original implementation.

In the second storage manager implementation, I'm trying to store files on a remote file system, instead of the local one. I'm following the exact same logic followed in the first implementation. However, when running initDB(), I'm getting the following exception:


WARNING:  no roles are defined in this database system
HINT
:  You should immediately run CREATE USER "ticker23" SUPERUSER;.
FATAL
:  database "template1" does not exist
child process exited
with exit code 1

This exception is thrown at the function: setup_auth in initdb.c when trying to execute the command:


REVOKE ALL on pg_authid FROM public

I don't know what's happening exactly in this command, but apparently the needed data cannot be accessed for some reasons.

Two important notes:

  1. I debugged the application and found that the storage manager is not even involved when executing this 'revoke all' command.

  2. Some module other than the storage manager is accessing the file system. For example the storage manager creates only the folder base/1 (under base), but when the execution finishes I find two other folders: base/11818 and base/11826. The code that does this copying clearly doesn't do any data processing as it happened also for my local implementation where files had totally different formatting from the one of the original storage managers.

Where are the local files accessed other than the storage manager?

Any ideas on what is going wrong, and how I can fix it is appreciated.

pgsql-novice by date:

Previous
From: Daniel Staal
Date:
Subject: Re: Restoring selected records from backup file
Next
From: Anatole Laffreux
Date:
Subject: Paging results from a query