Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Not Enough space

 
Neelam Gautam
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All!

I want to do telnet from my unix server to a windows server for it i use JTA Api of java. but while i am running 'exec' function by my RunTime Object , i am getting "java.io.IOException: Not enough space" Exception. but i have enough space on my server. so whats the problem with my code..? is there any bug of IO..? my code snippet is as follows::

String exec="telnet 203.187.192.75 5501";
Runtime run=Runtime.getRuntime();
Process proc=run.exec(exec); // exception comes here ..

please help

Thnaks in advance.

 
naveen jain
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
 
Carey Evans
Ranch Hand
Posts: 225
Debian Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The Java exception doesn't seem to say where the error occurred, but it’s probably ENOSPC or similar from a call to pipe(2) or fork(2). It could be caused by exceeding some process quotas, or limits like virtual memory or number of open file descriptors. The last one is possible if you’re creating lots of processes, but not closing all three streams associated with them when you’re finished.

You could try using tools like strace or truss to identify the failing system call; or alternatively, use something like Apache Commons Net to do the Telnet protocol in pure Java.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic