commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GMail <student...@gmail.com>
Subject Re: [io] FileSystemUtils.freeSpaceKb on unix gives OS error
Date Wed, 19 May 2010 13:07:41 GMT
Hello levi,

That's a the only description that you might get - external process exited with error.

What kind of UNIX do you have?

Check what environment java process has (PATH and other variables
might be different for logged in user and process), what is the
directory where process is running.

Wednesday, May 19, 2010, 8:27:37 AM, you wrote:
> Hi,

> I'm testing an app on Windows and Unix with commons-io-1.4.jar
> On Windows calculating the freeSpace is OK,
> but on Unix I get the following error.
> Executing 'df -k' manually on the machine works as expected. Too bad we
> don't see a better error description. Does anyone have any hints where to
> look for the problem? Maybe userrights?

> java.io.IOException: Command line returned OS error code '1' for command
> [df, -k, ]
> at
> org.apache.commons.io.FileSystemUtils.performCommand(FileSystemUtils.java:419)
> at
> org.apache.commons.io.FileSystemUtils.freeSpaceUnix(FileSystemUtils.java:323)
> at
> org.apache.commons.io.FileSystemUtils.freeSpaceOS(FileSystemUtils.java:196)
> at
> org.apache.commons.io.FileSystemUtils.freeSpaceKb(FileSystemUtils.java:166)

-- 
Best regards,
 Alex                            mailto:student00x@gmail.com


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
For additional commands, e-mail: user-help@commons.apache.org


Mime
View raw message