terminator doesn't exit cleanly, double launches (debian wheezy)

60 views
Skip to first unread message

Aryeh Leib Taurog

unread,
May 29, 2013, 4:01:00 PM5/29/13
to terminat...@googlegroups.com
I'm installing all my favorite packages on a relatively new wheezy box
and terminator is behaving very strangely.

After launching terminator I see both a ruby and a java process. If I
exit, the window disappears, but the processes don't. Then when I
launch terminator again, I get two windows (but only one additional
ruby and java process). If I kill off the old processes first then I
get only one window.

Here's a transcript, with logs:

altaurog@m92:~$ terminator &
[1] 5389
altaurog@m92:~$ /usr/bin/terminator:115: warning: assigned but unused variable - ex
/usr/share/software.jessies.org/terminator/Resources/salma-hayek/bin/invoke-java.rb:87: warning: assigned but unused variable - ex
/usr/share/software.jessies.org/terminator/Resources/salma-hayek/bin/invoke-java.rb:389: warning: assigned but unused variable - ex
/usr/bin/terminator:146:in `block in tryInAppServer': warning: URI.escape is obsolete
/usr/bin/terminator:146:in `block in tryInAppServer': warning: URI.escape is obsolete
/usr/bin/terminator:146:in `block in tryInAppServer': warning: URI.escape is obsolete
/usr/share/software.jessies.org/terminator/Resources/salma-hayek/bin/target-os.rb:17: Use RbConfig instead of obsolete and deprecated Config.
ps -F `pgrep -f terminator`
UID PID PPID C SZ RSS PSR STIME TTY STAT TIME CMD
altaurog 5389 2475 0 10200 7560 2 22:52 pts/3 Sl 0:00 /usr/bin/ruby -w /usr/bin/terminator
altaurog 5416 5389 4 418545 66644 3 22:52 pts/3 Sl 0:01 java -Xmx1g -Dorg.jessies.libraryDirectories=/usr/share/software.jessies.org/terminator/Resources/terminator/.generated/amd64_Linux/
altaurog@m92:~$ # here I typed 'exit' in the terminator window
altaurog@m92:~$ ps -F `pgrep -f terminator`
UID PID PPID C SZ RSS PSR STIME TTY STAT TIME CMD
altaurog 5389 2475 0 10200 7560 2 22:52 pts/3 Sl 0:00 /usr/bin/ruby -w /usr/bin/terminator
altaurog 5416 5389 2 418310 65728 3 22:52 pts/3 Sl 0:01 java -Xmx1g -Dorg.jessies.libraryDirectories=/usr/share/software.jessies.org/terminator/Resources/terminator/.generated/amd64_Linux/
altaurog@m92:~$ cat ~/.terminator/logs/terminator-5389.log
2013-05-29T22:52:38.445+0300 Terminator: Java 1.7.0_21 (VM 23.21-b01, runtime 1.7.0_21-b11)
2013-05-29T22:52:38.446+0300 Terminator: Linux 3.2.0-4-amd64/amd64 x8
2013-05-29T22:52:38.446+0300 Terminator: Revision 1641 (3267)
2013-05-29T22:52:38.446+0300 Terminator: Built 2012-01-17T09:21:16-08:00
2013-05-29T22:52:38.783+0300 Terminator: Created PtyProcess[pid=5443,fd=40,pty="/dev/pts/4"] and logging to /home/altaurog/.terminator/logs/2013-05-29T225238.765+0300-%2Fbin%2Fbash.txt
2013-05-29T22:52:38.975+0300 Terminator: echo localhost:35571 > /home/altaurog/.terminator/terminator-server-port_0.0
2013-05-29T22:53:25.678+0300 Terminator: Problem reading output from PtyProcess[pid=5443,fd=40,pty="/dev/pts/4"]
Associated exception:
java.io.IOException: read(40, buffer, 0, 8192) failed: Input/output error
at terminator.terminal.PtyProcess$PtyInputStream.read(PtyProcess.java:30)
at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:283)
at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:325)
at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:177)
at java.io.InputStreamReader.read(InputStreamReader.java:184)
at terminator.terminal.TerminalControl$ReaderRunnable.run(TerminalControl.java:152)
at java.lang.Thread.run(Thread.java:722)
2013-05-29T22:53:25.679+0300 Terminator: calling waitFor on PtyProcess[pid=5443,fd=40,pty="/dev/pts/4"]
2013-05-29T22:53:25.680+0300 Terminator: waitFor returned on PtyProcess[pid=5443,fd=-1,pty="/dev/pts/4",didExitNormally,exitValue=0]
altaurog@m92:~$ terminator &
[2] 5563
altaurog@m92:~$ /usr/bin/terminator:115: warning: assigned but unused variable - ex
/usr/share/software.jessies.org/terminator/Resources/salma-hayek/bin/invoke-java.rb:87: warning: assigned but unused variable - ex
/usr/share/software.jessies.org/terminator/Resources/salma-hayek/bin/invoke-java.rb:389: warning: assigned but unused variable - ex
/usr/bin/terminator:146:in `block in tryInAppServer': warning: URI.escape is obsolete
/usr/bin/terminator:146:in `block in tryInAppServer': warning: URI.escape is obsolete
/usr/bin/terminator:146:in `block in tryInAppServer': warning: URI.escape is obsolete
/usr/share/software.jessies.org/terminator/Resources/salma-hayek/bin/target-os.rb:17: Use RbConfig instead of obsolete and deprecated Config.
# now I got two windows
altaurog@m92:~$ ps -F `pgrep -f terminator`
UID PID PPID C SZ RSS PSR STIME TTY STAT TIME CMD
altaurog 5389 2475 0 10200 7560 2 22:52 pts/3 Sl 0:00 /usr/bin/ruby -w /usr/bin/terminator
altaurog 5416 5389 1 418545 67060 3 22:52 pts/3 Sl 0:01 java -Xmx1g -Dorg.jessies.libraryDirectories=/usr/share/software.jessies.org/terminator/Resources/terminator/.generated/amd64_Linux/
altaurog 5563 2475 0 10201 7552 6 22:54 pts/3 Sl 0:00 /usr/bin/ruby -w /usr/bin/terminator
altaurog 5607 5563 4 433898 67088 7 22:54 pts/3 Sl 0:01 java -Xmx1g -Dorg.jessies.libraryDirectories=/usr/share/software.jessies.org/terminator/Resources/terminator/.generated/amd64_Linux/
altaurog@m92:~$ cat ~/.terminator/logs/terminator-5563.log
2013-05-29T22:54:05.555+0300 Terminator: Java 1.7.0_21 (VM 23.21-b01, runtime 1.7.0_21-b11)
2013-05-29T22:54:05.556+0300 Terminator: Linux 3.2.0-4-amd64/amd64 x8
2013-05-29T22:54:05.557+0300 Terminator: Revision 1641 (3267)
2013-05-29T22:54:05.557+0300 Terminator: Built 2012-01-17T09:21:16-08:00
2013-05-29T22:54:05.887+0300 Terminator: Created PtyProcess[pid=5707,fd=41,pty="/dev/pts/5"] and logging to /home/altaurog/.terminator/logs/2013-05-29T225405.869+0300-%2Fbin%2Fbash.txt
2013-05-29T22:54:06.78+0300 Terminator: echo localhost:46697 > /home/altaurog/.terminator/terminator-server-port_0.0
altaurog@m92:~$ pkill -f terminator
altaurog@m92:~$ terminator >/dev/null 2>&1 &
[3] 5846
[1] Terminated terminator
[2] Terminated terminator
altaurog@m92:~$ # only one window


