Re: PGXLOG variable worthwhile? - Mailing list pgsql-hackers

From Mike Mascari
Subject Re: PGXLOG variable worthwhile?
Date
Msg-id 3D80CEF0.1010900@mascari.com
Whole thread Raw
In response to Re: PGXLOG variable worthwhile?  ("scott.marlowe" <scott.marlowe@ihs.com>)
List pgsql-hackers
I wrote:
> scott.marlowe wrote:>>
>> I wouldn't assume that.  It's been years since I tested it, but back 
>> then, the command line and all program I used could see the link 
>> created by ln that came with the resource kit.  They were distinctly 
>> different from the shortcut type of links, in that they seems 
>> transparent like short cuts in unix generally are.
>>
>> Do you have the resource kit or the gnu utils from it?
> 
> 
> The situation appears to be this:
> 
> 1. Soft links are available on NTFS 5 (2K/XP) as Reparse Points via the 
> DeviceIoControl() function for any application using the standard C 
> library routines.
> 
> 2. Soft links are available on any filesystem under 95/98/ME/NT4/2K/XP 
> as OLE streams (.lnk files) for Shell-aware applications.
> 
> 3. Hard links are available on NTFS 5 (2K/XP) via the CreateHardLink() API.

<snip>

> 4. Hard links are available on NTFS (NT3.1/NT4) via the BackupWrite() 
> API by writing a special stream to the NTFS.

I also believe (I could be wrong) that for directories, the only 
two methods of links are the Soft link methods above. So PGXLOG 
cannot use soft links on a non-XP/2K machine unless it is 
"Shell-Aware". For example, in a cygwin bash command window:

mkdir dir1
ln dir1 dir2 <- Error using Cygwin implementation
ln -s dir1 dir2 <- Creates a Shell short-cut (NT4)
echo "Hello" > dir1/test.txt
cat dir2/test.txt
"Hello" <- Cygwin's cat(bash?) is shell short-cut aware

Now, in a Windows NT command prompt:

notepad dir2\test.txt <- Notepad can't find file
notepad dir2.lnk <- Displays link contents

That means for a native port with a different PGXLOG directory 
running on NT4, the only choice *using links* is to make the 
native port shell short-cut aware.

I could be wrong but I don't think so.

Mike Mascari
mascarm@mascari.com



pgsql-hackers by date:

Previous
From: Thomas Swan
Date:
Subject: Re: OPAQUE and 7.2-7.3 upgrade
Next
From: Tom Lane
Date:
Subject: Re: OPAQUE and 7.2-7.3 upgrade