This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Problems with Cygwin symlinks on a TrueCrypt volume


On Dec  6 15:18, Dr Rainer Woitok wrote:
> Greetings,
> 
> I just happened to stumble over the problem described below.
> 
> Additional information:
> 
>   - Windows Vista, patched this week.
> 
>   - Cygwin updated this week.
> 
>   - TrueCrypt downloaded and installed this week.
> [...]
> $ cd /g
> $ ln -s . xx
> $ ls -nl xx
> lrwxrwxrwx 1 1002 513 1 2013-12-06 11:38 xx -> .
> $ rm xx*
> rm: cannot remove `xx': Permission denied
> $ rm -f xx*
> rm: cannot remove `xx': Permission denied
> $ ls -nl xx*
> lrwxrwxrwx 1 1002 513 1 2013-12-06 11:38 xx -> .
> [...]
> $ attrib -r 'g:\xx.lnk'
> $ rm xx.lnk
> $ ls -nl xx*
> ls: cannot access xx*: No such file or directory
> $ 
> [...]
> I really dont't know whether Windows  or TrueCrypt is incorrectly inter-
> preting  the DOS ReadOnly attribute,  and thus  whose  fault this is.  I
> would simply  suggest to change the code  of the  "rm" command so it ex-
> plicitly removes  the DOS ReadOnly  attribute  before it unlinks any ob-
> ject.

Cygwin's unlink function already removes the R/O attribute if it exists,
because the OS equivalent to the POSIX unlink function refuses to remove
files with the R/O attribute set.  I assume there's some weirdness in the
handling of the R/O attribute in TrueCrypt, but that's just speculation.

What you can do to help this issue along:  The same as above, but run
rm under strace:

  $ strace -o rm.trace rm -f xx

The -f flag drops the interactive prompt.  I added lots of debug output
to the unlink functionality over time, so the rm.trace file should
contain a lot of interesting details as to what's going wrong here.
Just appand the rm.trace file to your next reply.


Thanks,
Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

Attachment: pgppXy9Pmhb9J.pgp
Description: PGP signature


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]