I was getting an error while developing a Windows application that is to run on several machines at once.
It was being built on one machine and then shared via network share and loaded over the network and run in the memory space of a test machine, no special deployments or publishing.
Clearly if a machine is running the application it is going to probably lock some files over the network. As it happens I'm developing this in an AWS VPC, but that is not so relevant only to excuse the mistake.
I shutdown the AWS instance running the app over the network to release any locks. So I try to build the application on the local machine and it fails with error:
unable tocopy exe-file from obj\debug to bin\debug
So I think, this is wierd. Anyway I look on the local machine and it is one of the build files, a .dll that is locked. I think, so the network machine must have failed to release the lock or something as I shut it down.
I drop to DOS, because I'm old, and do a DIR /Q This shows the file ownership:
How wierd is that? All the other files are like you'd expect, except this one has an owner of just three dots. ... Something messed up my NTFS disk partition for sure I think.
OK. Well it is my file, and it is on my disk so I'm going to have it!
So I right-click the file and properties.
OK so I need read properties... Like explained here.
But what happens??? I don't believe it!
I need Read Permissions again, yes OK, I click Continue. And what pops up???
I don't permission to view this object's security properties - EVEN as an administrative user. Wow - that's pretty heaving going seeing as I paid a lot of money for this computer. Who else is going to have permissions on this object?!
Anyway then I proceed to look at - lots and lots of "solutions", no-one if which come close, or the usual "huh, rebooting 'solved' it for me".....
Just about to switch off and go and have a beer. When I notice the AWS instances were on "Spot Requests" - the first time I'd tried this - and the bugger had come back up and was locking the file over the network again.
So... if you see those 3 dots, or can't take ownership check no pesky machine has taken a lock on your file over the network.
© 2004 - 2019 1 Oak Hill Grove Surbiton Surrey KT6 6DS Phone: +44(020)82617371