Accessing Terminal using SSH

Good day,

I have config “Advanced SSH & Web Terminal” as per some YouTube video’s.

Going to “Windows PowerSheel” at the cmd prompt, I enter:
PS C:\Users\user> ssh [email protected]

I have previously said yes to the lines followed

[email protected]’s password: entered my password
[\e]0;\u@\h:\w\a]\W $ ← this is what I get

What am I doing wrong? It is not showing the “Terminal” “front page”

If I am in HA and use “Terminal” it works fine, but not if I access it through Windows PowerShell, Putty or any of these types of programs.

My guess is an incorrect $TERM setting in PuTTY.

In the old days, terminals were hardware devices (CRT screen, keyboard, serial interface, later LAN) and worked differently - e.g. VT100 gave different characters than an xterm. Control characters like bold and colours were very likely to use different control codes. Software terminal emulators are the same - try VT100 or xterm or whatever and see if the \e\w\a disappears.

The thing is, it does the same with Windows Terminal. Most of the example I looked at, they used this and it worked fine when they show it in “YouTube”.

Like most things, it works fine in the example, but when I try it…

The $TERM will be wrong there as well - works fine on Linux with $TERM = xterm-256color which suggests the number of colours might be the issue.

There have been a few similar posts on this same issue suggesting something has changed recently.

FWIW, using Windows 11 built in ssh.exe to HAOS on port 22222 works fine and still correctly sets up the terminal. Maybe this is related to the Add-in. Technically, PowerShell is running the ssh.exe built in to Windows, just like cmd.exe would do.

You can add -vvv to the ssh command line and get debug output. You should see debug related to the terminal setup:

debug1: ENABLE_VIRTUAL_TERMINAL_INPUT is supported. Reading the VTSequence from console
debug3: This windows OS supports conpty
debug1: ENABLE_VIRTUAL_TERMINAL_PROCESSING is supported. Console supports the ansi parsing
debug3: Successfully set console output code page from:65001 to 65001
debug3: Successfully set console input code page from:437 to 65001

What does your version say?