Help using Base SAS procedures

ERROR: Insufficient space in file WORK

Reply
New Contributor
Posts: 4

ERROR: Insufficient space in file WORK

[ Edited ]

Hi all,

 

After using SAS University Edition for a couple of weeks now, I'm running into the two errors:

 

ERROR: Insufficient space in file WORK.'SASTMP-000000019'n.UTILITY.
ERROR: File WORK.'SASTMP-000000019'n.UTILITY is damaged. I/O processing did not complete.
 
It happens on many occasions, but the most strange example I have is the following;
 
Table Data.example is 2.5M rows (100MB), with
 
p_id num, c_id num, startyear num, endyear num, flag num
1, 1, 2005, 2009, 0
1, 2, 2009, 2013, 0
1, 1, 2013, , 1
2, 5, 2001, 2012, 0
......
 
When I try to invoke the following
PROC SQL;

UPDATE Data.example
SET endyear = 2020
WHERE flag = 1;
I get the error. I find this weird as the dataset may have many rows, but is still fairly small in size. Any ideas or suggestions on how to cope with this?
 
Thanks in advance!
 
UPDATE:
 
When I run a completly new instance of SAS (in a new VirtualBox), everything runs great. Here the virtual drive size is still 10GB, but the real size is only 4GB. I guess that this is the difference? And how is this possible?
Super User
Posts: 9,671

Re: ERROR: Insufficient space in file WORK

A solution is finding a fold which has a large space . and specify :

 

options  user='d:\temp\'  ;

 

 

this option will use d:\temp\ instead of WORK library . and run your code again. 

New Contributor
Posts: 4

Re: ERROR: Insufficient space in file WORK

Thanks for your reply Xia, but I don't that will work. I'm running it in VirtualBox, and don't I thought that it was not possible to increase the size of the drive. The virtual size and real size are almost equal (10.7GB, 10.4GB), but I don't know how that is possible, as I don't have that much data (~4GB, of which ~3GB of original data that I trimmed down to that 100MB noted above).

 

It looks to me like all temp files should be deleted somehow, but I don't know how this is possible or even if this is the way to go.

Super User
Posts: 9,671

Re: ERROR: Insufficient space in file WORK

Are you using SAS University Edition. If it was ,try :

 

options  user='/folders/myfolders/'  ;

Super User
Super User
Posts: 7,392

Re: ERROR: Insufficient space in file WORK

Use a datastep to do the update.  It has been pointed out the SQL can get quite resource hungry.  Now you can either do this two ways, the simplest would be with a datastep:

data have;
  startyear=2005; endyear=2009; flag=0; output;
  startyear=2006; endyear=2009; flag=1; output;
run;

data want;
  set have;
  if flag=1 then endyear=2020;
run;
New Contributor
Posts: 4

Re: ERROR: Insufficient space in file WORK

Thanks for your reply, but I think the operation I try to perform should be no problem. Especially since this is the easiest and simplest one I tried recently (when formatting, altering and reducing the 2GB file everything worked fine, so I don't believe a 100MB file with a single operation should cause any problem).

Super User
Super User
Posts: 7,392

Re: ERROR: Insufficient space in file WORK

As I said, SQL can be quite resource hungry.  You can also try clearing out work folders, if you right click on work in Explorer window in SAS, you can see the path to the work directory.  Go there and clear out the files.  Also right click on that folder and check how much space there is.

Occasional Contributor
Posts: 5

Re: ERROR: Insufficient space in file WORK

Hi Guys,

 

I´m having exactly the same problem. I used to access SAS with VMWARE, after a couple of weeks, it didnt work anymore. Then I moved to Virtual box. Excelent. Now, after two weeks, the LOG keeps saying:

 

ERROR: Insufficient space in file WORK.IMPORT.DATA.
ERROR: File WORK.IMPORT.DATA is damaged. I/O processing did not complete.
 
But it did the same task many many times in the past few days and very quickly. The file is 5mb in size, so this is not the problem. It seems that some table has exploded in space and damaged the work area. I have tried changing the work location, restarting the virtual machines, running the code again and again, and nothing seems to work. 
 
Where does the work files stay in the disk, regarding SAS Studio 3.5?
 
Thank you very much for any insight that could lead to solving the problem.
 
On time:
 
Does SAS store the work tables in my computer or in the virtual machine?
Does SAS use my memory RAM or virtual machine´s RAM?
 
I have 8gb ram (sometimes it points to insufficient memory) and 70GB space left in HD.
 
 
New Contributor
Posts: 4

Re: ERROR: Insufficient space in file WORK

Hi.

The student version only allows for 10GB on your virtual drive. There is no way to change that, so be careful with what you save on the virtual machine.

Kind regards,
Occasional Contributor
Posts: 5

Re: ERROR: Insufficient space in file WORK

But how can this be possible? I ran the same code again and again, always on work are and with success, so it overwrited the tables, not increasing table size.

 

Im now uninstalling everything to see what happens.

 

Thank you very much.

Super User
Super User
Posts: 7,392

Re: ERROR: Insufficient space in file WORK

Please do not necro threads - that means draggin back threads from quite some time and replying with new questions.  Every time you do this people who responded originally start getting notifications for threads long since closed.  Open a new topic.

Occasional Contributor
Posts: 5

Re: ERROR: Insufficient space in file WORK

Sorry. New in the community. Should I do what you say for this? My intention was to notify that RJ had the correct solution.
Super User
Super User
Posts: 7,392

Re: ERROR: Insufficient space in file WORK

Best to hit the like button on posts that help, and start a new thread for questions - things might have changed scince that post for instance.

Ask a Question
Discussion stats
  • 12 replies
  • 2247 views
  • 0 likes
  • 4 in conversation