Martin Dorey

unread,
May 29, 2013, 4:28:42 PM5/29/13
to terminat...@googlegroups.com
Nice to see a familiar name, especially this time from a proper
operating system :). The main symptom, and the warnings in the logs,
tell me that this is a Ruby 1.9 interop problem that I fixed a couple
of weeks ago. The build date in your logs is over a year ago.
Perhaps you're still using software.jessies.org rather than
code.google.com? There's now a link from the header and footer at
software.jessies.org but this was a yet more recent development.
> --
> You received this message because you are subscribed to the Google Groups
> "terminator-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to terminator-use...@googlegroups.com.
> To post to this group, send email to terminat...@googlegroups.com.
> Visit this group at http://groups.google.com/group/terminator-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

--
Sent from my mobile device

Aryeh Leib Taurog

unread,
Jun 2, 2013, 7:32:08 AM6/2/13
to terminator-users
Just saw this--

On May 29, 11:28 pm, Martin Dorey <martindo...@gmail.com> wrote:
> Nice to see a familiar name, especially this time from a proper
> operating system :).  The main symptom, and the warnings in the logs,
> tell me that this is a Ruby 1.9 interop problem that I fixed a couple
> of weeks ago.  The build date in your logs is over a year ago.
> Perhaps you're still using software.jessies.org rather than
> code.google.com?  There's now a link from the header and footer at
> software.jessies.org but this was a yet more recent development.

Thanks! I installed the .deb on code.google.com. It doesn't double-
launch
anymore. I do still see a ruby process running as long as the java
process
is still running. Is that expected? (I seem to recall asking this
once
before, but I don't remember the conclusion). Also there is still an
IOException logged when I exit bash. Is that expected?

> On 5/29/13, Aryeh Leib Taurog <aryehl...@aryehleib.com> wrote:
>
>
>
>
>
>
>
>
>
> > I'm installing all my favorite packages on a relatively new wheezy box
> > and terminator is behaving very strangely.
>
> > After launching terminator I see both a ruby and a java process.  If I
> > exit, the window disappears, but the processes don't.  Then when I
> > launch terminator again, I get two windows (but only one additional
> > ruby and java process).  If I kill off the old processes first then I
> > get only one window.
>
> > Here's a transcript, with logs:
>
> > altaurog@m92:~$ terminator &
> > [1] 5389
> > altaurog@m92:~$ /usr/bin/terminator:115: warning: assigned but unused
> > variable - ex
> > /usr/share/software.jessies.org/terminator/Resources/salma-hayek/bin/invoke -java.rb:87:
> > warning: assigned but unused variable - ex
> > /usr/share/software.jessies.org/terminator/Resources/salma-hayek/bin/invoke -java.rb:389:
> > warning: assigned but unused variable - ex
> > /usr/bin/terminator:146:in `block in tryInAppServer': warning: URI.escape is
> > obsolete
> > /usr/bin/terminator:146:in `block in tryInAppServer': warning: URI.escape is
> > obsolete
> > /usr/bin/terminator:146:in `block in tryInAppServer': warning: URI.escape is
> > obsolete
> > /usr/share/software.jessies.org/terminator/Resources/salma-hayek/bin/target -os.rb:17:
> > /usr/share/software.jessies.org/terminator/Resources/salma-hayek/bin/invoke -java.rb:87:
> > warning: assigned but unused variable - ex
> > /usr/share/software.jessies.org/terminator/Resources/salma-hayek/bin/invoke -java.rb:389:
> > warning: assigned but unused variable - ex
> > /usr/bin/terminator:146:in `block in tryInAppServer': warning: URI.escape is
> > obsolete
> > /usr/bin/terminator:146:in `block in tryInAppServer': warning: URI.escape is
> > obsolete
> > /usr/bin/terminator:146:in `block in tryInAppServer': warning: URI.escape is
> > obsolete
> > /usr/share/software.jessies.org/terminator/Resources/salma-hayek/bin/target -os.rb:17:
> > For more options, visithttps://groups.google.com/groups/opt_out.

Martin Dorey

unread,
Jun 2, 2013, 2:32:40 PM6/2/13
to terminator-users
> I do still see a ruby process running as long as the java
> process is still running.  Is that expected?

The initial Ruby process certainly hangs around to report on any unexpected failure in the Java process.  Perhaps it was motivated by our struggles with Cygwin, with Java would sometimes exit with the only clue being the signal that it died with.

If you double-click the icon again, then the Ruby process that's initiated there will quit if it successfully manages to pass off the request to the existing Java process.

> Also there is still an IOException logged when I exit bash.  Is that expected?

I think so.  I certainly see it.  I guess it's hard for Terminator to tell when you exited it deliberately and when it disappeared underneath you.


Aryeh Leib Taurog

unread,
Jun 3, 2013, 7:50:38 AM6/3/13
to terminator-users
On Jun 2, 9:32 pm, Martin Dorey <martindo...@gmail.com> wrote:
> > I do still see a ruby process running as long as the java
> > process is still running.  Is that expected?
>
> The initial Ruby process certainly hangs around to report on any unexpected
> failure in the Java process.  Perhaps it was motivated by our struggles
> with Cygwin, with Java would sometimes exit with the only clue being the
> signal that it died with.
>
> If you double-click the icon again, then the Ruby process that's initiated
> there will quit if it successfully manages to pass off the request to the
> existing Java process.

I'm not sure I understand. If I launch more instances of terminator
I see an additional ruby process hanging around for each one (but only
one java process). On the other hand, if I select "New Shell" from
the file menu I get a new window but no new processes.

Martin Dorey

unread,
Jun 3, 2013, 12:19:12 PM6/3/13
to terminator-users
You do understand but I was flat wrong where we differed.  I was going to say that I was looking at the wrong piece of code, but even in the code I was looking at, there's an explanatory comment:

        # parseCommandLine now blocks until the requested window is closed.

So, sorry, it's now behaving as designed.


Reply all
Reply to author
Forward
0 new messages