Watchdog package is messing up the /dev/rtc file causing timedatectl to fail
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
watchdog (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
[Impact]
* Once the watchdog package is installed, users can not use timedatectl, because watchdog package
recreated /dev/rtc.
[Test Case]
* On a Ubuntu system:
# Check the /dev/rtc* files:
- ls -l /dev/rtc*
lrwxrwxrwx 1 root root 4 Mar 26 10:38 /dev/rtc -> rtc0
crw------- 1 root root 251, 0 Mar 26 10:38 /dev/rtc0
# Run timedatectl command:
- timedatectl status
Local time: Mon 2018-03-26 09:06:56 UTC
Universal time: Mon 2018-03-26 09:06:56 UTC
RTC time: Mon 2018-03-26 09:06:55
Time zone: UTC (UTC, +0000)
Network time on: yes
NTP synchronized: yes
RTC in local TZ: no
# Install watchdog package:
- apt-get update && apt-get install watchdog
# Check how the /dev/rtc* files looks now:
- ls -l /dev/rtc*
crw-rw---- 1 root root 10, 135 Mar 26 09:56 /dev/rtc
crw------- 1 root root 251, 0 Mar 26 09:55 /dev/rtc0
# The timedatectl is failing because dbus can not work with /dev/rtc file now
- timedatectl status
Failed to query server: No such device
[Regression Potential]
It looks like there is a bug in the watchdog package in Ubuntu which breaks timedatectl to work properly.
[Problem description]
The "postinst" script in watchdog package call "MAKEDEV misc" which remove /dev/rtc symlink and create "bad" /dev/rtc character device.
```
if [ -x "`which MAKEDEV`" ]; then
# do we have to create the device?
if [ ! -c /dev/watchdog ]
then
(cd /dev; MAKEDEV misc || true)
fi
# do we have to create the temperature device?
if [ ! -c /dev/temperature ]
then
(cd /dev; MAKEDEV misc || true)
fi
fi
```
description: | updated |
Status changed to 'Confirmed' because the bug affects multiple users.