And there is so much to gain by learning a new system. (It’s hardly a core component of a relational database system, but I can only applaud, because spatial queries are very powerful and look cool.)īecause I’ve not implemented the database part of my project yet, I’ve got nothing to lose by choosing an unfamilar technology except a couple of drunken weekends. SQL Server understands spatial data out the box. tSQLt is open source, but immature.įor spatial support, PostGIS. Compare SQL Compare in the SQL Server world, which is great, but too expensive for personal use.įor a unit testing framework implemented within the database, pgTap. All the PostgreSQL tools are open source.įor source control, builds and schema deployment, apgdiff. For each tool class below, the example tool is just the first I heard a reasonable recommendation for – there is at least one more. I guess you get more options in the open source world. The PostgreSQL community seems at least as active as the SQL Server community in providing these features. When selecting a database platform for my latest data analysis project, I identified the following requirements: automatic source control, simple builds and deployment, easy unit testing, and spatial support, and an affordable total cost. But I’ve always wanted to learn another database system, because I believe knowing more than one will make me a better developer on both platforms. I wrote this before I tried to install PostgreSQL. This was originally posted at the scotunes blog. Posted in regular | Tagged postgresql | Leave a reply Uninstall PostgreSQL cleanly I’ll investigate the script initcluster.vbs to see if I can work out what’s going wrong. The first error could be as a result of the second. initdb: could not change permissions of directory "C:/Program Files/PostgreSQL/9.1/data": Permission denied fixing permissions on existing directory C:/Program Files/PostgreSQL/9.1/data. The second error looks like a permissions issue. Ensuring we can read the path C:Program FilesPostgreSQL9.1 (using icacls) to Sco: This first error looks like it’s passing a bad parameter to icacls. The database cluster initialisation failed. The database cluster initialization failed.įrom the log file: Error running cscript //NoLogo "C:Program FilesPostgreSQL9.1/installer/server/initcluster.vbs" "postgres" "postgres" "****" "C:Program FilesPostgreSQL9.1" "C:Program FilesPostgreSQL9.1data" 5432 "DEFAULT" : Program ended with an error exit code A dialog box appeared at the end of the installation: The installation has failed again, this time with a different set of errors. I uninstalled PostgreSQL and tried again, this time running the installer as Administrator. I assumed the problem was caused by not running the installer with administrative privileges. When I first tried to install PostgreSQL, it failed. But I’ll sleep on it now and persevere tomorrow. So, the syntactically correct parameter is Sco:(NP)RX.Īlmost makes me want to use SQL Server Express instead. Inheritance rights precede perms, and simple perms do not require parenthesis. Inheritance rights may precede either Perm form, and they are applied only to directories: Perm is a permission mask that can be specified in one of the following forms:Ī comma-separated list in parenthesis of specific rights: The command fails with the following error: Invalid parameter "Sco:(RX)(NP)" On my machine, the script invokes the command: icacls "C:Program FilesPostgreSQL9.1" /grant Sco:(RX)(NP) It tries to use the icacls utility to set the correct permissions, but uses the wrong syntax. The install script, initcluster.vbs, is pretty broken. The recommended fix is basically ‘do the installer’s job yourself’. Or alternatively, you can fix up the directory permissions and then manually restart the initcluster.vbs script like this for v9, cscript //NoLogo "/installer/server/initcluster.vbs" "postgres" "postgres" "" "" "" 5432 "DEFAULT" Check your install-postgresql log but it is usually related to permission errors. You may also see related errors show up as The database Cluster initialisation failed during the One Click installer. The installer will set permissions on the install directory but not on parent directories of it. Make sure the PostgreSQL service account has permissions on the directories leading up to the one you have installed into. The PostgreSQL wiki has a helpful section on Common Installation Errors: I’m getting permissions errors when installing/running initdb
0 Comments
Leave a Reply. |