rename cmd (c++) behavior on ESS

shibboleth

Junior Member
Jul 23, 2007
3
0
0
on an ESS, rename will occasionally report successful status, but this is misleading as one particular symptom seems to suggest: in my application, the next action after a rename is to get a file handle, and rarely this will result in "file not found". the same application is run on a single filesystem & this never happens.

is this due to what i perceive to be that rename merely makes a new link (or shadow), and then forks the actual move, which is rarely incompleted before parent process attempts to define a file handle for the new location?

this scenario is extremely difficult to faithfully reproduce
 

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
You should probably tell us what an ESS is before we can make any educated guesses. But AFAIK a rename should be a single syscall and thus atomic within the app calling rename(2). Even if the rename operation created a hard link with the new name and then removes the old name in two operations the file will just be available under both names for a small amount of time, there is no data moved during a rename unless you're moving across filesystems and then it's equivalent to a copy and delete.
 

shibboleth

Junior Member
Jul 23, 2007
3
0
0
right, sorry. ESS: IBM's implementation of a very large enterprise storage "array".

i agree rename should be a vanilla syscall, but i think it's forking. my recent experience w/ similar coding in java has indicated you can choose whether or not to block at this call. because this is a c++ thing, all documentation suggests (but does not explicitly say) this blocks until ERRNO is assigned a value, and thusly this called is blocked. but as indicated, i can (rarely) reproduce a symptom to suggest this is a forked call - and now i'm deeply in the realm of eSpeculating - the return code is from a successful call to fork. and again, yes, i agree that across file systems it's equivalent to cp & then rm.

IBM advertises their ESS is transparent, and all applications implementing what are in effect OS built-ins should not have unexpected/unanticipated behavior [citation desperately lacking]
 

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
Can you run the app through strace, that should tell you whether it's forking or not. If you're just doing 'mv' on the cli then it's definitely not forking.
 

shibboleth

Junior Member
Jul 23, 2007
3
0
0
ah yes. using truss, it seems to be the case it's a direct kernel/system call, and not a forked-to-unix-mv call.

mystery remains as to why immediately following a reported failure to rename a subsequent rename always succeeds. sadly, the design must stand; so off i kluge.

thanks for responding.
 
sale-70-410-exam    | Exam-200-125-pdf    | we-sale-70-410-exam    | hot-sale-70-410-exam    | Latest-exam-700-603-Dumps    | Dumps-98-363-exams-date    | Certs-200-125-date    | Dumps-300-075-exams-date    | hot-sale-book-C8010-726-book    | Hot-Sale-200-310-Exam    | Exam-Description-200-310-dumps?    | hot-sale-book-200-125-book    | Latest-Updated-300-209-Exam    | Dumps-210-260-exams-date    | Download-200-125-Exam-PDF    | Exam-Description-300-101-dumps    | Certs-300-101-date    | Hot-Sale-300-075-Exam    | Latest-exam-200-125-Dumps    | Exam-Description-200-125-dumps    | Latest-Updated-300-075-Exam    | hot-sale-book-210-260-book    | Dumps-200-901-exams-date    | Certs-200-901-date    | Latest-exam-1Z0-062-Dumps    | Hot-Sale-1Z0-062-Exam    | Certs-CSSLP-date    | 100%-Pass-70-383-Exams    | Latest-JN0-360-real-exam-questions    | 100%-Pass-4A0-100-Real-Exam-Questions    | Dumps-300-135-exams-date    | Passed-200-105-Tech-Exams    | Latest-Updated-200-310-Exam    | Download-300-070-Exam-PDF    | Hot-Sale-JN0-360-Exam    | 100%-Pass-JN0-360-Exams    | 100%-Pass-JN0-360-Real-Exam-Questions    | Dumps-JN0-360-exams-date    | Exam-Description-1Z0-876-dumps    | Latest-exam-1Z0-876-Dumps    | Dumps-HPE0-Y53-exams-date    | 2017-Latest-HPE0-Y53-Exam    | 100%-Pass-HPE0-Y53-Real-Exam-Questions    | Pass-4A0-100-Exam    | Latest-4A0-100-Questions    | Dumps-98-365-exams-date    | 2017-Latest-98-365-Exam    | 100%-Pass-VCS-254-Exams    | 2017-Latest-VCS-273-Exam    | Dumps-200-355-exams-date    | 2017-Latest-300-320-Exam    | Pass-300-101-Exam    | 100%-Pass-300-115-Exams    |
http://www.portvapes.co.uk/    | http://www.portvapes.co.uk/    |