Link two directories
am 14.04.2008 12:07:20 von MikeHi,
I am running out of space on my /tmp directory. But my /local/scratch
is almost empty.
How can I link my /tmp to store on /local/scratch instead?
cheers,
//mike
Hi,
I am running out of space on my /tmp directory. But my /local/scratch
is almost empty.
How can I link my /tmp to store on /local/scratch instead?
cheers,
//mike
On Apr 14, 3:07=A0pm, mike
> Hi,
>
> I am running out of space on my /tmp directory. But my /local/scratch
> is almost empty.
> How can I link my /tmp to store on /local/scratch instead?
>
> cheers,
>
> //mike
Create a link to /loca/scratch from /tmp as shown:
# ln -s /local/scratch /tmp/scratch
Now all the contents that you put in /tmp/scratch will land in /local/
scratch.
- Fazlin
mike scrisse:
> I am running out of space on my /tmp directory.
# rm -fr /tmp/*
**BEWARE** you are root!
It is nice doing this in single user mode or in init scripta.
> ...
> How can I link my /tmp to store on /local/scratch instead?
Wrong way!
The right way is clean up /tmp on boot or on shutdown so
you have a clean system oat starup.
That if you have a simple desktop, for a server that you
never shutdown you can contemplate adding a cron job that
periodically clean up /tmp directory.
mike
> How can I link my /tmp to store on /local/scratch instead?
Some applications will use another directory instead of /tmp. It
might be a command line option, or by setting the TMPDIR environment
variable.
2 more cents, do not forget to look fot "dot" files, stuff
like .X11*, try a `ls -la` or
my fav, `find /tmp -ls `, they may be the cause of your space issues.,
JB
mallin.shetland wrote:
> mike scrisse:
> > I am running out of space on my /tmp directory.
>
> # rm -fr /tmp/*
>
> **BEWARE** you are root!
>
> It is nice doing this in single user mode or in init scripta.
>
>
> > ...
> > How can I link my /tmp to store on /local/scratch instead?
>
> Wrong way!
>
> The right way is clean up /tmp on boot or on shutdown so
> you have a clean system oat starup.
>
> That if you have a simple desktop, for a server that you
> never shutdown you can contemplate adding a cron job that
> periodically clean up /tmp directory.