delorie.com/archives/browse.cgi | search |
X-Spam-Check-By: | sourceware.org |
From: | "Dave Korn" <dave DOT korn AT artimi DOT com> |
To: | <cygwin AT cygwin DOT com> |
Subject: | RE: Using du.exe to calculate disk usage on a Microsoft cluster server |
Date: | Mon, 3 Jul 2006 15:04:44 +0100 |
Message-ID: | <016d01c69ea9$a30d5760$a501a8c0@CAM.ARTIMI.COM> |
MIME-Version: | 1.0 |
X-Mailer: | Microsoft Office Outlook 11 |
In-Reply-To: | <44A92091.2080108@bethel-crc.ca> |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Unsubscribe: | <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com> |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
On 03 July 2006 14:50, Will Beldman wrote: > I need to determine disk usage for each directory on a Microsoft cluster > server. As a linux junkie, du is *the* tool for automating this kind of > stuff so I installed cygwin, mapped some drives and tried to schedule > the utility to run at night. However, I get a lot of errors thrown back > such as: > 1. "No such file or directory" - Which tends to appear on weird > filenames (like with spaces or ' or some other character) or when I > don't have permission to access the drive (but that's something I can fix) Without seeing your script and knowing the dir names in question, it's hard to say, but the obvious bet would be some kind of shell quoting/escaping bug in the way you invoke 'du'. > 2. "File name too long" - Which it is, but I'd hope there is some way to > get around this Rename it. How did you get a filename that's longer than PATH_MAX? That's not meant to even be possible! > 3. "du: fts_read failed: Permission denied" - That's the last error > message I get. The program seems to crash at this point. Probably perms again. Hard to know whether it's actually crashed or is just doing something with no visible output unless you actually debug it though. > My question to the list is: > 1. Is there a way to eliminate the errors above (especially the third so > it can at least complete) First two seem easy. Third is indeed a bug I would guess; if the tree walk fails, it should fall back to manually descending the dirs (or at least error-out gracefully). Would need to be able to reproduce it to know for sure. > 2. Has anyone else found a solution which will properly report the > amount of disk space a particular directory is occupying? Something that > is free and can be scheduled to run at night. Let's see if we can't make 'du' work first! cheers, DaveK -- Can't think of a witty .sigline today.... -- 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/
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |