Disable tab discarding for nassh/crosh

21 views
Skip to first unread message

Pat Grasso

unread,
Jan 30, 2018, 12:28:59 AM1/30/18
to chromium-hterm
Hello all,

I frequently utilize crosh in order to run crouton on my Chromebook, which serves my needs well. However, due to the severe memory constraints imposed by the hardware in my Chromebook (I believe this model is among the cheapest available), I often run into issues with chrome's automatic tab discarder. More specifically, while inside a chroot session using crosh and simultaneously doing work in other tabs, chrome will spontaneously kill my crosh tab! As a result, all of the sub-processes spawned within the hterm shell remain alive but inaccessible once the page reloads.

I would really like for tabs containing crosh/nassh to not be automatically discarded. After a bit of searching, I came across the extension docs for tabs and found the autoDiscardable property, which appears to accomplish this.

I've cloned and updated nassh (and crosh) to utilize this feature, but wanted to see if anybody had suggestions before I submit the patch.

Mike Frysinger

unread,
Jan 30, 2018, 2:23:55 PM1/30/18
to Pat Grasso, chromium-hterm
i'm not sure if that'll work, but might be worth a try

in the mean time, you could run screen/tmux first and then do everything inside of that, then you could resume it easily even if crosh was killed

do you get different behavior if you launch crosh via the Secure Shell app rather than using ctrl+alt+t ?  set the hostname to ">crosh" to connect.
-mike

--
You received this message because you are subscribed to the Google Groups "chromium-hterm" group.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-hterm/ded61a37-4ebb-406c-9b60-3ed7a6fa7bb8%40chromium.org.

Pat Grasso

unread,
Jan 30, 2018, 4:12:08 PM1/30/18
to chromium-hterm, patg...@gmail.com
in the mean time, you could run screen/tmux first and then do everything inside of that, then you could resume it easily even if crosh was killed

I had considered this, but avoided it due to my inability to get tmux working with truecolor. Due to your suggestion, I again attempted to find a solution and managed to get it working! Although, there's still the matter of orphan processes created by crouton and the minor annoyance of restarting the session. The latter problem is more manageable with the use of tmux/screen.
 
do you get different behavior if you launch crosh via the Secure Shell app rather than using ctrl+alt+t ?  set the hostname to ">crosh" to connect.

Before changes, I am still able to force crosh to be discarded when started this way (by exhausting memory). After changes, I am not.

- Pat Grasso
Reply all
Reply to author
Forward
0 new messages