Well this problem is now solved. A very strange error I must say. @lesley pointed me in the right direction. I can say it had nothing to do with permissions.
I use webmin as CP. Somethingf happened during last update. The VPS has 1 domain and the setting has been that the domain has unlimited disk space. The shop take about 21 Gb and the disk is 1 TB.
When I checked the suotes for the domain I discovered that the disk quota for the domain was set to 1 Gb. Shop works as normal.
Anyway, when I set the quota to unlimited all the errors disappeared.
One warning. I was advised to delete 2 folders in the Smarty folder. I tried that a couple of times and tb just chrashed. I also tested it after I fixed the problems. The same crash. They folders will not be recreated and a backup need to be restored or as I do it, roll back a snapshot