New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 810705 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Mar 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 3
Type: Bug

Blocked on:
issue 800049



Sign in to add a comment

add TERM=xterm-256color to the rootfs

Project Member Reported by kirtika@google.com, Feb 9 2018

Issue description

OS: R65/R66

Running 'top' fails with "'xterm-256color': unknown terminal type"
'export TERM=xterm' fixes this. Regression?

 

Comment 1 by kirtika@google.com, Feb 9 2018

Cc: grundler@chromium.org
Owner: vapier@chromium.org
Summary: top doesn't work on R65/R66 test images (was: top doesn)

Comment 2 by kirtika@google.com, Feb 9 2018

Description: Show this description
Blockedon: 800049
Labels: OS-Chrome
Status: Started (was: Untriaged)
Summary: add TERM=xterm-256color to the rootfs (was: top doesn't work on R65/R66 test images)
i'm assuming you're sshing into the device and not running it locally (e.g. via crosh).  in which case, this isn't a regression, and i think it's "always" been this way.

Secure Shell's default TERM is xterm-256color.  CrOS has never shipped that terminal setting (we've built ncurses with USE=minimal since at least 2010).  so if you ssh into the device, and run a program that queries the terminal settings (just about any ncurses program e.g. top), it will throw this error message.

if you normally ssh from a screen/tmux session you might not have noticed as those tend to default to TERM=screen which CrOS has shipped.

you can workaround it by manually running `TERM=xterm` on the system.

i already have a fix for this in progress via issue 800049, but it's been tricky getting it into the tree due to binpkgs.
Correct - she was using ssh and I am guessing the default terminal emulator (In my case that is "xcfe4-terminal" but "gnome-terminal-server" reports the same):

grundler@firesword:~$ env | fgrep TERM
COLORTERM=truecolor
TERM=xterm-256color


I've never run across this because I explicitly run xterm and thus:

<grundler> $ env | fgrep TERM
XTERM_SHELL=/bin/bash
XTERM_VERSION=XTerm(327)
TERM=xterm
XTERM_LOCALE=en_US.utf8

Components: Platform>Apps>Default>Hterm
Components: -Platform>Apps>Default>Hterm
not really an hterm issue.  you can see the same problem with other emulators like urxvt or xterm or whatever.
I run into this all the time using rodete + xfce4-terminal now. :-(

It looks like vapier added the -256color variants in the upstream ncurses-6.0-r2 ebuild.  If it's going to be a while before we can update to ncurses 6.x, would it be OK to apply the same change to the 5.9 ebuild?

http://crosreview.com/969413
Project Member

Comment 8 by bugdroid1@chromium.org, Mar 20 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/overlays/portage-stable/+/4b3f4e9f3d125669fbc8611488e2eb3aee9ca237

commit 4b3f4e9f3d125669fbc8611488e2eb3aee9ca237
Author: Kevin Cernekee <cernekee@chromium.org>
Date: Tue Mar 20 09:22:09 2018

sys-libs/ncurses: modernize the fallback terminal list

We drop "sun" and "xterm-xfree86" as it's unlikely anyone uses those
anymore in fallback scenarios.  We add {screen,xterm}-256color as those
are fairly common defaults.  The size delta is negligible.

Backported from upstream ncurses-6.0-r2 ebuild
(commit 961bf0f53a7ac66bd84021d8e5e093f54cf5d972).

BUG= chromium:810705 
TEST=`TERM=xterm-256color less /etc/lsb-release`

Change-Id: Iba658ae88d3b074ec8f91d831485fd10db4679e3
Reviewed-on: https://chromium-review.googlesource.com/969413
Commit-Ready: Kevin Cernekee <cernekee@chromium.org>
Tested-by: Kirtika Ruchandani <kirtika@chromium.org>
Reviewed-by: Jason Clinton <jclinton@chromium.org>
Reviewed-by: Vadim Bendebury <vbendeb@chromium.org>
Reviewed-by: Kirtika Ruchandani <kirtika@chromium.org>

[rename] https://crrev.com/4b3f4e9f3d125669fbc8611488e2eb3aee9ca237/sys-libs/ncurses/ncurses-5.9-r6.ebuild

Cc: vapier@chromium.org
Components: OS>Packages
Owner: cernekee@chromium.org
Status: Fixed (was: Started)
IIUC, this is fixed? (And much thanks!) Ongoing stuff in issue 800049.

Sign in to add a comment