FQDN in bash prompt

I want to have a way to determine which OSMC (in different locations) I am logged in by SSH.
So changed /etc/bash.bashrc to PS1='${debian_chroot:+($debian_chroot)}\u@\H:\w\$ ' but no success still only display the hostname.

Do they all have the same hostname?

Yes, they are all have the hostname (OSMC) as I don’t want it to be different approach in each location. Therefore I just want the bash to display the respective domain (.germany .hongkong) which are the local search domains.

But it seems when logging in with SSH the bash.bashrc is not consulted

What do you get if you type hostname -f from a shell?

osmc@osmc:~$ hostname --short
osmc
osmc@osmc:~$ hostname --fqdn
osmc.hongkong
osmc@osmc:~$ hostname --domain
hongkong

That looks OK. Maybe you need to change the PS1 in the osmc users .bashrc file.

Just to confirm, I changed the /etc/bash.bashrc file on my Pi, and no change to PS1. Changed in in the osmc user .bashrc and it works.

Yeah, I can confirm changing the user bashrc worked. So seems no templating of /etc/bash.bashrc

I’m pretty sure that’s how it’s supposed to work. If you don’t have a .bashrc, then the system one is used. If you delete the PS1 lines from the .bashrc the system ones may work (I’m not sure if it loads the system bashrc and the the .bashrc, or just the .bashrc if it exists)

Yep you are most likely correct, I just was coming from the behaviour on one of my other Linux systems.