From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1164f8,3c7308a6d5ab7ad7,start X-Google-Attributes: gid1164f8,public From: "Tony" Subject: Weird Time Behaviour Date: 1999/10/30 Message-ID: <941282326.16289.0.nnrp-13.d4e4b8ee@news.demon.co.uk> X-Deja-AN: 542384842 X-NNTP-Posting-Host: creaker.demon.co.uk:212.228.184.238 X-Trace: news.demon.co.uk 941282326 nnrp-13:16289 NO-IDENT creaker.demon.co.uk:212.228.184.238 X-MSMail-Priority: Normal X-Priority: 3 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300 Newsgroups: comp.sys.dec X-Complaints-To: abuse@demon.net We have a problem with time on the DEC Alpha machines that we are using. Our application runs in a hot standby configuration on two identical machines. The machines are Single Board Computer 233Mhz with 256MB, same amount of cache on each machine. Also, the same kernel build is used on both these machines. In fact, the same kernel /vmunix is used. We use NTP (we are currently using ntp4.98b) synchronised to a number of radio clocks, to keep with 10ms of GMT. The system behaviour is as follows: 1. Run our harness+comms applications standalone on MACHINE_1. 2. Cause a system load of resulting in, on average, 30% processor utilisation for harness, and 10% for comms. 3. Watch the behaviour of ntpd over 24 hours. The system and ntpd behave perfectly well. Change so that the harness+comms applications are running standalone on MACHINE_2, with the same system load. Again, there are no problems synchronising the machines. Ok, now: 1. Run the master harness+comms applications on MACHINE_1. 2. Run the standby harness+comms applications on MACHINE_2. 3. Watch the behaviour of ntpd on the master + standby machines over 24 hours. The MACHINE_2 machine, drifts ~10 seconds per hour (i.e. it _slows_ down by ~10 seconds per hour) Reboot machines + change mastership, so that the master runs on MACHINE_2, and the standby runs on MACHINE_1. The weird drifting behaviour now occurs on MACHINE_1! So, OK, it's easy to blame NTP, so we'll disable it on MACHINE_2, disable the call to 'ntpdate' on boot up, and set the time from the speaking clock by hand: 1. Stop using NTP completely on MACHINE_2. 2. Reboot both machines. MACHINE_1 syncs to the time and remains in sync. 3. Set the time of MACHINE_2 by hand, using 'date' and the speaking clock. 4. Wait 1 hour. The times are still the same. 5. Start master app with same system load. Wait 1 hour. Times are still the same. 6. Start standby application on MACHINE_2. MACHINE_2 is immediately ~2 seconds behind. 7. Wait 1 hour. MACHINE_2 is now ~10 seconds behind. 8. Wait 6 hours, MACHINE_2 is now ~60 seconds behind. Again, this behaviour follows the standby. Note that the system load just hastens the process. Looking at process statistics, the only difference between master + standby is that the standby comms uses 10MB more memory, and the standby harness uses 13MB more memory. The CPU usage on the master is always higher than the cpu usage on the standby. vmstat statistics show everything more or less equal, but slightly more page faults on the standby. Note: we cannot step the time periodically, due to the nature of the hot standby mechanism. And I don't think we can slew the time by 10 seconds per hour. Anyone got any ideas? It looks like it's related to memory, but does anybody have any experience of this kind of situation? Stats are attached for those interested: MACHINE_1 Virtual Memory Statistics: (pagesize = 8192) -------------------------------------------------------- procs memory pages intr cpu r w u act free wire fault cow zero react pin pout in sy cs us sy id 5133 20 22K 5848 2853 129 36 57 0 28 0 80 1K 1K 52 12 37 4134 20 22K 5848 2853 128 36 56 0 28 0 91 1K 1K 54 12 34 9129 20 22K 5847 2853 129 36 57 0 28 0 110 1K 1K 57 10 33 4134 20 22K 5846 2854 128 36 56 0 28 0 84 1K 1K 69 12 19 7131 20 22K 5846 2854 128 36 56 0 28 0 86 1K 1K 52 11 37 5133 20 22K 5845 2854 128 36 56 0 28 0 104 1K 1K 56 12 32 4134 20 22K 5845 2854 213 72 69 0 56 0 94 1K 1K 53 12 35 6132 20 22K 5845 2854 128 36 56 0 28 0 65 986 1K 58 11 31 4134 20 22K 5844 2854 129 36 57 0 28 0 89 1K 1K 56 12 32 4134 20 22K 5844 2854 128 36 56 0 28 0 80 1K 1K 61 12 28 8130 20 22K 5843 2854 129 36 57 0 28 0 101 1K 1K 55 12 33 6132 20 22K 5843 2854 128 36 56 0 28 0 70 993 1K 55 11 34 5133 20 22K 5843 2854 128 36 56 0 28 0 107 1K 1K 62 12 26 9129 20 22K 5843 2854 128 36 56 0 28 0 77 1K 1K 58 12 30 6132 20 22K 5842 2854 128 36 56 0 28 0 104 1K 1K 57 14 28 4134 20 22K 5842 2854 129 36 57 0 28 0 91 1K 1K 53 12 35 10128 20 22K 5842 2854 87 18 51 0 14 0 89 1K 1K 59 10 31 7131 20 22K 5841 2854 84 18 48 0 14 0 97 1K 1K 66 12 22 6132 20 22K 5841 2854 128 36 56 0 28 0 91 1K 1K 56 12 32 6132 20 22K 5841 2854 128 36 56 0 28 0 77 1K 1K 53 12 36 MACHINE_2 Virtual Memory Statistics: (pagesize = 8192) -------------------------------------------------------- procs memory pages intr cpu r w u act free wire fault cow zero react pin pout in sy cs us sy id 4138 20 23K 4733 2556 133 34 63 0 28 0 65 1K 1K 21 12 67 5137 20 23K 4733 2556 133 34 63 0 28 0 62 1K 1K 23 11 66 5137 20 23K 4733 2556 133 34 63 0 28 0 73 1K 1K 21 11 68 5137 20 23K 4733 2556 133 34 63 0 28 0 65 1K 1K 22 10 68 5137 20 23K 4733 2556 133 34 63 0 28 0 75 1K 1K 21 10 69 5137 20 23K 4733 2556 133 34 63 0 28 0 66 983 1K 20 11 69 6136 20 23K 4733 2556 133 34 63 0 28 0 64 1K 1K 23 12 65 5137 20 23K 4733 2556 133 34 63 0 28 0 83 1K 1K 22 11 68 5137 20 23K 4733 2556 133 34 63 0 28 0 61 970 1K 21 10 69 7135 20 23K 4733 2556 133 34 63 0 28 0 84 1K 1K 19 12 69 8134 20 23K 4733 2556 133 34 63 0 28 0 66 1K 1K 19 12 69 6136 20 23K 4733 2556 216 68 76 0 56 0 70 1K 1K 24 13 64 7135 20 23K 4733 2556 85 15 55 0 10 0 59 1K 1K 21 10 69 6136 20 23K 4733 2556 98 19 58 0 18 0 69 1K 1K 22 11 68 6136 20 23K 4733 2556 133 34 63 0 28 0 70 1K 1K 22 10 68 8134 20 23K 4733 2556 133 34 63 0 28 0 64 1K 1K 21 11 68 5137 20 23K 4733 2556 133 34 63 0 28 0 94 1K 1K 23 12 65 9133 20 23K 4733 2556 133 34 63 0 28 0 76 1K 1K 20 11 70 5137 20 23K 4733 2556 133 34 63 0 28 0 68 1K 1K 22 11 67 MACHINE_1 Process statistics (ps aux) ------------------------------ USER PID %CPU %MEM VSZ RSS TTY S STARTED TIME COMMAND rel 1382 72.6 25.6 218M 65M ?? R 08:57:19 26:52.05 ./harness rel 1353 8.1 7.8 66.5M 20M ?? R 08:57:09 6:00.21 ./comms adminac 612 1.2 0.1 1.91M 240K ttyp0 S 08:38:26 0:21.96 -sh (csh) root 0 1.1 4.5 262M 11M ?? R < 08:36:46 1:06.70 [kernel idle] adminac 5028 0.3 0.0 1.59M 104K ttyp0 S + 10:19:46 0:00.01 sleep 1 root 204 0.2 0.4 3.73M 912K ?? S < 08:37:19 0:21.26 /usr/sbin/gated root 611 0.1 0.2 4.23M 528K ?? S 08:38:25 0:02.75 /usr/bin/X11/xterm -display CONSOLE:0.1 root 146 0.0 0.0 1.62M 120K ?? S 08:37:15 0:00.12 /usr/sbin/syslogd rel 1327 0.0 0.1 2.02M 264K ?? I 08:57:08 0:00.06 csh -c start_application -v -h comms root 148 0.0 0.0 1.68M 120K ?? I 08:37:15 0:00.01 /usr/sbin/binlogd root 22 0.0 0.0 1.59M 96K ?? I 08:36:55 0:00.88 /sbin/update root 1 0.0 0.0 464K 80K ?? I 08:36:46 0:00.13 /sbin/init -a root 3 0.0 0.2 952K 624K ?? I 08:36:47 0:00.09 /sbin/kloadsrv rel 1332 0.0 0.1 2.29M 352K ?? I 08:57:08 0:00.17 csh -f start_application -v -h comms root 332 0.0 0.0 2.12M 120K ?? S 08:37:29 0:00.26 /usr/sbin/portmap root 334 0.0 0.1 2.22M 216K ?? I 08:37:29 0:00.01 /usr/sbin/mountd -i rel 1328 0.0 0.1 1.62M 248K ?? S 08:57:08 0:05.13 rshd rel 1355 0.0 0.0 0K 0K ?? < - 0:00.00 root 336 0.0 0.0 1.59M 0K ?? S 08:37:29 0:00.01 /usr/sbin/nfsd -t8 -u8 root 338 0.0 0.0 1.59M 64K ?? S 08:37:29 0:00.00 /usr/sbin/nfsiod 7 root 395 0.0 0.1 1.87M 200K ?? I 08:37:32 0:00.05 -accepting connections (sendmail) root 442 0.0 0.1 1.65M 152K ?? I 08:37:34 0:00.10 /usr/sbin/inetd root 341 0.0 0.1 2.19M 200K ?? I + 08:37:29 0:00.03 /usr/sbin/rpc.statd root 343 0.0 0.1 2.30M 240K ?? S 08:37:29 0:01.15 /usr/sbin/rpc.lockd rel 1354 0.0 0.1 1.62M 248K ?? I 08:57:18 0:00.05 rshd root 438 0.0 0.1 1.70M 144K ?? S 08:37:33 0:00.26 /usr/sbin/snmpd root 477 0.0 0.1 1.62M 160K ?? I 08:37:37 0:00.17 /usr/sbin/cron root 470 0.0 0.2 2.47M 496K ?? I 08:37:37 0:00.15 /usr/sbin/joind root 499 0.0 0.1 1.72M 136K ?? I 08:37:39 0:00.02 /usr/lbin/lpd root 561 0.0 0.0 1.72M 120K ?? I 08:37:44 0:00.00 /usr/sbin/prmd /etc/prmd_config root 605 0.0 0.0 448K 88K console I + 08:37:50 0:00.04 /usr/sbin/getty console console vt100 root 602 0.0 1.0 2.59M 2.6M ?? S < 08:37:49 0:08.93 /usr/local/bin/ntpd.98b -g -l /usr/local/xntpd.log -x -c /etc/ntp.conf adminac 616 0.0 0.1 1.91M 240K ttyp1 I + 08:39:09 0:04.13 -sh (csh) root 615 0.0 0.2 4.18M 456K ?? I 08:39:09 0:00.74 /usr/bin/X11/xterm -display CONSOLE:0.1 adminac 614 0.0 0.1 1.91M 224K ?? I 08:39:09 0:00.02 csh -c /usr/bin/X11/xterm -display CONSOLE:0.1 adminac 613 0.0 0.1 1.62M 248K ?? I 08:39:09 0:00.04 rshd root 432 0.0 0.1 2.22M 152K ?? S 08:37:33 0:00.12 /usr/sbin/svrMgt_mib root 433 0.0 0.1 2.23M 152K ?? S 08:37:33 0:00.10 /usr/sbin/svrSystem_mib adminac 610 0.0 0.1 1.91M 224K ?? I 08:38:25 0:00.02 csh -c /usr/bin/X11/xterm -display CONSOLE:0.1 adminac 609 0.0 0.1 1.62M 248K ?? I 08:38:25 0:00.04 rshd adminac 1785 0.0 0.1 1.91M 232K ttyp2 S 09:53:00 0:00.24 -csh (csh) root 1784 0.0 0.1 1.72M 192K ?? S 09:53:00 0:00.22 telnetd root 5029 0.0 0.1 1.84M 376K ttyp2 R + 10:19:47 0:00.10 ps aux root 434 0.0 0.1 2.34M 232K ?? S 08:37:33 0:00.10 /usr/sbin/os_mibs MACHINE_2 Process statistics (ps aux) ------------------------------ USER PID %CPU %MEM VSZ RSS TTY S STARTED TIME COMMAND rel 1394 22.2 30.8 197M 78M ?? R 09:34:45 10:54.63 ./harness rel 1358 4.4 12.6 65.6M 32M ?? R 09:28:29 3:20.27 ./comms adminac 546 1.2 0.1 1.91M 240K ttyp0 S 08:38:36 0:24.10 -sh (csh) root 0 0.4 4.5 262M 11M ?? R < 08:36:43 0:27.95 [kernel idle] root 171 0.4 0.4 3.73M 912K ?? S 08:37:07 0:23.34 /usr/sbin/gated adminac 5231 0.4 0.0 1.59M 104K ttyp0 S + 10:21:50 0:00.01 sleep 1 root 545 0.1 0.2 4.23M 536K ?? S 08:38:34 0:02.64 /usr/bin/X11/xterm -display CONSOLE:0.1 root 1698 0.1 0.1 1.72M 192K ?? S 09:52:39 0:00.17 telnetd root 5230 0.0 0.1 1.73M 256K ttyp2 R + 10:21:51 0:00.03 ps aux root 22 0.0 0.0 1.59M 96K ?? I 08:36:52 0:00.70 /sbin/update root 1 0.0 0.0 464K 80K ?? I 08:36:43 0:00.15 /sbin/init -a root 3 0.0 0.2 952K 616K ?? I 08:36:44 0:00.10 /sbin/kloadsrv root 134 0.0 0.0 1.68M 120K ?? I 08:37:04 0:00.02 /usr/sbin/binlogd root 132 0.0 0.0 1.62M 120K ?? S 08:37:04 0:00.13 /usr/sbin/syslogd rel 1261 0.0 0.1 1.62M 248K ?? S 08:57:07 0:04.02 rshd rel 1275 0.0 0.0 1.61M 64K ?? I 08:57:08 0:00.00 /usr/bin/rsh MACHINE_1 start_application -v -h COMMS root 281 0.0 0.1 2.19M 200K ?? I + 08:37:11 0:00.03 /usr/sbin/rpc.statd root 283 0.0 0.1 2.30M 240K ?? S 08:37:11 0:01.21 /usr/sbin/rpc.lockd rel 1269 0.0 0.1 2.02M 264K ?? I 08:57:08 0:00.06 csh -c /usr/bin/rsh MACHINE_1 start_application -v -h COMMS rel 1274 0.0 0.1 1.61M 160K ?? S 08:57:08 0:02.48 /usr/bin/rsh MACHINE_1 start_application -v -h COMMS root 278 0.0 0.0 1.59M 64K ?? I 08:37:11 0:00.00 /usr/sbin/nfsiod 7 rel 1337 0.0 0.1 1.61M 160K ?? S 09:28:28 0:00.96 /usr/bin/rsh MACHINE_2 start_application -v -h COMMS rel 1336 0.0 0.1 1.62M 248K ?? S 09:28:28 0:03.71 rshd rel 1331 0.0 0.1 2.02M 264K ?? I 09:28:28 0:00.06 csh -c /usr/bin/rsh MACHINE_2 start_application -v -h COMMS rel 1330 0.0 0.1 1.62M 248K ?? S 09:28:27 0:02.19 rshd rel 1338 0.0 0.0 1.61M 64K ?? I 09:28:28 0:00.00 /usr/bin/rsh MACHINE_2 start_application -v -h COMMS rel 1339 0.0 0.1 2.02M 264K ?? I 09:28:28 0:00.06 csh -c start_application -v -h COMMS root 272 0.0 0.0 2.12M 120K ?? S 08:37:11 0:00.25 /usr/sbin/portmap root 274 0.0 0.1 2.21M 208K ?? I 08:37:11 0:00.01 /usr/sbin/mountd -i root 276 0.0 0.0 1.59M 0K ?? I 08:37:11 0:00.01 /usr/sbin/nfsd -t8 -u8 root 335 0.0 0.1 1.87M 200K ?? I 08:37:14 0:00.05 -accepting connections (sendmail) root 380 0.0 0.1 1.70M 160K ?? S 08:37:16 0:00.30 /usr/sbin/snmpd root 374 0.0 0.1 2.34M 232K ?? S 08:37:15 0:00.12 /usr/sbin/os_mibs root 373 0.0 0.1 2.22M 152K ?? S 08:37:15 0:00.12 /usr/sbin/svrMgt_mib root 372 0.0 0.1 2.23M 144K ?? I 08:37:15 0:00.09 /usr/sbin/svrSystem_mib root 382 0.0 0.1 1.65M 152K ?? I 08:37:17 0:00.11 /usr/sbin/inetd root 410 0.0 0.2 2.36M 424K ?? I 08:37:19 0:00.12 /usr/sbin/joind root 417 0.0 0.1 1.62M 160K ?? I 08:37:20 0:00.21 /usr/sbin/cron root 439 0.0 0.1 1.72M 136K ?? I 08:37:22 0:00.02 /usr/lbin/lpd root 501 0.0 0.0 1.72M 120K ?? I 08:37:27 0:00.00 /usr/sbin/prmd /etc/prmd_config adminac 543 0.0 0.1 1.62M 248K ?? I 08:38:34 0:00.05 rshd root 542 0.0 0.0 448K 88K console I + 08:37:40 0:00.04 /usr/sbin/getty console console vt100 adminac 552 0.0 0.1 1.91M 240K ttyp1 I + 08:38:53 0:04.39 -sh (csh) root 551 0.0 0.2 4.18M 456K ?? I 08:38:53 0:00.70 /usr/bin/X11/xterm -display CONSOLE:0.1 adminac 550 0.0 0.1 1.91M 224K ?? I 08:38:53 0:00.03 csh -c /usr/bin/X11/xterm -display CONSOLE:0.1 adminac 549 0.0 0.1 1.62M 248K ?? I 08:38:53 0:00.05 rshd rel 1370 0.0 0.1 1.62M 248K ?? I 09:34:44 0:00.05 rshd rel 1372 0.0 0.0 0K 0K ?? < - 0:00.00 adminac 544 0.0 0.1 1.91M 224K ?? I 08:38:34 0:00.04 csh -c /usr/bin/X11/xterm -display CONSOLE:0.1 adminac 1699 0.0 0.1 1.91M 232K ttyp2 S 09:52:40 0:00.20 -csh (csh) rel 1345 0.0 0.1 2.29M 352K ?? I 09:28:28 0:00.18 csh -f start_application -v -h COMMS -- Thanks Tony