Forum Menu




 


Log in Problems?
New User? Sign Up!
AVR Freaks Forum Index

Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Author Message
microcarl
PostPosted: Sep 06, 2008 - 05:21 AM
Raving lunatic


Joined: May 30, 2004
Posts: 8118
Location: Cincinnati, Ohio

dak664 wrote:
Maybe you aren't logged in as administrator?


Yes, I am the only administrator and user on this notebook. If I wasn't, I'd be in really deep do-do...

_________________
Carl W. Livingston, KC5OTL
microcarl@roadrunner.com

"There are only two ways to sleep well at night... be ignorant or be prepared."

The original Dragon Slayer !

Long live the AVR!!!
 
 View user's profile Send private message Send e-mail  
Reply with quote Back to top
microcarl
PostPosted: Sep 06, 2008 - 05:24 AM
Raving lunatic


Joined: May 30, 2004
Posts: 8118
Location: Cincinnati, Ohio

cpluscon wrote:
Openfiles is NOT available on my machine running XP Home, but is under XP Pro....

Yes, I'm running XP Home on this machine, as well. I'll have to check the XP Professional machines and see if it works with them.

_________________
Carl W. Livingston, KC5OTL
microcarl@roadrunner.com

"There are only two ways to sleep well at night... be ignorant or be prepared."

The original Dragon Slayer !

Long live the AVR!!!
 
 View user's profile Send private message Send e-mail  
Reply with quote Back to top
emuler
PostPosted: Sep 06, 2008 - 05:48 AM
Raving lunatic


Joined: Feb 07, 2007
Posts: 2395
Location: New Delhi, India

Isn't openfiles for seeing which shared files are open? Might not even be applicable in the OP's case.

_________________
If you think education is expensive, try ignorance.
 
 View user's profile Send private message  
Reply with quote Back to top
microcarl
PostPosted: Sep 06, 2008 - 05:55 AM
Raving lunatic


Joined: May 30, 2004
Posts: 8118
Location: Cincinnati, Ohio

Ah! If I type in:
Code:
CMD filesopen /?

a DOS window opens and I get a list of command switches. So that's it, I wasn't preceding "filesopen " with the CMD instruction.

Thanks all for your help.

_________________
Carl W. Livingston, KC5OTL
microcarl@roadrunner.com

"There are only two ways to sleep well at night... be ignorant or be prepared."

The original Dragon Slayer !

Long live the AVR!!!
 
 View user's profile Send private message Send e-mail  
Reply with quote Back to top
JohanEkdahl
PostPosted: Sep 06, 2008 - 12:46 PM
10k+ Postman


Joined: Mar 27, 2002
Posts: 18583
Location: Lund, Sweden

Good-morning all! (Yes, I had a bit of a sleep in, as it's Saturday).
Isn't it the loveliest thing to post and go to sleep, and when you wake up you have a lot of read up on, and hopefully a solution.

I think I see what openfiles is about, reading your descriptions. It seems to be a monitor that is hooked in somewhere between two OS layers. Isn't it amazing that this isnt't there in the first place. What operating system does not keep track of which resources (as eg an open file) is allocated to which process?! Windows, I presume...

Anyhow, heaps of thanks! I will turn off caching. I will try openfiles. I will try unlocker.

Thank you for the thrash can tip, Jim, but I am in the habit of trying to make sure mentally that I really want to delete a file and then its shift-del. Pooof!
 
 View user's profile Send private message Visit poster's website 
Reply with quote Back to top
emuler
PostPosted: Sep 06, 2008 - 01:17 PM
Raving lunatic


Joined: Feb 07, 2007
Posts: 2395
Location: New Delhi, India

Quote:

Thank you for the thrash can tip, Jim, but I am in the habit of trying to make sure mentally that I really want to delete a file and then its shift-del. Pooof!

As long as it isn't Shift-del. Pooof! Oh crap! Rolling Eyes

_________________
If you think education is expensive, try ignorance.
 
 View user's profile Send private message  
Reply with quote Back to top
svofski
PostPosted: Sep 06, 2008 - 05:10 PM
Raving lunatic


Joined: Jun 27, 2005
Posts: 3412
Location: St.Petersburg, Russia

Usually when a device is locked and you don't see an obvious offender, it's explorer.exe. Don't be afraid to restart it.

_________________
The Dark Boxes are coming.
 
 View user's profile Send private message Visit poster's website 
Reply with quote Back to top
emuler
PostPosted: Sep 06, 2008 - 06:31 PM
Raving lunatic


Joined: Feb 07, 2007
Posts: 2395
Location: New Delhi, India

Restarting explorer.exe always loses a few of my system tray icons. Sad I currently have 18 icons sitting there - restarting explorer will result in about 15 icons visible. The apps will still be running, but just not accessible through the tray. Razz

_________________
If you think education is expensive, try ignorance.
 
 View user's profile Send private message  
Reply with quote Back to top
JohanEkdahl
PostPosted: Sep 06, 2008 - 07:57 PM
10k+ Postman


Joined: Mar 27, 2002
Posts: 18583
Location: Lund, Sweden

Quote:

Restarting explorer.exe always loses a few of my system tray icons.

Not much comfort, but that can not be blamed on Explorer. The API for the System Tray includes a callback from Explorer to the tray application which essentially tells the app that Explorer has restarted and that the app needs to place it's icon in the tray again (with a ""forward" call to the API). Many tray apps don't enlist to get that callback, including some from Microsoft themselves. Sloppy programming on the part of the tray app makers, nothing else.
 
 View user's profile Send private message Visit poster's website 
Reply with quote Back to top
jgmdesign
PostPosted: Sep 06, 2008 - 08:13 PM
Raving lunatic


Joined: Apr 20, 2007
Posts: 6072
Location: Long Island New York

You could always use a MAC Laughing

Jim

_________________
Jim

I have decided that I am no longer going to plan anything in advance. In a court of law this is called Pre-Meditated, and does not look good for the defense.....

Timer function not working properly? Check CLKDIV8 Fuse first Wink
 
 View user's profile Send private message  
Reply with quote Back to top
emuler
PostPosted: Sep 06, 2008 - 08:45 PM
Raving lunatic


Joined: Feb 07, 2007
Posts: 2395
Location: New Delhi, India

JohanEkdahl wrote:
Quote:

Restarting explorer.exe always loses a few of my system tray icons.

Not much comfort, but that can not be blamed on Explorer. The API for the System Tray includes a callback from Explorer to the tray application which essentially tells the app that Explorer has restarted and that the app needs to place it's icon in the tray again (with a ""forward" call to the API). Many tray apps don't enlist to get that callback, including some from Microsoft themselves. Sloppy programming on the part of the tray app makers, nothing else.

Comforting to know that I'm not the only sufferer. Wink Yes, Microsoft's own Windows Task Manager is often one of the 'missing' apps. I keep this minimized to tray - makes a handy CPU usage monitor.

I tried running the taskbar as a separate process, but that wasn't much help either. Sad
 
 View user's profile Send private message  
Reply with quote Back to top
JohanEkdahl
PostPosted: Sep 06, 2008 - 09:03 PM
10k+ Postman


Joined: Mar 27, 2002
Posts: 18583
Location: Lund, Sweden

Quote:

I tried running the taskbar as a separate process, but that wasn't much help either.

OK, in case I was unclear: It is not the Explorers fault. It is not Taskbars fault either. It is the separate apps that present themselves with an icon in the taskbar that are at fault, not subscribing to the Explorer callback API. It's been several years since I dibbled with this in depth, so I'm afraid the details have been swapped out into the void. (If someone really needs them I'll dig in the vaults..)
 
 View user's profile Send private message Visit poster's website 
Reply with quote Back to top
emuler
PostPosted: Sep 06, 2008 - 09:08 PM
Raving lunatic


Joined: Feb 07, 2007
Posts: 2395
Location: New Delhi, India

No, no, you were quite clear. I'm afraid I wasn't. Embarassed What I meant was that by running the taskbar as a separate process it should have been possible to restart explorer.exe without killing the taskbar too. That way the pesky explorer.exe would release all the files it was locking, and the taskbar would remain as it is.

Sadly, I had no success with this at all. Killing explorer.exe invariably killed the taskbar too. Sad

_________________
If you think education is expensive, try ignorance.
 
 View user's profile Send private message  
Reply with quote Back to top
abcminiuser
PostPosted: Sep 07, 2008 - 07:11 AM
Moderator


Joined: Jan 23, 2004
Posts: 9832
Location: Trondheim, Norway

Windows has a reasonably bad architecture of locking files willy-nilly for read access, even if the file is already cached in memory. This is partly due to Windows' design, and partly due to poor programmers not releasing files properly/as fast as possible.

One common source of file locks is Explorer, the Windows shell. In modern Windows versions, as each folder is opened Explorer will then traverse the child folders to generate thumbnails of files when a registered thumbnail handler is avaiable -- that's how you get the movie screenshots, picture thumbnails in XP and Vista. As each file is processed, several things happen:

1) The file is opened by the explorer process and locked due to file read
2) The filetype is examined, and the registry checked for any matching handler
3) If the file is a media file, each codec on the computer is queried looking for a matching handler
4) If found, the codec or the thumbnail handler creates a thumbnail
5) The file is unlocked and the thumbnail shown -- also, optionally, the thumbnail is cached into the thumb.db hidden file inside the directory


That's a lot of work, and in the case of a broken handler or a misbehaving codec, it can cause Explorer itself to fail to release the file locks. For large directories full of many media files (or other thumbnailable types) the time required for the thumbnailing can also give the "folder locked" symptoms.

It is this reason that you need to wait a few seconds when opening a folder containing a second folder full of media files before trying to delete them, as Windows Explorer locks the child folder while it thumbnails it, much to the users chagrin when they just want to delete it.


Having the folder open in Explorer anywhere will also lock the folder, so before you can eject a driver you will need to make sure that it has no open windows. Deleted files in the drive will NOT cause locking behaviour; they are shifted into the hidden system "RECYCLER" folder on the drive and so you can delete a file to the recycle bin, remove and replace the drive, and the file will reappear in the recycle bin.


Turning off write caching can solve some of the problems, but decreases the drive performance - each small write must be flushed to the physical driver rather than cached and written out when needed. Disabling write caching (default on removable drives in XP) allows you to yank out the drive at any time with no data loss, but has the penalty of constant fsync()s.


You can use Process Explorer from Microsoft to search for any processes with open handles to files on the device, and narrow down the culprit that way.

- Dean Twisted Evil

_________________
Atmel Studio 6.1 is now released, grab it here.
Report AS6/ASF bugs here.
 
 View user's profile Send private message Send e-mail Visit poster's website 
Reply with quote Back to top
emuler
PostPosted: Sep 07, 2008 - 07:25 AM
Raving lunatic


Joined: Feb 07, 2007
Posts: 2395
Location: New Delhi, India

Which is why I keep the Windows Task Manager minimized to system tray. Selecting a video file in Explorer causes a momentary rise in CPU usage which can be seen in the tray icon. For large videos, especially broken/incomplete ones, this condition can last several minutes. When the CPU usage goes down again, it is safe to move/delete the file.

Btw. AFAIK the recycle bin is not available for removable drives. Files are deleted directly.

_________________
If you think education is expensive, try ignorance.
 
 View user's profile Send private message  
Reply with quote Back to top
JohanEkdahl
PostPosted: Sep 07, 2008 - 10:55 AM
10k+ Postman


Joined: Mar 27, 2002
Posts: 18583
Location: Lund, Sweden

Quote:

You can use Process Explorer from Microsoft to search for any processes with open handles to files on the device

How? Where is that alternative(Show me who has open files at/below a certain path)? Or are you actually suggesting a sequential search? Shocked On a Vista system with FireFox, Open Office Writer running I have 84 items in the list in Process Explorer..
 
 View user's profile Send private message Visit poster's website 
Reply with quote Back to top
JohanEkdahl
PostPosted: Sep 07, 2008 - 11:05 AM
10k+ Postman


Joined: Mar 27, 2002
Posts: 18583
Location: Lund, Sweden

And the saga continues.. Started a command-prompt.

Vista wrote:
ERROR: Logged-on user does not have administrative privilege.


So I go to the Control Panel, User Accounts. There is one user, me, with Administrator rights.
 
 View user's profile Send private message Visit poster's website 
Reply with quote Back to top
JohanEkdahl
PostPosted: Sep 07, 2008 - 11:10 AM
10k+ Postman


Joined: Mar 27, 2002
Posts: 18583
Location: Lund, Sweden

Quote:

In Windows, open Device Manager, Disk Drives, right click on USB drive in question, select properties. In Policies tab, select optimize for quick removal. Done.

Thought I'd try this out too. The Quick Removal option was already set..
 
 View user's profile Send private message Visit poster's website 
Reply with quote Back to top
AllN
PostPosted: Sep 07, 2008 - 11:30 AM
Posting Freak


Joined: Feb 14, 2007
Posts: 1858
Location: San Diego California

JohanEkdahl wrote:
And the saga continues.. Started a command-prompt.

Vista wrote:
ERROR: Logged-on user does not have administrative privilege.


So I go to the Control Panel, User Accounts. There is one user, me, with Administrator rights.

So you can't run the cmd program without getting the error or are you entering a program in the command-prompt window? If the latter, what command?

If you only have one user account and it’s has Administrator privileges then you should be able to run anything; except a few network commands that required you to have a password and the Guest user account turned on also.

John

_________________
Resistance is futile…… You will be compiled!
 
 View user's profile Send private message  
Reply with quote Back to top
JohanEkdahl
PostPosted: Sep 07, 2008 - 12:34 PM
10k+ Postman


Joined: Mar 27, 2002
Posts: 18583
Location: Lund, Sweden

Oh, sorry.. My mind was occupied being irritated. This is what I intended to post(added part emphasized):

And the saga continues.. Started a command-prompt. Type openfiles and hit enter.

Vista wrote:

ERROR: Logged-on user does not have administrative privilege.



So I go to the Control Panel, User Accounts. There is one user, me, with Administrator rights.
 
 View user's profile Send private message Visit poster's website 
Reply with quote Back to top
Display posts from previous:     
Jump to:  
All times are GMT + 1 Hour
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Powered by PNphpBB2 © 2003-2006 The PNphpBB Group
Credits