'top' util says: LinuxCNC AXIS process in 'D' state-uninterruptible sleep. What?

  • clunc
  • clunc's Avatar Topic Author
  • Offline
  • Elite Member
  • Elite Member
More
02 Jan 2023 15:33 #260770 by clunc
Trying to load the finish pass of the most complicated model[1] I have yet produced (~9M lines of G-code) caused the crash of Ubuntu.

Suspecting it had run out of memory, I begged a pair of 4GB sticks from a colleague, maxing the motherboard out to its 16GB, and rebooted.

When it came up I attempted the finish-pass load again, this time monitoring the memory usage with the utility 'inxi -m' which showed--indeed--that after it successfully loaded and displayed in LinuxCNC's AXIS interface, 9+GB were in-use.

Fine, okay, I went to bed. When I returned in the morning, LinuxCNC was not responsive to requests to load another model, the roughing pass. Investigating with the 'top' utility showed the 'axis' task using 60% of system memory (and I note in passing that 60% of 16GB is well over the 8GB original memory of the motherboard) and was also in the 'D' state , "uninterruptible sleep."  

"Uninterruptible" means the process can only be awakened by the process which put it to sleep: it ignores system signals--like 'hangup' and 'kill.'  It looks like linuxcnc is good-and-hung.

I'd like to know if anyone's seen this before, and if so how to deal with it.  I'll find out soon enough if linuxcnc enters 'D' after long inactivity or as soon as the finish pass is loaded, which would prevent its ever being executed, but until I find that out, has anyone else experienced this?

I'm chary of "adding more memory" because that would require replacing the motherboard, and the last time I was required to make a radical change to the controller a months'-long "wandering in the wilderness" trying to find my way back to 'Stable' ensued.
[1] "What possibly could explain ~9M lines of G-code?!" Topographic models.

Please Log in or Create an account to join the conversation.

More
02 Jan 2023 21:31 #260800 by PCW
Have you tried disabling the backplot?

Please Log in or Create an account to join the conversation.

  • clunc
  • clunc's Avatar Topic Author
  • Offline
  • Elite Member
  • Elite Member
More
02 Jan 2023 22:41 - 03 Jan 2023 13:11 #260806 by clunc
> Have you tried disabling the backplot? 
Peter, I haven't. 
Thank you for the good reminder, but I never even got a chance to run a line of code, so no backplot was created. 
 
"All I was trying to do" was open a different file, which led to it hanging.  Your suggestion led me to hunt up "Preview Control" in AXIS and I found the '(AXIS,*)' commands. I did need to see that the model loaded completely (namely that all of it could be seen), but having verified that, I don't need to see it the next time I load it to run it.

Now I'm curious to know what an
(AXIS,hide)
[code]line, after a few lines of the beginning of the model and an
[code](AXIS,show)
[code][code]line, a few lines before the end, will show.

My reading on the 'D'/uninterruptible sleep state said that the only way to wake it was to have the same process that put it to sleep send it a 'wake' signal.  For my part, I was able to kill linuxcnc and its child processes with 'kill -HUP'; I had expected 'axis' would not respond to any signals.

[b]EDIT: A problem with "killing" the running processes in my case at least was that "some thing" must have remained/not been cleaned up because every time LinuxCNC was opened afterwards, until I finally rebooted, the process 'axis', started by LinuxCNC, went quickly into the 'D' state. After reboot? problem wasn't there any longer.[/b]
[/code][/code][/code][/code]
 
Last edit: 03 Jan 2023 13:11 by clunc. Reason: Report followup experience.

Please Log in or Create an account to join the conversation.

  • clunc
  • clunc's Avatar Topic Author
  • Offline
  • Elite Member
  • Elite Member
More
03 Jan 2023 13:15 #260838 by clunc
(I have attempted to fix the Frankenstein formatting three times, but the linuxcnc.org editor is more determined than I am. Something I did set it against me.)

Please Log in or Create an account to join the conversation.

  • clunc
  • clunc's Avatar Topic Author
  • Offline
  • Elite Member
  • Elite Member
More
03 Jan 2023 14:10 #260842 by clunc
> Now I'm curious to know what an
>  (AXIS,hide)
>  (AXIS,show)
> will show...

I inserted them into the stock default demo program (/usr/share/axis/images/axis.ngc, iirc)[1] and got the result attached. I was still surprised.  And it works quite well with my uber-long program. 'top' reports that the 'axis' process settles into the 'S' mode
waiting for the execute command. AXIS now displays only the first and last 100 lines out of the nearly 9M. Considerably less loaded.

[1] I think every new user should try this just to be exposed to the functionality.[2]
[2] In fact, I think the code ought to be IN the default code, as it is in the attached.
Attachments:

Please Log in or Create an account to join the conversation.

Time to create page: 0.059 seconds
Powered by Kunena Forum