I am new to linux.

I hope to install openvpn on my dedicated server. When I maked lzo/openvpn project, it said that there are 2 error, the reason is'No space left on device' I checked /tmp directory. The /tmp patrition space limitation is 1012M , used 925M

It looks like the directory/partrition is almost full.

What is the solution for this? clear /tmp directory or any other way?

Welcome any comment

Thanks interdev

link|improve this question
feedback

migrated from stackoverflow.com Dec 3 '10 at 7:56

This question came from our site for professional and enthusiast programmers.

7 Answers

For ways of safely tidying up /tmp, have a look at Wipe out /tmp every week? . Failing that, use du -sk /tmp/* | sort -n to identify the big files and subdirectories in your /tmp, and think carefully about what you can safely remove before doing so. There's no magic recipe to identifying what's safe to remove, but common sense and careful thought will help a lot.

link|improve this answer
feedback

You might also investigate if there is a binary package by the Distribution your Linux installation is based.

OpenVPN should be pretty common in modern distros.

Nothing to do with the primary question but might be helpful anyway

link|improve this answer
I used different version to install, same report – user62414 Dec 3 '10 at 8:16
feedback

This belongs on superuser, however you should just clear /tmp.

link|improve this answer
feedback

Could you sort files by size to view what is fulling your /tmp maybe some softwere usuing space on /tmp for logs

link|improve this answer
feedback

You could clear this directory :

echo "Emptying /tmp"
rm /tmp/* -rf &1>2 > /dev/null

You could also set TMPTIME=7 in /etc/default/rcS so that only stuff older than 7 days is deleted when you reboot.

link|improve this answer
Will the files in /tmp be removed automatically when rebooting the server? – user62414 Dec 3 '10 at 8:04
yes, with TMPTIME=7 files older than 7 days are automatically deleted every reboot – aleroot Dec 3 '10 at 9:43
it depends on the distro. – MadHatter Dec 3 '10 at 10:20
feedback

can you run "df -k /tmp" - is /tmp on the "/" filesystem , or is it on its own filesystem ? If it is on the "/" filesystem , its perfectly reasonable for it to be as large as this.

link|improve this answer
feedback

You don't know what files in /tmp may be in use by the system. Reboot first, then delete any files pre-dating the reboot from /tmp (or anything more than 1 day old). Then for good measure, reboot again.

Although for the longer term, you need to start keeping an eye on what files are in /tmp and work out why they're not getting cleared down automatically.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.