gcc:设备上没有剩余空间? [英] gcc: No space left on device?
问题描述
我试图在Ubuntu 10中使用一个简单的gcc命令生成一些C代码,但是由于某种原因,我一直收到一个错误:
I'm trying to make some C code with a simple gcc command in Ubuntu 10, but for some reason, I keep getting an error:
Cannot create temporary file in /tmp/: No space left on device
事情是,虽然,我有足够的空间在磁盘上。这里是df -h的输出:
The thing is, though, I have plenty of space on the disk. Here is output of df -h:
Filesystem Size Used Avail Use% Mounted on
/ 3.7G 2.4G 1.1G 70% /
devtmpfs 312M 112K 312M 1% /dev
none 312M 24K 312M 1% /dev/shm
none 312M 80K 312M 1% /var/run
none 312M 0 312M 0% /var/lock
none 312M 0 312M 0% /lib/init/rw
和df -i,如果你想知道inode:
And df -i, in case you are wondering about the inodes:
Filesystem Inodes IUsed IFree IUse% Mounted on
/ 240960 195198 45762 82% /
devtmpfs 79775 609 79166 1% /dev
none 79798 3 79795 1% /dev/shm
none 79798 41 79757 1% /var/run
none 79798 2 79796 1% /var/lock
none 79798 1 79797 1% /lib/init/rw
我也可以 touch / tmp / test
成功,所以我知道我的驱动器上有空间。任何想法为什么gcc决定投入适应突然?
I can also touch /tmp/test
successfully, so I know I have space on the drive. Any ideas as to why gcc decided to throw a fit all of a sudden? (It was working earlier) Thanks beforehand.
推荐答案
在我看来,你的/ tmp目录实际上是作为一个 devtmpfs
如果我记得正确,实际上是你的电脑的RAM。
It looks to me that your /tmp directory is actually mounted as a devtmpfs
which if I remember correctly is actually your computer's RAM.
您可以随时重新启动,看看是否有帮助,增加虚拟内存分区,或者关闭正在运行的程序,看看是否有帮助。此外,您可以从/ tmp中删除一些不必要的文件,因为它们至少在会话的生命周期中是不稳定的。
You can always reboot and see if that helps, increase your virtual memory partition, or you can close running programs to see if that helps. Additionally, you can maybe delete some unnecessary files from /tmp as they are volatile to at least the life of the session.
这篇关于gcc:设备上没有剩余空间?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!