Linux/General Server Management: Difference between revisions
< Linux
Jump to navigation
Jump to search
Brodriguez (talk | contribs) m (Brodriguez moved page Linux/Datetime Management to Linux/General Server Management) |
Brodriguez (talk | contribs) (Add hostname values) |
||
Line 1: | Line 1: | ||
== View Current System Timezone == | == HostName Management == | ||
The '''HostName''' is the value that displays such as when connecting via an ssh terminal. | |||
=== Display Current HostName === | |||
hostname | |||
To view additional information, use: | |||
hostnamectl | |||
=== Change HostName === | |||
sudo hostnamectl set-hostname <desired_new_name> | |||
== Datetime Management == | |||
These commands control what datetime your system uses. | |||
=== View Current System Timezone === | |||
cat /etc/timezone | cat /etc/timezone | ||
== View Current System Date == | === View Current System Date === | ||
date | date | ||
== Set System Timezone == | === Set System Timezone === | ||
sudo timedatectl set-timezone <timezone> | sudo timedatectl set-timezone <timezone> | ||
For example: | For example: | ||
sudo timedatectl set-timezone America/New_York | sudo timedatectl set-timezone America/New_York |
Latest revision as of 01:23, 7 May 2023
HostName Management
The HostName is the value that displays such as when connecting via an ssh terminal.
Display Current HostName
hostname
To view additional information, use:
hostnamectl
Change HostName
sudo hostnamectl set-hostname <desired_new_name>
Datetime Management
These commands control what datetime your system uses.
View Current System Timezone
cat /etc/timezone
View Current System Date
date
Set System Timezone
sudo timedatectl set-timezone <timezone>
For example:
sudo timedatectl set-timezone America/New_York