I want to work from home via SSH.
I run Ubuntu. I have installed sshfs and mounted my files locally. However, working on local files is too slow, as sshfs fetches files each time it wants to read it.
How can I put everything into cache ?
I want to work from home via SSH.
I run Ubuntu. I have installed sshfs and mounted my files locally. However, working on local files is too slow, as sshfs fetches files each time it wants to read it.
How can I put everything into cache ?
Use the cache timeout parameter and set it to a big value (several hours) :
sshfs -C -o cache_timeout=80000 myself@work:~/files_at_work ~/my_home
Then, use this script to fetch all the files and put them into the cache :
#!/bin/bash
for file in `find .`
do
echo "$file"
cat $file > /dev/null
done