Just performed a shutdown/reboot in Xubuntu 12.04 LTS and when I got back, I had difficulty opening up Firefox, Software Center, and a bunch of stuff. Usually a log file was missing, a profile couldn't be found, and general input/output errors. Long story short, I found that the power-down was treated as an "improper crash" by Software Center and Firefox (both of which, should have been closed) and were locked by root. Why did that happen?
To expand: I did some digging and found that somehow root had possession of some folders. I double-checked this with Firefox (version 23) -- some files in /home/user/.mozilla/firefox/.default/ were locked by root. Using CHOWN -R user:user would only be a temporary fix until I ran Firefox again (which would have root repossess the files). I could sudo firefox from the CLI with no issues; it would even restore my last session.
Searching for more root-only folders in my home/user directory, I found a bunch in /home/user/.cache -- in fact, the software-center was no longer owned by user:user. Removing it with rm -rf gave me back Software Center (which was a relief, because sudo apt-get clean wasn't getting me anywhere). Removing the mozilla folder in .cache gave me back Firefox.
My questions are:
- Why did these cache folders cause issues with running these programs?
- Why were these cache folders under root instead of user?
- Why don't these files get flushed upon shut-down?