The OP asserts
Quote:just login as user pi through ssh and you will normal get this error. Especially when you have setup LC_ALL or LC_CTYPE in your remote environment. ssh is passing that environment partial to the client ( moode)
Actually, the ssh man page says (Linux Mint and RaspiOS, both based ultimately on Debian):
Code:
ssh will normally set the following environment variables:
...LANG and LC variables are not mentioned in the list, but then...
Additionally, ssh reads ~/.ssh/environment, and adds lines of the format
“VARNAME=value” to the environment if the file exists and users are al‐
lowed to change their environment. For more information, see the
PermitUserEnvironment option in sshd_config(5).
and on the moOde player, the sshd_config man page says
Code:
PermitUserEnvironment
Specifies whether ~/.ssh/environment and environment= options in
~/.ssh/authorized_keys are processed by sshd(8). Valid options
are yes, no or a pattern-list specifying which environment vari‐
able names to accept (for example "LANG,LC_*"). The default is
no. Enabling environment processing may enable users to bypass
access restrictions in some configurations using mechanisms such
as LD_PRELOAD.
Examining the /etc/ssh/sshd_conf file on the moOde player, I see the option in question is commented out
Code:
#PermitUserEnvironment no
hence, sshd chooses "no" by default.
I conclude the OP has been changing settings.
=====
As a check, first a look at my stock moOde player:
Code:
pi@moode3a:~ $ locale
LANG=en_GB.UTF-8
LANGUAGE=
LC_CTYPE="en_GB.UTF-8"
LC_NUMERIC="en_GB.UTF-8"
LC_TIME="en_GB.UTF-8"
LC_COLLATE="en_GB.UTF-8"
LC_MONETARY="en_GB.UTF-8"
LC_MESSAGES="en_GB.UTF-8"
LC_PAPER="en_GB.UTF-8"
LC_NAME="en_GB.UTF-8"
LC_ADDRESS="en_GB.UTF-8"
LC_TELEPHONE="en_GB.UTF-8"
LC_MEASUREMENT="en_GB.UTF-8"
LC_IDENTIFICATION="en_GB.UTF-8"
LC_ALL=
While for my Linux Mint box
Code:
kreed@xenon:~$ locale
LANG=en_US.UTF-8
LANGUAGE=en_US
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=
kreed@xenon:~$ ls -l .ssh/environment
ls: cannot access '.ssh/environment': No such file or directory
As expected from my reading of the man pages, and as Tim said, I don't see the issue when I ssh to a stock moOde player from the Linux Mint box.
======
Certainly one can get into interesting situations with locale settings. My thought is, wait for the problem actually to arise and then try the OP's solution.
Regards,
Kent