Reinitializing LXTerminal without Rebooting

Stuck with a problem in your code? Seek help here.

Re: Reinitializing LXTerminal without Rebooting

Postby asheets » July 13th, 2017, 9:28 am

Not what I was expecting.... back to the drawing board...

evansste wrote:After running the short program overnight, LXterminal stopped working, as expected. <snip>
Posts: 306
Joined: February 17th, 2011, 4:30 pm

Re: Reinitializing LXTerminal without Rebooting

Postby bandersnatch » July 15th, 2017, 5:06 am

Hi Guys,

It's only a hunch but I suspect that the problem lies with the octave-cli script rather than in LXTerminal.
I agree with the comment from asheets that the shell script hangs due to a resource lack/conflict but
I reckon that this is caused by Octave/the Octave script...
Analysing the shell/process structure from the OS level might not give you enough information

Two approaches come to mind:
1/ Embed debugging logging in the Octave script to log execution of the script to a file.
With any luck you will see exactly where/why the script is hanging....
Start with coarse-grained logging & add more fine-grained logging when you know approximately where things are clogging up...

2/ Just out of curiosity, you could also set up Octave on an (e.g.) XP virtual machine (VMWARE/Virtual box.. whatever)
& see if you get the same problem with hanging after 24 hours.
If this also hangs then the problem is definitely in Octave/the Octave script & not LXTerminal/Lubuntu
If the script runs stably under XP then the problem is truely with lubuntu & we are "back to the drawing board"..;^)

You can also use the XP system monitor to track/graph the memory/io/processor usage of the script over days/weeks..
These graphs provide a quick and easy way of monitoring/examining the resource usage & trends of your Octave script.
If you see a curve that keeps rising then you can be sure that things will eventually come to a grinding halt.

The idea is to use the powerful monitoring tools in XP to tune your Octave script so that it remains stable in your lubunti enviroment..
The XP kernel is heavily influenced by VMS, and has hugely extended kernel monitoring features compared to the original Unix kernel...

Keep us posted on your progress ;^)

Posts: 150
Joined: September 17th, 2014, 12:06 pm

Re: Reinitializing LXTerminal without Rebooting

Postby evansste » July 15th, 2017, 6:29 am

Hello everyone.

Duplicating this scenario is extremely easy, and knowing what I did, specifically, may allow you to see the problem right away.

First, open octave. I always use the console, so I open LXterminal and type "octave-cli".

Then modify your .octaverc file by adding "exit;" to it. When finished, mine contains the following lines:

cd /home/evansste/octdir

Finally, type the following at the Octave prompt:

while 1;system('lxterminal -e octave-cli');pause(3);end

Once you hit "enter", Octave will open a new LXterminal every three seconds. The new terminal will immediately close. If you run this for a while, LXterminal will no longer work correctly. Opening a new LXterminal will mean opening a window that is blank. For me, I let it run overnight. The next morning, LXterminal wasn't working correctly.

The above is all I needed to do in order to re-create the situation. Maybe this will help you understand what the problem is.
Posts: 99
Joined: October 8th, 2014, 8:19 am


Return to Help Me! Software

Who is online

Users browsing this forum: No registered users and 1 guest