From: Stelian P. <st...@po...> - 2005-01-12 22:18:49
|
On Wed, Jan 12, 2005 at 01:40:47PM -0800, Kenneth Porter wrote: > --On Tuesday, January 11, 2005 3:33 PM -0800 Kenneth Porter > <sh...@se...> wrote: > > >restore: cannot rename ./var/lib/mysql to ./var/lib/RSTTMP06373651: > >Permission denied > > Looks like this code also exists in 0.4b37, so perhaps it's not getting > triggered when I run that version of restore. In any case, when doing a > compare, nodeupdates() shouldn't be making filesystem changes no matter > what input it gets from the dump file. It looks like renameit() needs to > check for command == 'C'. I'm not sure if this breaks mktempname() and if > that needs attention as well. I think you got it. I believe this could be related to some changes I made in 0.4b38 to improve the comparision (before 0.4b38, only files were compared, directory weren't, so a change in the ownership of a directory was not reported by restore -C). While implementing this, I reused some code and it appears that this code requires some sort of write access. I'll look at this more in detail tomorrow. > While checking this as a mortal I realized that restore can't dump core > when it can't write to the root of the target filesystem. It might be > desirable to have panic() chdir to /tmp or to the directory the program > started from before aborting. chdir() back to the original directory seems to be indeed the right way. Stelian. -- Stelian Pop <st...@po...> |