Anonymous | Login | 2024-08-24 20:59 EDT | ![]() |
Main | My View | View Issues | Change Log | Roadmap |
View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | Project | Category | View Status | Date Submitted | Last Update | |||
0001490 | PacketFence | core | public | 2012-07-13 11:49 | 2012-09-06 10:57 | |||
Reporter | fgaudreault | |||||||
Assigned To | obilodeau | |||||||
Priority | normal | Severity | minor | Reproducibility | always | |||
Status | closed | Resolution | fixed | |||||
Platform | OS | OS Version | ||||||
Product Version | 3.3.2 | |||||||
Target Version | 3.5.1 | Fixed in Version | 3.5.1 | |||||
Summary | 0001490: pfdhcplistener watch will start instead of restart | |||||||
Description | Two things: - The watch will not restart unless ALL the pfdhcplistener daemons are crashed/not running - Instead of restarting the service when a daemon crashed, the watch will start new ones stacking the process (so you can end up with multiple listeners for the same interface) | |||||||
Additional Information | To fix it : In services.pm: $action eq "status" && do { my $pid; # Handle the pfdhcplistener case. Check how much internal interfaces + management we have, and if the number of pids # are not equals this (internal+management), then return 0 to force a restart. if ($exe ne "pfdhcplistener") { chop( $pid = `pidof -x $exe` ); $pid = 0 if ( !$pid ); } else { my @devs = get_internal_devs_phy(); my $numPids = $#devs+1; $pid = `pidof -x $exe`; my @pidArray = split(/ /, $pid); if ($#pidArray != $numPids) { $pid = 0 } } $logger->info("pidof -x $exe returned $pid"); return ($pid); } In bin/pfcmd: if ( lc($command) eq 'restart' ) { if ( lc($service) eq 'pf' ) { $logger->info( "packetfence restart ... executing stop followed by start"); local $cmd{command}[2] = "stop"; service(); local $cmd{command}[2] = "start"; service(); return 1; } else { if ( !pf::services::service_ctl( $service, "status" ) ) { $command = "restart"; } } } | |||||||
Tags | No tags attached. | |||||||
fixed in git revision | 2ac65663676178ef2ba5ca0cdf3311eda1953317 | |||||||
fixed in mtn revision | ||||||||
Attached Files | ||||||||
![]() |
|
(0002849) fgaudreault (viewer) 2012-07-19 11:28 |
Created a fix branch for that one. Merge it when able... |
(0002852) fgaudreault (viewer) 2012-07-30 14:54 |
Merged in Devel. |
(0002855) dwuelfrath (administrator) 2012-07-31 14:45 |
Fixed in 3.5.0 |
(0002944) obilodeau (reporter) 2012-08-17 09:08 |
Having issues with this patch if pfdhcplistener get stuck. Also I'm not sure about the 'restart' idea. It kept restarting *every* service every 5 minutes just because there was a single pfdhcplistener process stuck.. Investigating a little more before deciding what to do. |
(0002948) obilodeau (reporter) 2012-08-17 12:01 |
My previous comment about restarting everything is unrelated to the previous fix in that change, sorry about that. See 0001494. The real process management problem is that 3 hung pfdhcplisteners on eth0 is the same as 3 properly running dhcplisteners on eth0, eth0.10 and eth0.20. Now that I fixed 0001478, we should do a better job and check on what process each listeners runs. |
(0002949) obilodeau (reporter) 2012-08-17 14:04 |
We are now checking exactly for the interface name in the process listing. This way no hung unrelated listener can count as a "running listener" for another interface. See: https://github.com/inverse-inc/packetfence/pull/48 [^] |
(0003025) obilodeau (reporter) 2012-09-06 10:57 |
fix released in 3.5.1 yesterday |
![]() |
|||
Date Modified | Username | Field | Change |
2012-07-13 11:49 | fgaudreault | New Issue | |
2012-07-13 11:57 | fgaudreault | Tag Attached: Code Review | |
2012-07-13 11:57 | fgaudreault | Status | new => feedback |
2012-07-19 11:28 | fgaudreault | Note Added: 0002849 | |
2012-07-30 14:54 | fgaudreault | Note Added: 0002852 | |
2012-07-30 14:54 | fgaudreault | Status | feedback => resolved |
2012-07-30 14:54 | fgaudreault | Resolution | open => fixed |
2012-07-30 14:54 | fgaudreault | Assigned To | => fgaudreault |
2012-07-31 14:45 | dwuelfrath | Note Added: 0002855 | |
2012-07-31 14:45 | dwuelfrath | Fixed in Version | => 3.5.0 |
2012-07-31 14:45 | dwuelfrath | Tag Detached: Code Review | |
2012-08-06 16:40 | obilodeau | Status | resolved => closed |
2012-08-17 09:08 | obilodeau | Assigned To | fgaudreault => obilodeau |
2012-08-17 09:08 | obilodeau | Note Added: 0002944 | |
2012-08-17 09:08 | obilodeau | Status | closed => feedback |
2012-08-17 09:08 | obilodeau | Resolution | fixed => reopened |
2012-08-17 10:44 | obilodeau | Status | feedback => assigned |
2012-08-17 12:01 | obilodeau | Note Added: 0002948 | |
2012-08-17 14:04 | obilodeau | git revision | => 2ac65663676178ef2ba5ca0cdf3311eda1953317 |
2012-08-17 14:04 | obilodeau | Note Added: 0002949 | |
2012-08-17 14:04 | obilodeau | Status | assigned => resolved |
2012-08-17 14:04 | obilodeau | Fixed in Version | 3.5.0 => +1 |
2012-08-17 14:04 | obilodeau | Resolution | reopened => fixed |
2012-09-06 10:56 | obilodeau | Target Version | => 3.5.1 |
2012-09-06 10:56 | obilodeau | Fixed in Version | +1 => 3.5.1 |
2012-09-06 10:57 | obilodeau | Note Added: 0003025 | |
2012-09-06 10:57 | obilodeau | Status | resolved => closed |
Copyright © 2000 - 2012 MantisBT Group |