drpsrvu85668 2017-10-09 11:07
浏览 117

php时间如何与硬件时钟(hwclock)相关?

I have correctly set timezone to Europe/Dublin and daylight is true but I receive wrong hour - 1 hour earlier. echo date("H:i:s"); // returns 11:03:49, should be 12:03:49. Linux system time is set correctly but maybe I have to change something in hardware time? What should I do to gain correct time in php?

# hwclock --debug
hwclock from util-linux-ng 2.17.2
Using /dev interface to clock.
Last drift adjustment done at 1507541250 seconds after 1969
Last calibration done at 1507541250 seconds after 1969
Hardware clock is on UTC time
Assuming hardware clock is kept in UTC time.
Waiting for clock tick...
...got clock tick
Time read from Hardware Clock: 2017/10/09 10:03:49
Hw clock time : 2017/10/09 10:03:49 = 1507543429 seconds since 1969
Mon 09 Oct 2017 12:03:49 PM CEST  -0.094111 seconds
  • 写回答

0条回答 默认 最新

    报告相同问题?

    悬赏问题

    • ¥100 set_link_state
    • ¥15 虚幻5 UE美术毛发渲染
    • ¥15 CVRP 图论 物流运输优化
    • ¥15 Tableau online 嵌入ppt失败
    • ¥100 支付宝网页转账系统不识别账号
    • ¥15 基于单片机的靶位控制系统
    • ¥15 真我手机蓝牙传输进度消息被关闭了,怎么打开?(关键词-消息通知)
    • ¥15 装 pytorch 的时候出了好多问题,遇到这种情况怎么处理?
    • ¥20 IOS游览器某宝手机网页版自动立即购买JavaScript脚本
    • ¥15 手机接入宽带网线,如何释放宽带全部速度