`
SilverRing
  • 浏览: 73437 次
社区版块
存档分类
最新评论

[linux] Adjust Time

阅读更多
We use the command below to find out the current system time:

date


If it's incorrect and we wish to change it, we can issue a command below:

date nnddhhmm[[cc]yy][.ss]


where

    nn = month of the year (01 to 12)
    dd = day of the month (01 to 31)
    hh = hour of the day (00 to 23)
    mm = minute of the hour (00 to 59)
    cc = The first to digits of the year
    yy = The last two digits of the year
    .ss = The seconds

Here's the command to find out the hardware clock:

hwclock --show


To make it consistent with the system time, command like this:

hwclock --hctosys


If we wanna keep it on time automatically, install ntp.
分享到:
评论

相关推荐

    linux ntp时间同步设置

    24 May 08:57:40 ntpdate[1920]: adjust time server 182.92.12.11 offset -0.004755 sec ``` 这表示系统时间已调整至与服务器 `182.92.12.11` 的时间相差 `-0.004755` 秒。 如果 `ntp.api.bz` 无法连接,还可以...

    Linux基本命令,初学linux必备的东西

    例如,`ntpdate 10.161.8.200`将时间同步到指定的NTP服务器,出现“adjust time”表示同步成功。 8. **系统日志查看**:系统日志文件位于`/var/log/messages`。可以先`cd`进入`/var/log`目录,然后使用`vi`查看日志...

    Linux时间同步的2种方法

    由于硬件的原因,机器或多或少的根标准时间对不上,一个月的误差几秒到几分钟不等。对于服务器来说时间不准,会有很多麻烦。例如,支付的时候,无法下单,游戏...  22 Oct 21:11:43 ntpdate[5014]: adjust time serve

    NTP客户端配置-linux.docx

    如果同步成功,将显示调整时间服务器的offset值,例如`adjust time server 172.18.10.251 offset -0.001468 sec`。如果同步失败,将显示`no server suitable for synchronization found`。 6. 设置开机自启动 在...

    hwclock linux 时钟

    硬件时钟是一个内置在计算机主板上的实时时钟(Real Time Clock),即使在系统关闭的情况下也能继续运行。`hwclock` 工具提供了多种功能来读取硬件时钟的时间、调整系统时间与硬件时钟之间的时间差以及定期更新硬件...

    centos服务器时间问题解决方案

    2) 测试 ntp:ntpdate time.windows.com,出现 4 Nov 09:39:40 ntpdate[5325]: adjust time server 64.4.10.33 offset 0.023655 sec,说明时间同步成功 3) 配置每 10 分钟时间同步一次:crontab -e 0-59/10 * * * * ...

    centos下wget安装包

    `wget`有丰富的选项可以自定义下载行为,如设置下载速度限制(`--limit-rate`),断点续传(`-c`),或者在指定时间后自动停止(`--timeout`)等。 对于网络管理员和开发者来说,`wget`的一个强大特性是它可以递归...

    RealToon 5.2.1 卡通动漫风格着色器.txt

    - Computer (PC,Mac & Linux), Mobile & Video Game Console (Nintendo Switch) in one shader. - You can also use this in creating Anime/Cartoon film & Illustrations/Arts in unity3d. - You can also use ...

    cp201x资源启动程序

    Note that your version of Linux may differ slightly -- adjust accordingly. $ cd ~ $ sudo apt-get install build-essential linux-source $ cp /usr/src/linux-source-3.2.0.tar.bz2 . $ bunzip2 linux-source...

    mysql显示乱码问题

    # also need to also adjust /etc/apparmor.d/usr.sbin.mysqld. user = mysql pid-file = /var/run/mysqld/mysqld.pid socket = /var/run/mysqld/mysqld.sock port = 3306 basedir = /usr datadir = /var/lib/mysql...

    windows 使用wget 下载命令

    这个工具最初是为Linux系统开发的,但也可以在Windows环境下使用。本篇文章将详细讲解如何在Windows中安装和使用`wget`,以及相关的使用技巧。 **一、wget的安装** 在Windows上使用`wget`,首先需要获取对应版本的...

    wget[exe&help]

    `--mirror`是`-r -N -l inf --convert-links --adjust-extension --page-requisites`的组合,用于创建源网站的本地镜像。`--convert-links`将相对链接转换为绝对链接,以便在本地浏览。 5. **时间戳和更新**: `-...

    pyloris-3.2-win32

    Setting the --timebetweenconnections flag will adjust the amount of time between socket connections. This will directly affect how quickly the target's connection limit is reached. Proxy Options ...

    wget详细使用说明

    **-T 或 --timeout** 设置网络超时时间。 **--http-user, --http-password** 用于HTTP基本认证,提供用户名和密码。 **--auth-no-challenge** 在支持但不需要身份验证的情况下,避免服务器发送质询。 ### 使用...

    wget.exe

    `wget` 最初是为Linux系统开发的,但后来被移植到了Windows平台,成为开发者、系统管理员和普通用户下载大文件或整个网站的首选工具。 ### 主要功能 1. **非交互式下载**:`wget` 的一大特点就是它可以在后台运行...

    Ubuntu_命令技巧

    使用`sudo apt autoremove --purge linux-image-*`命令可以清理旧版本的Linux内核。 **1.24 导入ppa源的key值** 使用`wget -qO- <key-url> | sudo apt-key add -`命令可以从URL导入PPA源的公钥。 #### 二、系统...

    计算机专业英语词汇.pdf

    例如:“The program can also run on Linux”(该程序也可以在Linux上运行)。 46. do: 做。动词,用于执行行动或操作。例如:“Do not save changes if prompted”(如果提示保存更改则不保存)。 ***rmation: ...

Global site tag (gtag.js) - Google Analytics