I have file
/some/foo which is a plain text file. I can edit it with
vim and I can
cat something else to it. But whenever I try to automate the editing process with
sed, it says
sed: cannot move '/some/sedGl29Uj': Device or resource busy
I tried redirecting
sed's output to a temporary file and
cat, it's OK. But if I try to move the temporary file onto it, it will say
root@localhost:/some # mv tmp foo mv: Device or resource busy
I'm quite concerned why
cat can write the file but
Ubuntu 16.04.1 LTS.
/some is a subfolder of
/ (root mount point, ext4).