3

I have seen some questions and I know that Ubuntu reserves 5% of filesystem to root. Believe me this is not the case.

I was moving some files from my home folder to another partition and I had to cancel the copying process due to some reason (the copy didn't stop abruptly, I cancelled it). Now when I try to move the remaining files I get error Error opening file '/media/sda5/Android/carbon/external/icu4c/i18n/ucol_bld.h': No space left on device. The destination partition has 85Gb free and my source (Ubuntu home) partition has 12Gb free (total of 48Gb, 5% of 48 is not 12).

Is there any other reason why I might get this error? How do i fix it?

Note: The path from which I was moving had a lot of directories and sub-directories. (It was android source actually. So you can imagine.) I don't know if that information might be useful.

Edit: df -h | grep -v '^none' gives

Filesystem      Size  Used Avail Use% Mounted on
/dev/loop0       48G   34G   12G  75% /
udev            3.9G  4.0K  3.9G   1% /dev
tmpfs           793M  1.4M  792M   1% /run
/dev/sda7        50G   50G  441M 100% /host
/dev/sda9        50G   34G   17G  68% /media/sda9
/dev/sda6       300G  281G   20G  94% /media/sda6
/dev/sda5       300G  221G   80G  74% /media/sda5

df -h -i | grep -v '^none' gives

Filesystem     Inodes IUsed IFree IUse% Mounted on
/dev/loop0       3.0M  874K  2.2M   29% /
udev             989K   578  989K    1% /dev
tmpfs            992K   655  991K    1% /run
/dev/sda7        505K    66  505K    1% /host
/dev/sda9         17M   38K   17M    1% /media/sda9
/dev/sda6         20M  110K   20M    1% /media/sda6
/dev/sda5         81M  1.1M   80M    2% /media/sda5

Please note that the partitions in question are /dev/loop0 and /dev/sda5

Edit 2:

I just noticed that I am even unable to create new documents in my partition /dev/sda5 (all the more reason to panic)

Edit 3: I fired sudo strace mv. Here is the output. I don't really understand it a lot.

TheRookierLearner
  • 265
  • 1
  • 5
  • 12
  • Have you checked the hidden trash folders in your home as well as the other partition? – user68186 Apr 08 '14 at 19:41
  • I right-clicked and then saw "Properties" that gave me the free space. I guess that's the free space including the trash. – TheRookierLearner Apr 08 '14 at 19:44
  • Run dmesg | less in a Terminal, and see if you can find any meaningful info there. If there is nothing useful in there, go to your /var/log folder and try to find the culprit in the log files. They have meaningful names, so you get the idea which one to check out. (You can browse them with a gui tool, like sudo geany or sudo gedit, if you prefer that way. sudo ls /var/log will list you the log files.) – Apache Apr 08 '14 at 19:51
  • Please go into a terminal and add to the question the result of these two commands: df -h | grep -v '^none' and df -h -i | grep -v '^none'. This will give the account of space (the former) and inodes (basically, the number of files) of all filesystems excluding the virtual ones. – Rmano Apr 08 '14 at 20:34
  • @Rmano - Please see the edit. – TheRookierLearner Apr 08 '14 at 21:00
  • You have /host full, are you sure there is no need of it (like having some temporary directory in it)? --- Is /dev/loop0 an encrypted disk? I have little clue, it's quite a new configuration for me --- try to do strace cp ... to see exactly where it fails. Or maybe you have a big file open and deleted that is keep alive by some process and clogs you disk. Difficult to say. – Rmano Apr 08 '14 at 21:07
  • /dev/loop0 is not an encrypted disk. My Ubuntu is Wubi installed, though. I even restarted my laptop so I am not sure if the big file which, if at all might have been open, is still open now. – TheRookierLearner Apr 08 '14 at 21:10
  • I fired sudo strace mv .. but honestly I can't make a lot out of output. Mind if I paste the output to pastebin? – TheRookierLearner Apr 08 '14 at 21:16
  • Here is the output http://paste.ee/p/hic1K

    I don't really understand it a lot.

    – TheRookierLearner Apr 08 '14 at 21:35
  • What directory were you in when you ran that cp command? Was it /media/sda5? If so, try creating a subdirectory and copying the files there instead. – psusi Apr 09 '14 at 02:44
  • The android shared partition should have FAT32 filesystem. You should check it for errors in Windows using chkdsk. – Danatela Apr 09 '14 at 02:48
  • @psusi - I was in home directory when I tried that command. Also I am not able to create any file/directory in /media/sda5 – TheRookierLearner Apr 09 '14 at 02:49
  • @Danatela - Its NTFS. But thanks for the suggestion though. I'll do it. Will have to reboot my system. – TheRookierLearner Apr 09 '14 at 02:51
  • @Danatela - Woohoo! Thanks! That helped. I ran chkdsk E:/f in Windows in an administrative cmd shell(it was my E: drive) and indeed, it found some errors and fixed it. If you could write that as an answer, I'd gladly accept it. Also, I'm adding thw Wubi tag to my question because I think this is a Windows/Wubi specific problem – TheRookierLearner Apr 09 '14 at 04:27
  • Lots of files can fill up your inodes, check out the link - http://askubuntu.com/questions/231585/running-out-of-inodes – kingmilo Apr 09 '14 at 04:43
  • @kingmilo - True. But the df - i commands outputs that only 29% of my inodes are in use (see 1st edit) – TheRookierLearner Apr 09 '14 at 04:48
  • @TheRookierLearner kool, was just an fyi, it catches a lot of people out. – kingmilo Apr 09 '14 at 06:10

1 Answers1

1

When you cancel the copying of file there might appear a problem in the filesystem. So reboot into Windows and run

chkdsk /F <drive>

It should find and fix errors that can't be fixed inside Ubuntu.

Offtopic: I dream about such application that would scan disk in Ubuntu without need to boot Windows…

Danatela
  • 13,243
  • 11
  • 45
  • 72