contrail-vrouter-agent:Agent introspect does not respond to request sometimes
Bug #1447937 reported by
Sandip Dey
This bug affects 2 people
Affects | Status | Importance | Assigned to | Milestone | ||
---|---|---|---|---|---|---|
Juniper Openstack | Status tracked in Trunk | |||||
R2.20 |
Fix Committed
|
High
|
Megh Bhatt | |||
Trunk |
Fix Committed
|
High
|
Megh Bhatt |
Bug Description
Request to <agent>:8085 getting stuck.
Its happening in sanity .
Reproduced the problem and showed to Manish/Hari
tags: | added: base |
summary: |
- contrail-vrouter-agent:Agent introspect does not respond to equest + contrail-vrouter-agent:Agent introspect does not respond to request sometimes |
Changed in juniperopenstack: | |
status: | New → In Progress |
information type: | Proprietary → Public |
tags: | added: analytics |
To post a comment you must log in.
copying debug info
we have taken a gcore of vrouter-agent and I have narrowed it down to issue because of following check-in /github. com/Juniper/ contrail- controller/ commit/ 902a5872d9c069a 5beb9d236e899f6 7a8605351b# diff-949e5ca38d fdab9ce14ec60e3 0fe211c
https:/
There is no task scheduled to process the entries in the concurrent queue request_queue in http session
And session just hangs.
This happens because checking for empty along with push/pop is not an atomic operation.
So it so happens that we check the queue to be not empty but while we try to enqueue an entry it was already empty because of the parallel task.
And after enqueue of this entry we don’t start a new task for the same.
Please find the debug info pasted below.
We should consider replacing this task creation and concurrent queue with a workqueue, if it helps ?
(gdb) p SandeshHttp::hServ_ intrusive_ ptr<TcpSession> ppl::concurrent _queue< HttpRequest* , tbb::cache_ aligned_ allocator< HttpRequest* > >) { :strict_ ppl::internal: :concurrent_ queue_base_ v3<HttpRequest* >> = { :strict_ ppl::internal: :concurrent_ queue_page_ allocator> = { vptr.concurrent _queue_ page_allocator = 0x1103770 ppl::internal: :concurrent_ queue_base_ v3<HttpRequest* >: ppl::concurrent _queue< HttpRequest* , tbb::cache_ aligned_ allocator< HttpRequest* > >: :allocator< char>> = { __gnu_cxx: :new_allocator< char>> = {<No data fields>}, <No data fields>}, string< char, std::char_ traits< char>, std::allocator< char> >::_Alloc_hider: 204.217. 75:8085: :10.204. 216.7:44164" :map_type *) 0x301aaf0 std::allocator< std::_Rb_ tree_node< std::pair< std::basic_ string< char, std::char_ traits< char>, std::allocator< char> > const, boost:: intrusive_ ptr<HttpSession > > > >> = {
<__gnu_ cxx::new_ allocator< std::_Rb_ tree_node< std::pair< std::basic_ string< char, std::char_ traits< char>, std::allocator< char> > const, boost:: intrusive_ ptr<HttpSession > > > >> = {<No data fields>}, <No data fields>}, tree<std: :basic_ string< char, std::char_ traits< char>, std::allocator< char> >, std::pair< std::basic_ string< char, std::char_ traits< char>, std::allocator< char> > const, boost:: intrusive_ ptr<HttpSession > >, std::_Select1st <std::pair< std::basic_ string< char, std::char_ traits< char>, std::allocator< char> > const, boost:: intrusive_ ptr<HttpSession > > >, std::less< std::basic_ string< char, std::char_ traits< char>, std::allocator< char> > >, std::allocator< std::pair< std::basic_ string< char, std::char_ traits< char>, std::allocator<...
$1 = (HttpServer *) 0x7ff59806dc50
(gdb) pset $1->session_ref_ boost::
elem[0]: $2 = {
px = 0x30720f0
}
Set size = 1
(gdb) p (HttpSession *) 0x30720f0
$3 = (HttpSession *) 0x30720f0
(gdb) p $3->request_
request_builder_ request_queue_
(gdb) p $3->request_queue_
$4 = (tbb::strict_
<tbb:
<tbb:
_
},
members of tbb::strict_
my_rep = 0x3093e00
},
members of tbb::strict_
my_allocator = {<No data fields>}
}
(gdb) p $3->context_
context_map_ context_str_
(gdb) p $3->context_str_
$5 = {
static npos = <optimized out>,
_M_dataplus = {
<std:
<
members of std::basic_
_M_p = 0x3041db8 "http%10.
}
}
(gdb) p $3->context_map_
$6 = (HttpSession:
(gdb) p *$3->context_map_
$7 = {
_M_t = {
_M_impl = {
<
members of std::_Rb_