Project

General

Profile

Bug #26403

Don't send email on authorized system reboot

Added by Jeff Alperin about 1 year ago. Updated about 1 year ago.

Status:
Resolved
Priority:
No priority
Assignee:
Vladimir Vinogradenko
Category:
GUI (new)
Target version:
Seen in:
Severity:
New
Reason for Closing:
Reason for Blocked:
Needs QA:
No
Needs Doc:
Yes
Needs Merging:
Yes
Needs Automation:
No
Support Suite Ticket:
n/a
Hardware Configuration:

Lenovo TS140, 16G memory, two mirrored drives (8TB and 6TB). System has been running FN releases for two plus years. 11.1 beta installed three days ago.

ChangeLog Required:
No

Description

Click Reboot in GUI left panel. Click Reboot in pop-up warning. System reboots, but sends email:

Subject: Unauthorized system reboot
Body: System booted at Sun Oct 29 17:39:15 2017 was not shut down properly.

Attached debug files taken before and after reboot.


Related issues

Related to FreeNAS - Feature #23361: Add unauthorized reboot e-mail alertResolved2017-04-14

Associated revisions

Revision 83854d51 (diff)
Added by Vladimir Vinogradenko about 1 year ago

fix(middleware): Fix middleware hang on devd stop

Ticket: #26403

History

#1 Updated by Eric Loewenthal about 1 year ago

With the old GUI?

#2 Updated by Jeff Alperin about 1 year ago

Yes. Old GUI (I'm a troglodyte).

#3 Updated by Dru Lavigne about 1 year ago

  • Assignee changed from Release Council to Vladimir Vinogradenko
  • Private changed from No to Yes

#4 Updated by Dru Lavigne about 1 year ago

  • Related to Feature #23361: Add unauthorized reboot e-mail alert added

#5 Updated by Vladimir Vinogradenko about 1 year ago

  • Status changed from Unscreened to 15
  • Assignee changed from Vladimir Vinogradenko to William Grzybowski

After we stop devd, /var/run/devd.seqpacket.pipe is being kept. Because no one is on the writing side, https://github.com/freenas/freenas/blob/master/src/middlewared/middlewared/plugins/device.py#L80 returns None immediately and devd_listen restarts immediately leaving asyncio no chance to execute other tasks. So, after devd stops, middleware hangs completely — it does not process incoming requests and also has no opportunity to terminate properly.

I think we can just add await asyncio.sleep(1) before break, or it is not there for reason?

#6 Updated by William Grzybowski about 1 year ago

  • Assignee changed from William Grzybowski to Vladimir Vinogradenko

Isso no reason to not do that but I am unsure of the problem. Shouldn't the "await read" and/or "await asyncio.open_unix_connection" give a chance for that to happen?

I am think the real problem here is that its looping non-stop because line = b'' and we should really change from "if line is None:" to "if line == b'':" or "if not line:" ?

#7 Updated by Vladimir Vinogradenko about 1 year ago

  • Status changed from 15 to Needs Developer Review
  • Assignee changed from Vladimir Vinogradenko to William Grzybowski

William, you are absolutely right!

#8 Updated by William Grzybowski about 1 year ago

  • Status changed from Needs Developer Review to Reviewed by Developer
  • Assignee changed from William Grzybowski to Vladimir Vinogradenko

#9 Updated by Dru Lavigne about 1 year ago

  • Status changed from Reviewed by Developer to 46

Vladimir: what is the target date for this one?

#10 Updated by Vladimir Vinogradenko about 1 year ago

  • Status changed from 46 to Ready For Release
  • Target version set to 11.1

Dru: merged both in master and 11.1-stable

#11 Updated by Dru Lavigne about 1 year ago

  • File deleted (debug-ts140-20171029151609.tgz)

#12 Updated by Dru Lavigne about 1 year ago

  • File deleted (debug-ts140-20171029152041.tgz)

#13 Updated by Dru Lavigne about 1 year ago

  • Subject changed from Unauthorized system reboot to Don't send email on authorized system reboot

#14 Updated by Dru Lavigne about 1 year ago

  • Private changed from Yes to No

#15 Updated by Bonnie Follweiler about 1 year ago

  • Needs QA changed from Yes to No
  • QA Status Test Passes FreeNAS added
  • QA Status deleted (Not Tested)

#16 Updated by Dru Lavigne about 1 year ago

  • Target version changed from 11.1 to 11.1-RC2

#17 Updated by Dru Lavigne about 1 year ago

  • Target version changed from 11.1-RC2 to 11.1-RC3

#18 Updated by Dru Lavigne about 1 year ago

  • Status changed from Ready For Release to Resolved

#19 Updated by Jeff Alperin about 1 year ago

I installed 11.1-RC3 and do not get the emails now when rebooting. Thank you.

Also available in: Atom PDF