bdezonia
2/4/2009 7:04:00 PM
I continue to have a crash with a script I've written that recurses
through a disk calling foreach() as needed on directories.
I am getting the following error:
D:/BackupScripts/trimMachines.rb:130:in `open': Invalid argument - x:\.
\data\dubinin\vmap\v1180\soamafr\lib_180\trans\k\f\g\e (Errno::EINVAL)
from D:/BackupScripts/trimMachines.rb:130:in `foreach'
from D:/BackupScripts/trimMachines.rb:130:in `trimDirectory'
from D:/BackupScripts/trimMachines.rb:135:in `trimDirectory'
from D:/BackupScripts/trimMachines.rb:130:in `foreach'
from D:/BackupScripts/trimMachines.rb:130:in `trimDirectory'
from D:/BackupScripts/trimMachines.rb:135:in `trimDirectory'
from D:/BackupScripts/trimMachines.rb:130:in `foreach'
from D:/BackupScripts/trimMachines.rb:130:in `trimDirectory'
... 31 levels...
from D:/BackupScripts/trimMachines.rb:193:in `trimMachines'
from D:/BackupScripts/trimMachines.rb:178:in `foreach'
from D:/BackupScripts/trimMachines.rb:178:in `trimMachines'
from D:/BackupScripts/trimMachines.rb:244
I've checked and the directory mentioned does exist, the user account
has full access to the directory, the directory is not empty, the
directory name is < 255 chars long, etc.
This script works for millions of files with directories that have
much longer names and many more subdirectories than this example
failure. The failures happen routinely after a few days of running the
script and always on different directories.
I am running Ruby 1.8.6 (2007-09-24 patchlevel 111) [i386-mswin32] on
Windows Server 2003 64 bit.
Does anyone have a clue what the problem could be? Is this a Ruby bug?