public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* git checkout problem
@ 2009-05-14 15:25 Whitman, Steve
  2009-05-14 19:41 ` Whitman, Steve
  2009-06-30 15:52 ` gauthier
  0 siblings, 2 replies; 3+ messages in thread
From: Whitman, Steve @ 2009-05-14 15:25 UTC (permalink / raw)
  To: cygwin

I've been using git for a few weeks now and recently ran into a problem
that I just can't workaround.  I tried updating to the cygwin 1.7
release hoping that this would fix the issue but it didn't.  I found
that a checkout of a branch "new_file_system" from the master branch (or
vice versa) would result an error that a file can't be unlinked. Below
is the sequence of git commands that I run that cause the problem.  This
is the exact sequence of commands that I run:

	bash-3.2$ git status
	# On branch master
	nothing to commit (working directory clean)
	bash-3.2$ git checkout new_file_system
	error: unable to unlink old
'src/libCpp/device/cdu/readManuData.cpp' (Device or
	resource busy)
	M       src/libCpp/device/cdu/readManuData.cpp
	Switched to branch 'new_file_system'
	bash-3.2$ git status
	# On branch new_file_system
	# Changed but not updated:
	#   (use "git add <file>..." to update what will be committed)
	#   (use "git checkout -- <file>..." to discard changes in
working directory)
	#
	#       modified:   src/libCpp/device/cdu/readManuData.cpp
	#
	no changes added to commit (use "git add" and/or "git commit
-a")
	bash-3.2$ git reset --hard
	HEAD is now at 5d9a836 Merge from CC branch to master
	bash-3.2$ strace -o /c/temp/cygwin17.bug --mask=all git checkout
master
	error: unable to unlink old 'src/libCpp/services/flash.cpp'
(Device or resource
	busy)
	M       src/libCpp/services/flash.cpp
	Switched to branch 'master'
	bash-3.2$ git status
	# On branch master
	# Changed but not updated:
	#   (use "git add <file>..." to update what will be committed)
	#   (use "git checkout -- <file>..." to discard changes in
working directory)
	#
	#       modified:   src/libCpp/services/flash.cpp
	#
	no changes added to commit (use "git add" and/or "git commit
-a")

Here is a portion of the strace log where the file (flash.cpp) is
referenced (the full log is over 1MB which is why I didn't include it):

   34 5526393 [main] git 4640 fhandler_base::open:
(\??\C:\repo\cvs\abc-git\src\libCpp\services\cdu\flashvm46.cpp,
0x100A01)
   58 5526451 [main] git 4640 alloc_sd: uid 11962, gid 11477, attribute
1ED
   34 5526485 [main] git 4640 cygsid::debug_print: alloc_sd: owner SID =
S-1-5-21-30099031-893089305-1333819168-1962 (+)
   34 5526519 [main] git 4640 cygsid::debug_print: alloc_sd: group SID =
S-1-5-21-30099031-893089305-1333819168-1477 (+)
   37 5526556 [main] git 4640 alloc_sd: ACL-Size: 100
   80 5526636 [main] git 4640 alloc_sd: Created SD-Size: 176
  372 5527008 [main] git 4640 fhandler_base::set_flags: flags 0x100A01,
supplied_bin 0x10000
   50 5527058 [main] git 4640 fhandler_base::set_flags: filemode set to
binary
   34 5527092 [main] git 4640 fhandler_base::open: 0 = NtCreateFile
(0x1F0, 40120080,
\??\C:\repo\cvs\abc-git\src\libCpp\services\cdu\flashvm46.cpp, io, NULL,
80, 7, 2, 4020, NULL, 0)
   36 5527128 [main] git 4640 fhandler_base::open: 1 =
fhandler_base::open
(\??\C:\repo\cvs\abc-git\src\libCpp\services\cdu\flashvm46.cpp,
0x100A01)
   67 5527195 [main] git 4640 fhandler_base::open_fs: 1 =
fhandler_disk_file::open
(\??\C:\repo\cvs\abc-git\src\libCpp\services\cdu\flashvm46.cpp, 0xA01)
   37 5527232 [main] git 4640 open: 5 = open
(src/libCpp/services/cdu/flashvm46.cpp, 0xA01)
   35 5527267 [main] git 4640 writev: writev (5, 0x22C424, 1)
   33 5527300 [main] git 4640 fhandler_base::write: binary write
  129 5527429 [main] git 4640 writev: 4874 = write (5, 0x22C424, 1),
errno 2
   35 5527464 [main] git 4640 close: close (5)
   34 5527498 [main] git 4640 fhandler_base::close: closing
'/c/repo/cvs/abc-git/src/libCpp/services/cdu/flashvm46.cpp' handle 0x1F0
  115 5527613 [main] git 4640 close: 0 = close (5)
  177 5527790 [main] git 4640 normalize_posix_path: src
src/libCpp/services/flash.cpp
   37 5527827 [main] git 4640 cwdstuff::get: posix /c/repo/cvs/abc-git
   34 5527861 [main] git 4640 cwdstuff::get: (/c/repo/cvs/abc-git) =
cwdstuff::get (0x10F0008, 32768, 1, 0), errno 0
   34 5527895 [main] git 4640 normalize_posix_path:
/c/repo/cvs/abc-git/src/libCpp/services/flash.cpp = normalize_posix_path
(src/libCpp/services/flash.cpp)
   59 5527954 [main] git 4640 mount_info::conv_to_win32_path:
conv_to_win32_path (/c/repo/cvs/abc-git/src/libCpp/services/flash.cpp)
   49 5528003 [main] git 4640 set_flags: flags: binary (0x2)
   34 5528037 [main] git 4640 mount_info::conv_to_win32_path: src_path
/c/repo/cvs/abc-git/src/libCpp/services/flash.cpp, dst
C:\repo\cvs\abc-git\src\libCpp\services\flash.cpp, flags 0x2, rc 0
   86 5528123 [main] git 4640 symlink_info::check: not a symlink
   53 5528176 [main] git 4640 symlink_info::check: 0 = symlink.check
(C:\repo\cvs\abc-git\src\libCpp\services\flash.cpp, 0x2232B8) (0x2)
   34 5528210 [main] git 4640 path_conv::check:
this->path(C:\repo\cvs\abc-git\src\libCpp\services\flash.cpp),
has_acls(1)
   75 5528285 [main] git 4640 unlink_nt: Opening file for delete failed,
status = 0xC0000043
   31 5528316 [main] git 4640 seterrno_from_win_error:
/ext/build/netrel/src/cygwin-1.7.0-47/winsup/cygwin/syscalls.cc:639
windows error 32
   34 5528350 [main] git 4640 geterrno_from_win_error: windows error 32
== errno 16
   33 5528383 [main] git 4640 __set_errno: void
seterrno_from_win_error(const char*, int, DWORD):318 val 16
   33 5528416 [main] git 4640 unlink: -1 = unlink
(src/libCpp/services/flash.cpp)
  109 5528525 [main] git 4640 fhandler_console::write: 626EB748, 7
   35 5528560 [main] git 4640 fhandler_console::write: at 101(e) state
is 0
  125 5528685 [main] git 4640 fhandler_console::write: 7 =
fhandler_console::write (,..7)
   86 5528771 [main] git 4640 fhandler_console::write: 22C110, 78
   33 5528804 [main] git 4640 fhandler_console::write: at 117(u) state
is 0
  867 5529671 [main] git 4640 fhandler_console::write: 78 =
fhandler_console::write (,..78)
  316 5529987 [main] git 4640 fhandler_console::write: 626EB73C, 1
   35 5530022 [main] git 4640 fhandler_console::write: at 10(0x20) state
is 0
  720 5530742 [main] git 4640 fhandler_console::write: 1 =
fhandler_console::write (,..1)
  184 5530926 [main] git 4640 normalize_posix_path: src
src/libCpp/services/flashimpl.h
  309 5531235 [main] git 4640 cwdstuff::get: posix /c/repo/cvs/abc-git
   78 5531313 [main] git 4640 cwdstuff::get: (/c/repo/cvs/abc-git) =
cwdstuff::get (0x10F0008, 32768, 1, 0), errno 0
   35 5531348 [main] git 4640 normalize_posix_path:
/c/repo/cvs/abc-git/src/libCpp/services/flashimpl.h =
normalize_posix_path (src/libCpp/services/flashimpl.h)
   33 5531381 [main] git 4640 mount_info::conv_to_win32_path:
conv_to_win32_path (/c/repo/cvs/abc-git/src/libCpp/services/flashimpl.h)

 - Steve -


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 3+ messages in thread

* RE: git checkout problem
  2009-05-14 15:25 git checkout problem Whitman, Steve
@ 2009-05-14 19:41 ` Whitman, Steve
  2009-06-30 15:52 ` gauthier
  1 sibling, 0 replies; 3+ messages in thread
From: Whitman, Steve @ 2009-05-14 19:41 UTC (permalink / raw)
  To: cygwin

> I've been using git for a few weeks now and recently ran into a
problem
> that I just can't workaround.  I tried updating to the cygwin 1.7
> release hoping that this would fix the issue but it didn't.  I found
> that a checkout of a branch "new_file_system" from the master branch
(or
> vice versa) would result an error that a file can't be unlinked. Below
> is the sequence of git commands that I run that cause the problem.
This
> is the exact sequence of commands that I run:

I've performed some additional experiments and I'm starting to believe
this is probably not an issue with cygwin (it might be a git on Windows
issue).  I installed the latest version of msysgit (1.6.3.msysgit.0) and
found that I was still having the problem described above.

I'm running Windows Vista w/SP1 with UAC enabled.  I found that if I
turn off UAC the problem went away.  Turn UAC on and the problem
re-appears.  I then tried running bash as an admin and that also seems
to resolve the issue.  Finally I modified the properties of the bash
executable to run in Windows XP w/SP2 compatibility mode and that also
seems to resolve this problem even with UAC enabled and running without
admin privileges.  I'll continue to do some more testing but it appears
that I have a reasonable workaround for this issue.

 - Steve -


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: git checkout problem
  2009-05-14 15:25 git checkout problem Whitman, Steve
  2009-05-14 19:41 ` Whitman, Steve
@ 2009-06-30 15:52 ` gauthier
  1 sibling, 0 replies; 3+ messages in thread
From: gauthier @ 2009-06-30 15:52 UTC (permalink / raw)
  To: cygwin



Whitman, Steve wrote:
> 
> I've been using git for a few weeks now and recently ran into a problem
> that I just can't workaround.  I tried updating to the cygwin 1.7
> release hoping that this would fix the issue but it didn't.  I found
> that a checkout of a branch "new_file_system" from the master branch (or
> vice versa) would result an error that a file can't be unlinked. 

I've had the same problem.
I closed my editor (slickedit), restarted my git bash, and the checkout
worked.

Did you solve your problem?

Hth.
Gauthier
-- 
View this message in context: http://www.nabble.com/git-checkout-problem-tp23542913p24270805.html
Sent from the Cygwin list mailing list archive at Nabble.com.


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2009-06-30 12:12 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-05-14 15:25 git checkout problem Whitman, Steve
2009-05-14 19:41 ` Whitman, Steve
2009-06-30 15:52 ` gauthier

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).