-
-
Notifications
You must be signed in to change notification settings - Fork 223
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Segfault when detaching after deleting shadow on Classic #7514
Comments
What FB version? |
Firebird 3.0 |
I'm sorry, the stack related to a different version. Here is the stack for Firebird 3.0: libEngine12.so!Jrd::Attachment::createPool(Jrd::Attachment * const this) (src\jrd\Attachment.cpp:115)
libEngine12.so!CMP_compile2(Jrd::thread_db * tdbb, const UCHAR * blr, ULONG blr_length, bool internal_flag, ULONG dbginfo_length, const UCHAR * dbginfo) (src\jrd\cmp.cpp:167)
libEngine12.so!Jrd::AutoRequest::compile(Jrd::AutoRequest * const this, Jrd::thread_db * tdbb, const UCHAR * blr, ULONG blrLength) (src\jrd\exe_proto.h:170)
libEngine12.so!MET_get_shadow_files(Jrd::thread_db * tdbb, bool delete_files) (temp\Debug\jrd\met.cpp:5987)
libEngine12.so!SDW_get_shadows(Jrd::thread_db * tdbb) (src\jrd\sdw.cpp:584)
libEngine12.so!CCH_fetch_lock(Jrd::thread_db * tdbb, Jrd::WIN * window, int lock_type, int wait, SCHAR page_type) (src\jrd\cch.cpp:797)
libEngine12.so!CCH_fetch(Jrd::thread_db * tdbb, Jrd::WIN * window, int lock_type, SCHAR page_type, int wait, const bool read_shadow) (src\jrd\cch.cpp:730)
libEngine12.so!CCH_FETCH(Jrd::thread_db * tdbb, Jrd::win * window, USHORT lock_type, SCHAR page_type) (src\jrd\cch_proto.h:84)
libEngine12.so!TRA_update_counters(Jrd::thread_db * tdbb, Jrd::Database * dbb) (src\jrd\tra.cpp:832)
libEngine12.so!JRD_shutdown_database(Jrd::Database * dbb, const unsigned int flags) (src\jrd\jrd.cpp:6711)
libEngine12.so!purge_attachment(Jrd::thread_db * tdbb, Jrd::StableAttachmentPart * sAtt, unsigned int flags) (src\jrd\jrd.cpp:7162)
libEngine12.so!Jrd::JAttachment::freeEngineData(Jrd::JAttachment * const this, Firebird::CheckStatusWrapper * user_status, bool forceFree) (src\jrd\jrd.cpp:2953)
libEngine12.so!Jrd::JAttachment::detach(Jrd::JAttachment * const this, Firebird::CheckStatusWrapper * user_status) (src\jrd\jrd.cpp:2913)
libEngine12.so!Firebird::IAttachmentBaseImpl<Jrd::JAttachment, Firebird::CheckStatusWrapper, Firebird::IReferenceCountedImpl<Jrd::JAttachment, Firebird::CheckStatusWrapper, Firebird::Inherit<Firebird::IVersionedImpl<Jrd::JAttachment, Firebird::CheckStatusWrapper, Firebird::Inherit<Firebird::IAttachment> > > > >::cloopdetachDispatcher(Firebird::IAttachment * self, Firebird::IStatus * status) (src\include\firebird\IdlFbInterfaces.h:9081)
libfbclient.so.2!Firebird::IAttachment::detach<Firebird::CheckStatusWrapper>(Firebird::IAttachment * const this, Firebird::CheckStatusWrapper * status) (src\include\firebird\IdlFbInterfaces.h:1964)
libfbclient.so.2!Why::YAttachment::detach(Why::YAttachment * const this, Firebird::CheckStatusWrapper * status) (src\yvalve\why.cpp:5464)
libfbclient.so.2!Firebird::IAttachmentBaseImpl<Why::YAttachment, Firebird::CheckStatusWrapper, Firebird::IReferenceCountedImpl<Why::YAttachment, Firebird::CheckStatusWrapper, Firebird::Inherit<Firebird::IVersionedImpl<Why::YAttachment, Firebird::CheckStatusWrapper, Firebird::Inherit<Firebird::IAttachment> > > > >::cloopdetachDispatcher(Firebird::IAttachment * self, Firebird::IStatus * status) (src\include\firebird\IdlFbInterfaces.h:9081)
Firebird::IAttachment::detach<Firebird::CheckStatusWrapper>(Firebird::IAttachment * const this, Firebird::CheckStatusWrapper * status) (src\include\firebird\IdlFbInterfaces.h:1964)
rem_port::end_database(rem_port * const this, PACKET * sendL) (src\remote\server\server.cpp:3075)
process_packet(rem_port * port, PACKET * sendL, PACKET * receive, rem_port ** result) (src\remote\server\server.cpp:4481)
loopThread() (src\remote\server\server.cpp:6032)
(anonymous namespace)::ThreadArgs::run((anonymous namespace)::ThreadArgs * const this) (src\common\ThreadStart.cpp:78)
(anonymous namespace)::threadStart(void * arg) (src\common\ThreadStart.cpp:94)
libpthread.so.0!start_thread (Unknown Source:0)
libc.so.6!clone (Unknown Source:0)](url) |
Did not reproduce. |
Weird, I get this in the log on Classic with the test.
As I see it, the problem is that fbt transaction disconnects at the same time as the commit of the isql transaction.
|
OK, when we deal with races it's not guranteed to be reproduced on different HW. Will have to use long way to fix. |
HEAD
Dumbs: https://drive.google.com/drive/folders/1Elfi20dq5XmJNoD7ByhNecLOI1YBGRpE?usp=sharing |
May be I was not enough explicit - I need binaries, src is not enough to analyze core dump. |
Sorry, missed that one. I've uploaded the binaries at the Disk (the same link) |
shadowsShutdown.patch.gz |
The fix has helped. Thanks |
The easiest way to reproduce it is fbtest
The stack:
The text was updated successfully, but these errors were encountered: