IOException when no disk space left

Good time of day, everyone!
In my program, I have to copy files of a quite substantial size from one media onto another. Since the free space is limited, I need to catch the case when it gets no longer available. The total size of files is unknown and cannot be computed beforehand (random element), so checking availability before copying each file would barely make sense.
What I need is to catch the case when it ultimately runs out of free disk space while copying. What exception is that? The program throws some unreadable gibberish (likely because of my locale):
java.io.IOException: ═хфюёЄрЄюўэю ьхёЄр эр фшёъх
Another thing that worries me is that it takes quite a long time before this exception is thrown. Maybe there's a better solution?
Googling gave nothing so far :(
Thanks in advance!

SqueezyMo wrote:
Good time of day, everyone!
In my program, I have to copy files of a quite substantial size from one media onto another. Since the free space is limited, I need to catch the case when it gets no longer available. The total size of files is unknown and cannot be computed beforehand (random element), so checking availability before copying each file would barely make sense. You're burning CDR's or DVDR's, right? The common approach to "making stuff fit" is to pre-build a file collection... to burned when the user "commits" the selection (by pressing a burn button). This allows the user to organise the content to "best fit" accross multiple media... most burners now automatically workout "best fit" based purely on size (I guess using some sort of [backpack algorithm|http://encyclopedia2.thefreedictionary.com/Backpack+problem]).
Overall the trick is remove the "randomness" by delaying the burn process.
This doesn't really apply to (reliably) rewritable media... Note that DVD-RW's are notoriously NOT reliably rewritable... the probability of corruption seems to nearly-double on each overwrite after the first dozen (or so)... I gave up using them for backups, and went back to DVD-R's... (now I use an external HDD).
What I need is to catch the case when it ultimately runs out of free disk space while copying. What exception is that? The program throws some unreadable gibberish (likely because of my locale):
java.io.IOException: ═хфюёЄрЄюўэю ьхёЄр эр фшёъхTry changing your locale to English (temporarily), so you can read that error message... and also try writing it (the exceotion) to a UTF-8 encoded file... I suspect the console is responsible for scrambling the high-order UTF characters.
Another thing that worries me is that it takes quite a long time before this exception is thrown. Yes... it would, it would take time to fill the destination media, wouldn't it... so do your size check before you start copying anything. Also worth noting that most users prefer an "upfront, all or nothing" paradigm most of the time... giving them confidence that when they hit the "go" button it will eventually work... nothing worse than a slow kettle that needs watching.
Maybe there's a better solution? Yes, several... It's just time to bight the bullet and get serious about this, or just use one of the plethora of libraries ;-)
Googling gave nothing so far :( Thanks in advance!Yep, google is excellent for "named problems" of all sorts (from aircraft maintenance scheduling to fish recipes)... not so good for problems such as this which have (AFAIK) yet to be ascribed a common name.
Cheers. Keith.
PS: Listen to Chicon... I should have read his post before writing this... Que sera sera.

Similar Messages

  • There is not enough disk space left to import

    I am in the middle of editing a movie. I have imported two clips and am trying to import a third.
    I have precisely 62.42Gigabytes of hard disk space (I have a 120 Gig HD). The clip I want to import is 1.69 Gigabytes.
    I get the following message:
    Error during Import
    The file could not be imported: There is not enough disk space left to import...
    I tried moving the project to another account on the same computer but that did not work either.
    I have searched through these forums and many others seem to have the same problem but I have yet to find ANY workable solution!
    HELP please!

    The clip I want to import is 1.69 Gigabytes.
    By any chance, is the "clip" a compressed QuickTime movie? If so, when iMovie converts it to DV a 1.69GB movie may expand quite a lot. Please describe the clip.
    And describe the disk the project resides on. Is it an internal disk or external disk?
    Here's some things to check out...
    http://discussions.apple.com/message.jspa?messageID=2920540#2920540
    Karl

  • The file could not be imported: There is not enough disk space left

    The file could not be imported: There is not enough disk space left to import
    why? I have 53.1 Gb left and I can import the whole movie but when I broke it up into chapters to edit it will only import 2 edited chapters I don't like imovie
    anyone ??

    dananarama wrote:
    I just had the same problem this morning. I tried to import a 500MB mp4 into iMovie HD, and I have 9.5GB on my hard drive, but the same error message came up.
    If the 500MB mp4 file was highly compressed and iMovie converted it to DV, it's quite possible iMovie would run out of disk space.
    Although 9.5GB sounds like a lot, it's tiny when editing video. (Each hour of video is ~13GB.) When iMovie complains that it can't find the disk space it needs, it's not a good thing. Everything is put in jeopardy. Don't forget that thee Mac OS X itself needs a certain amount of elbow room. When it can't get it, big problems can occur.
    The main drive of your Mac should have at least 10-15% free disk space at all times, even AFTER iMovie/iDVD is done handling the video.
    Karl

  • Not Enough Disk Space Left

    I'm trying to make a highlight film to send to colleges for football and im using imovie hd. I've imported 2 game films onto a project from a usb jump drive and made 15-20 7 second clips from them. Then I've deleted the big game film files from the project. I'm trying to import another game film, but everytime I do it says "Error during import. The file could not be imported: There is not enough disk space left to import gamefilm.mp4"
    I thought maybe it was because I didn't have enough space on my hard drive. But it says there's 1 GB left on my drive. Each film is about 225 MB. Plus I loaded the film from the jumpdrive to the harddrive with no problems. Then I thought it might be there's not enough room on the project. So I opened a new one, but its the same problem. How do I import the new film...?

    Welcome to the forums.
    It sounds like you're encountering a problem when iMovie converts the file from the USB drive Presumably the game film is very compressed on the jump drive, but iMovie converts video into a format it can use (at about 13 gigs per hour). A gig on your hard drive means that you deperately need more hard drive space.
    Once you free up more space for import, you've solved only part of the problem because burning your project to DVD will take gigs more space. Over in the iDVD forum, you'll see recommendations for 10-20 gigs of free space for burning a DVD.
    Besides this project, your computer needs space to function effectively. Some folks say we need 10% free, but that's a lot of space on a big drive. I start to worry if I have less than 10 free gigs for everyday use; more if I'm doing a video project.
    John

  • No disk space left error

    I keep getting prompted that I have no disk space left, but I have over 40GB left. It then wants me to force quit my applications in order to continue doing anything. My mac is also running a lot slower lately and I constantly have to force quit applications because they freeze. I just got it about 2 months ago, so I really don't understand the problem.

    Sorry.
    Yes, I have 116 Gb available. If I had not much than 14 Gb, I'd figure the problem!
    About the fragmentation... well, since my computer is new (around october 2007) and I never passed beyond my 116 Gb free space, I doubt the disk is too fragmented. At least, I never took care of fragmentation on Mac OS.
    I just discovered that DiskWarrior 3 does not work on my system (10.5.1), so I don't even know another tool for fragmentation.
    Thank you.

  • Low disk space left on Q drive on T430s

    I have seen a few posts where a few others have had this problem but so far I'm having no luck figuring out how to fix it. I bought this laptop for my wife and set it up yesterday with no messages. Turned it on today and it now says I have only 1.67GB left of 13.6GB.
    How can I fix this problem... any help would be great.
    Solved!
    Go to Solution.

    Dan,
    I'm not sure why my Q drive is running low on disk space, but have read that once a back up had been done that this drive can be deleted. I did the back up thing but part of me wants to save the recovery on Q in case I lost the back up disks or that maybe there might not have copied correctly. I just don't understand as to why the disk space seems to be shrinking. Such a pain when no one seems to have any idea as to how to fix it.

  • No disk space left on my pc because of photostream!

    Hi,
    my pc has no disk space as it has all of my photostream saved on it, so how can I stop this happening (the 1000 photos are saved on pc even though the photostream box is unticked on my pc in icloud)?
    I have found that if I delete a photo in photostream folder saved on my pc it also deletes it from my iphone camera roll and any folders I have put it in, so what would happen if my pc 'died'? Is there a way to delete all my photostream on my pc, but keep them on iphone, and how can I make sure that they are not saved again when I next sync my iphone?
    On itunes there is a box that says 'sync photos from' and it gives option to choose a folder on my pc (this box is unticked), but I thought itunes saved photos FROM iphone, not from pc?
    How can I view my photos on icloud.com, all I can see are folders for mail and reminders etc?
    Thanks a million (frustrating!)

    >...everything is automatically saved to the C one?
    Depends on which kind of data you are writing about.
    For instance, you use download application eMule and by default download files will be saved in folder created on partition C. for this purposes you can create own folder on partition E and define this in eMule settings, so all downloaded data will be saved automatically on partition E.
    If you have some files on C just move them to E.
    If you don't know how to this I m afraid you should visit some Windows course and learn basic stuff about operating systems or buy some book and learn how it works exactly.
    Please don't understand me wrong but you are missing some basic knowhow about operating systems and how to work with.

  • Formatting a HDD with the Solaris 8 install when the disk space is locked.

    I added memory, a printer, and a CD Writer to my PC, and then I reinstalled solaris 8. At the point where it asks which drive to use, the only available drive, which is my C: drive, shows up with a negative disk space value. However, when I look at the partition size, it is 20 GB, and if I change it, it has no effect on the negative value. This is a reinstall of Solaris 8 onto the same drive. Is there a way to fdisk the drive. Solaris 8 won't do it, and Partition Magic seems to only work with linux, which does not seem compatible with Solaris?

    I added memory, a printer, and a CD Writer to my PC, and then I reinstalled solaris 8. At the point where it asks which drive to use, the only available drive, which is my C: drive, shows up with a negative disk space value. However, when I look at the partition size, it is 20 GB, and if I change it, it has no effect on the negative value. This is a reinstall of Solaris 8 onto the same drive. Is there a way to fdisk the drive. Solaris 8 won't do it, and Partition Magic seems to only work with linux, which does not seem compatible with Solaris?

  • How to find out how much disk space left on hard drive OS 10.7.5?

    Yes, this probably seems like a dumb question; however, after I installed OS 10.7.5, I noticed that the little bar at the bottom of each window which revealed available disk space has disappeared. How do I get it back? How do I find out how much space left on my internal hard drive?

    ArtWench wrote:
    How do I find out how much space left on my internal hard drive?
    Right Click on it and  Get Info > Available
    ArtWench wrote:
    ... which revealed available disk space has disappeared. How do I get it back? ...
    Finder > View > Show status bar

  • Notify users when their disk space is running low

    Hi all,
    I'm an administrator of about 100 Apple macs and an OS X server and generally speaking, problems are pretty easy to fix. There is just one major problem I'm always having and its simple to fix, which is that when Users run out of home disk space (only 600MB each) applications start crashing (understandably). The problem is that users don't actively watch their free disk space and when things start going wrong, I'll come along and point out that they need to delete some things and it'll start working again.
    What I'm having trouble with (because I'm an absolute beginner) is making an AppleScript (or whatever would be best) to watch for when their home space is getting full (with 20MB free space) it'll pop up and say "don't trouble the technician, delete some files!" (or something along those lines)
    So, here's what I have (pretty pathetic)
    tell application "Finder"
    set freeSpace to (free space of (get startup disk)) div 1024 div 1024
    end tell
    Is their a way of finding disk space of a Home Drive (which is on a network drive on the server)
    What I'd like is to say
    tell application "Finder"
    set freeSpace to (free space of (get home)) div 1024 div 1024
    end tell
    It tells me "can't get free space of folder "stephenl"" (my home folder)
    Could anyone please help

    --I'm sure there are several ways to do what you want; here's one that works on an individual computer. If necessary, suitable changes should be possible for server situations, but someone else will have to jump in on that. Copy this to Script Editor, make suitable modifications, then save it as an application; be certain "Startup Screen" isn't checked. Either have the user start it when the computer is started up, or place it in the log-in items (System Peferences) so that happens automatically.
    set message_ to "Stephen! Don't trouble the technician, delete some files!" -- modify to suit
    set MinAllowFS to 20 -- set this to the available disk space you want to trigger one or more of the responses. MB doesn't have to be specified if everything is in MB (max. possible space, etc.), otherwise some adjustments will have to made to the script. To TEST the script, set the number above what you know the available space could be.
    repeat --(However often you want to check free space)
    delay 5 --that's 5 seconds; if you think every 10 minutes is often enough to check, make that 600; or make it 0 and the script will repeat essentially in the time it takes to run, which is about 2.5 seconds on my machine
    try
    set bootDiskInfo to do shell script "diskutil list | grep 'stephen'" -- this gets information for all disks, and then finds the line pertaining to disk 'stephen' (change as necessary)
    set bootDiskID to last word of bootDiskInfo -- that last word is the identifier for the disk you're after
    set FSinfo to do shell script "diskutil info " & bootDiskID & " | grep 'Free Space'" -- similar to the above command, getting the free space for the boot disk.
    set ActFS to word 3 of FSinfo -- word 3 is the numerical value of the free space, irrespective of the multiplier (KB, MB, GB etc.); as stated previously, there will have to changes to the script if the spaces range amongst multipliers.
    --Pick one or more of the following responses by removing the comment ("--")
    if ActFS < MinAllowFS then beep 3
    --if ActFS < MinAllowFS then display dialog message_
    --if ActFS < MinAllowFS then say "[[rate 180]]" & message_--[here's a link on using speech: http://www.blankreb.com/studioarticles.php?ID=3
    end try
    end repeat

  • Not enough disk space left error

    I am trying to put a video that is in .mov format into imovie HD and then export that into a DVD file so I can burn it and play it on a DVD player. But right away when I try importing it to edit it it says not enough disk space. I have 18 gigs on the hard drive that I am using right now. Is there any way around this or would the file just become that big or what? Thank you beforehand for any information you can provide.

    No that doesen't pretain to my problem I am not having a problem burning the disk or with Idvd at all (yet anyways) just importing it to Imovie without a pointless error that makes no sense. Of corse it does talk about skipping imovie completely by using Idvd which is what I am trying to do now but it takes a very very long time for quicktime to convert files of that size. But I will see if it works and post back again.

  • Disk Space Left

    Hi All,
    Just a quick question you may be able to help me with?
    I have an imac 800 G4 with 768mb Ram. It only has a 60GB hard drive. The drive has only about 1.4GB of space left. I have noticed a lack of performance over the last few weeks and was wondering if the lack of disk space would be causing the slow down.
    Any ideas if this would be causing my slow down?
    Thanks
    Dan

    Once you've followed Ian's excellent advice: the long term solution will be additional storage:
    You could archive old data to CD-R/DVD-R using your optical drive very easily; just use the Finder's disk burning capabilities.
    Also you could purchase an External Firewire Hard Drive. This is likely to be faster than your internal drive (5,400rpm vs 7,200rpm respectively) and can have a capacity of up to about 1.5Tb(!). Here are some examples. You can add internal drive but this is more complex and some 800Mhz iMac users report that they are limited to 128Gb (which is the addressing limit on the IDE bus on older Macs).
    mrtotes

  • MacBook Pro becomes has spotlight problems when disk space gets low

    I've noticed that when my disk space gets very low, that mds starts running all of the time bringing my laptops's performance to a crawl. I've also noticed that oddly, when I try to use spotlight for a full text search (not just from/to/subject searches) in Mail, that spotlight seems to start re-indexing immediately.
    Specifically:
    1) I go to mail and start a search in spotligh
    2) the "message body" option is available for me to search through the entire message body
    3) I select "message body" for my search, but spotlight finds no results (even though there are some)
    4) the next search I do in Mail via spotlight now shows "message body" as greyed out
    5) mds and associated processes suddenly start running and my mac becomes very slow
    6) after some number of hours, mds stops and "message body" becomes available in Mail again for searches, but as soon as I try to use it this process repeats
    I had about 10 gigs free on my disk, but after freeing up about 30 gigs this all stopped and spotlight started working again fine.

    This emphasises the old guideline of having not more than about 80% of disk space used for best performance on any computer. If in doubt about which hdd to buy get the largest you can afford - probably the next size up from that!
    Neville

  • Receiving an automatic notification from Windows Server when disk space is low

    Hello,<o:p></o:p>
    Does Windows Server 2012 R2 have any such functionality built-in to enable monitoring of disk space?
    We have an old VB Script file that sends me an email when disk space gets low.
    Also, the following post discusses the topic regarding Windows Server 2008:
    http://social.technet.microsoft.com/Forums/windowsserver/en-US/c9878861-6ba5-4d3b-b6b0-6e4b33c41853/notification-when-low-disk-space?forum=windowsserver2008r2management
    I was wondering if there was any change regarding this in
    Windows Server 2012 R2 .
    Many thanks.<o:p></o:p>
    Keith<o:p></o:p>
    R K Howard

    Hi,
    Windows Server 2012 stays the same on that topic, you still need some kind of monitoring on your disk space.
    If you don't have a monitoring solution, like for example SCOM, you can for example with powershell do what you earlier did in VB script. Either you have a scheduled task that runs as often as you'd like, or you can utilize something called WMI eventing
    to trigger on an event 'disk low' but thats a bit more complicated.
    See below examples on some example scripts that you could use.
    https://www.simple-talk.com/sysadmin/powershell/disk-space-monitoring-and-early-warning-with-powershell/
    http://technet.microsoft.com/en-us/library/ff730927.aspx
    http://gallery.technet.microsoft.com/6e935887-6b30-4654-b977-6f5d289f3a63Hope
    this helps you!
    //Johan
    Microsoft Certified Trainer
    MCSE: Desktop, Server, Private Cloud, Messaging
    Blog: http://365lab.net

  • 20gb of Disk Space Vanishes? On it's own?

    Hi guys, I'm a long time mac user and have never seen anything like this.
    I run a 2.53gz MBP 5,1. with 4gb of ram and 320gb HD. I have the drive partitioned with a 60gb NTFS bootcamp partition for WindowsXP that I use with Parallels 4. I use Time Machine to backup to a 2tb WD drive.
    So, I've been running the machine all day long with approximately 24.5gb of disk space. I left my desk around 6:00 today and I just came back to find a low disk space error and saw that I only had 1.8gb left, and watched it drip down to 1.5, 1.3 and 1.1gb right in front of my eyes without doing anything at all! I rebooted and now the computer has been sitting steady at 5.7gb. I looked through my timemachine archive to earlier in the day and the last update was right after I left (with 24.5gb of disk space left) the next update is inexplicably at 1.7gb. I did get info on all the main folders in my root directory (Applications, Library, System & Users) and the identical folders now and there is almost no difference whatsoever in folder size! Yet, when you look at the bottom of the window in the time machine reference from a few hours earlier it says 24.5gb available, and then go back to the "now" window it says 5.7gb available...
    I'm totally baffled. approximately 19gb of disk space just completely vanished and I can't account for the change or the increase in used disk space anywhere.
    The only recent update was the Security Update 2010-001 that was issued on the 19th.
    I have tried to restart. Reset the PRAM. Checked the SMART status using Disk Utility. Everything checks out.
    The only thing I could possibly point to is an issue with Bootcamp and the NTFS drive. However I was not running bootcamp or parallels when this happened.
    Time Machine was stuck at "Calculating Changes... (15%)" when I came back and the Time Machine drive is nearly full...but I don't think this should matter.
    Also Time Machine hasn't completed a full backup since the drive was at it's original 24.5gb. I'm wondering if it got stuck when doing a backup and somehow is confused between what is backed up and what isn't and there is disk space being "held" somewhere by time machine somehow.
    Any suggestions on what happened to the mystery 19gb?
    Message was edited by: gabeotron

    The two swap files sound OK, you will always have at least one of approximately 60MBs. The sleepimage is also normal: it will be about the size of the RAM you have, and contains the content of your actual RAM. The point being that if you put your computer into hibernate, or for a laptop the battery runs out of juice, when the machine is again brought back into action it can resume from where it was when things were stopped. So that is normal.
    It sounds like perhaps a run-away log file could be responsible. You might take a look in
    /private/var/log
    Arrange by size and see what you've got. My biggest one is the folder for DiagnosticMessages, at 5MBs. Everything else is in the KB range.
    If that doesn't turn up the culprit you can use the Terminal commands.
    Francine
    Francine
    Schwieder

