BOINC-AUSTRALIA FORUM

Members Only => ALL ABOUT HARDWARE => ALL THINGS LINUX => Topic started by: cruncher Pete on February 07, 2025, 01:32:31 PM

Title: Linux PC naming convention
Post by: cruncher Pete on February 07, 2025, 01:32:31 PM
All my windows machines have names and numbers.  The question is how do I do that in Linux. I have not found a way.  Can you help?
Title: Re: Linux PC naming convention
Post by: ryzenmulti on February 07, 2025, 02:28:42 PM
I think you are talking about 'hostname'? In a terminal window, type the hostname command to see what it is. Usually this is specified when you first install the linux o/s. It shows beside your username in a terminal as 'user@hostname'.

Is that what you want to reset? what flavour of linux are you running? (type 'uname -a' into a terminal)
Title: Re: Linux PC naming convention
Post by: cruncher Pete on February 07, 2025, 03:17:13 PM
Thanks, Ryzenmulty. As you observed I am not familiar with Linux although I have installed it on some machines.  I am just a set and forget type of a guy, clueless.  I now learned that I am talking about the Hostname.  I am using Linux Mint and what I am hoping to achieve is to show the hostname in the Taskbar permanently as in windows. and yes I wish to change the name of it as I moved it from its original location..
Title: Re: Linux PC naming convention
Post by: Abruraspingi on February 07, 2025, 10:53:32 PM
Don't forget to update the hostname in the hostname text file

It's located at
/etc/hostname

You want to update the next to
127.0.0.1
Title: Re: Linux PC naming convention
Post by: Dingo on February 08, 2025, 04:26:18 AM
CHANGE THE HOSTNAME 

In a terminal window

Find what hostname is
sudo hostnamectl

Change hostname
sudo hostnamectl set-hostname ENTER HOSTNAME HERE

Change the hostname in the host file
sudo nano /etc/hosts

Example of the line you need to change from my server

127.0.1.1 localhost parliamenthillottawa.com -->  Change parliamenthillottawa.com to your hostname

Confirm it is changed
sudo hostnamectl

To find the IP address try
ifconfig

The ip address is after the inet like this  inet 162.19.21.444

In the GUI it is

Select Start > Settings > Network & internet > Wi-Fi and then select the Wi-Fi network you're connected to.
Under Properties, look for your IP address listed next to IPv4 address.

Title: Re: Linux PC naming convention
Post by: cruncher Pete on February 08, 2025, 09:16:55 AM
Thanks Giles, but what do I do for the hostname to show up permanently in the Taskbar  or Desktop?
Title: Re: Linux PC naming convention
Post by: Dingo on February 08, 2025, 10:05:33 AM
Sorry I don't use a Linux GUI and don't use Linux Mint either, so I can't help.  I did a search and found this though.

https://www.youtube.com/watch?v=tE66Kc0djhY
Title: Re: Linux PC naming convention
Post by: ryzenmulti on February 10, 2025, 06:28:39 PM
Ok Cruncher Pete, you need to buckle up. You are asking for some advanced function there. If you right click your mouse on a blank area of the screen it should display a menu to open a terminal (called a bash window = exactly the same as a MSwindows command window, only completely backwards to someone not familiar with it).

You can do what you need via a widget called 'system monitor sensor'. Widgets are  little programs that can be run. If you search widget for mint linux system sensor you'll likely find what you need. Linux installs programs via a 'package manager' - some searching will show you how to use it.
Title: Re: Linux PC naming convention
Post by: cruncher Pete on February 10, 2025, 07:47:14 PM
Thanks Ryzenmulti. To me this is the reason that I do not like Linux.  It is too hard for an old fart like me.  I am just a button pusher. I like the idea in Windows that you can show your hostname in the taskbar.  It saves looking at other switches etc, it is there permanently.
Title: Re: Linux PC naming convention
Post by: ryzenmulti on February 11, 2025, 05:33:49 AM
Understood. A version of Linux runs on every supercomputer on the planet because of very low overhead. It's just not pretty. Microsuck is user friendly but bloated with all sorts of glittery overheads and monitoring. Linux is very hands on, and it is why people use it. Microsuck has even started to copy some of that and embedded a linux distro inside itself. Go figure.