Re: Porting to Native WindowsNT/2000

From: Ian Lance Taylor <ian(at)airs(dot)com>
To: "Dwayne Miller" <dmiller(at)espgroup(dot)net>
Cc: mlw <markw(at)mohawksoft(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Porting to Native WindowsNT/2000
Date: 2001-09-02 05:08:02
Message-ID: si1ylqrxhp.fsf@daffy.airs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

"Dwayne Miller" <dmiller(at)espgroup(dot)net> writes:

> Well, for one.... I have no idea what cygwin is, or what it does to
> your system, or what security vulnerabilities it might add to your
> system. It comes with alot of stuff that I may or may not need, but
> what components I need to run Postgres is not clear.

Cygwin is a Unix environment for Windows. For information, see
http://cygwin.com/

Cygwin comes with a lot of stuff which you don't need to run Postgres.
Simply having that stuff on your computer will not introduce any
security vulnerabilities if you don't run the programs. Cygwin is
simply a DLL and a bunch of Unix programs. It has no server
component.

In order to build Postgres, you will need the compiler and associated
tools. In order to run all the Postgres commands, you will need the
shell and several of the tools.

In fact, I believe that a cygwin distribution actually comes with
Postgres prebuilt and ready to run.

(To be honest, the idea of worrying about security vulnerabilities on
Windows seems odd to me. If you are honestly worried about security
on your database server, the first step is to stop running Windows.)

> Two.... could Postgres be made more efficient on Windows if it ran
> without cygwin?

Yes. Cygwin adds measurable overhead to all I/O operations, and
obviously a database does a lot of I/O. Postgres employs operations
which are fast on Unix but are very slow on cygwin, such as fork.

As mlw said, porting Postgres to run natively on Windows would be a
significant effort. The forking mechanism it uses currently would
have to be completely rearchitected. The buffer, file manager, and
networking code would have to be rewritten. Off the top of my head,
for a top programmer who is an expert in Unix, Windows, and Postgres,
it might take a year. There would also be a heavy ongoing maintenance
cost to keep up with new Postgres releases.

> Three.... can you start cygwin programs on startup of the system?

Sure. cygwin programs are just Windows programs which use a
particular DLL.

Ian

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Vladimir V. Zolotych 2001-09-02 08:23:23 Need help in composing PostgreSQL query
Previous Message Dwayne Miller 2001-09-02 04:33:31 Re: Porting to Native WindowsNT/2000