Maybe you are looking for

  • Can't print from LR5

    I'm trying to print a test print before I print a 13 x 38 panorama. I don't know yet if anything will print as I want, but here's what I've spent time thrashing on with this print: Mac os 10.8.4, latest Epson drivers, Epson 3880. I've got this set up

  • SMTP Port # for use in hotels etc

    Ive tried various methods and have webmail enabled but wondering if there is a recommended alternate port user's can input into entourage/mail when in a hotel or something where 25 is blocked. What's a recommended way to change it or add it on there

  • RH9 - Can not create ANY links in linked Word documents ;-(

    Ok, this does not make sense: - From RH9, create a fresh empty project - Create two word files "Topic1.docx" and "Topic2.docx" - Put "Link Here" in each document - Save the documents - From Project Manager, Project Files, link both documents, generat

  • Can I increase the amount of memory allocation to my terminal or any other application to make it run faster ?

    Hi, I have a file that must be run using Terminal only. Its a pretty large file and i do remember that in WIndows we had an option where we could maximum run-time memory to speed up the process of a particular task. Is there any, such chance in Mac ?

  • Macbook Pro 13" Sluggishness

    Hello fellow Applers, I've been convinced I was paranoid for a while now, but recently I just can't take it anymore. Please let me know if these are normal specs for a 2011 MBP 13". 4gb DDR3 RAM, 320gb Hitachi HDD 5400rpm 1:34 seconds to power on and