Operating System - HP-UX
1847086 Members
5596 Online
110262 Solutions
New Discussion

Re: changing time on a cluster node

 
SOLVED
Go to solution
akarayil
Frequent Advisor

changing time on a cluster node

Hi experts,
We have two rx2620 cluster(MC/SG) nodes with hpux 11.23 OS. The primary server also configured as NTP server. Alternate node and other servers are configured as NTP client. There is a time difference of 15 min. in our network. If I change the time in NTP server, the same time will be updated in other servers also. Can I do the following steps to update the time:
1#cmhaltpkg -v pkg123
2#cmhaltcl -v
3#set_parms date_time
4#shutdown -ry 0
5#cmviewcl -v If cluser is not started then
6#cmruncl
OR
move package to other node, then
#cmhaltnode -n node1
then use set_parms to change the time and restart.
Kindly guide me with the best option.

Regards,


6 REPLIES 6
Robert-Jan Goossens_1
Honored Contributor
Solution

Re: changing time on a cluster node

Hi,

The easiest solution might be to move the NTP server functionality to an alternate host. If you have a "spare" unix(linux,hpux,solaris) system you could setup a new ntp server, and you that host to slowly adjust the time on the other hosts.

Have a look at the ntpdate manpage (ntdate -B)

Best regards,
Robert-Jan
sujit kumar singh
Honored Contributor

Re: changing time on a cluster node

Hi

Just Few thoughts , might be you shall get a better suggestion.
"Special care needs to be taken while taking a system back to a time in the past."

Please keep the followin things into consideration.

1) how did your systems happen to pick this time differnence when they had the same NTP Server?
3)Is the timezons settings on all the machines OKay? that is their Time Zone correctly defined?
4)whether you are going to take the systems 15 miutes in Future or 15 min in the past?
5)If you are taking the systems in the past make sure that the databases and the applications on that system are totally stopped for that equal amount of time making sure that no DB transactions are done or application transactions happen in that time.
Only try to start the applications and database when your system has effectively come from the past time to the actual currebt time or the DB can end up recording a later transcation before an earlier trasaction. So be careful.
6)If you are taking the systems in the future then also take few minutes time for the applications and DB to start , this is optional in case you are moving the system in future w.r.t. now.
7)If the TimeZone settings are OK then you can also use the date command to achoeve this on HP-UX systems.
8)for the node1 as the NTP server and that node2 as the Standby node of the cluster, please stop all the applications anf databases and packages before you change time keeping in mind the point 5.
you can also stop the xntpd daemon and the cron daemon on the systems as you shall be making the changes.

say node1 is the node as NTP server and node2 is the other node. Stop all the packages, Databases and applications on both the nodes using your preferred methodof cmhaltpkg etc. Halt the cluster also using cmhaltcl that shall be better.

on node1 and node 2 give the command as :

#/sbin/init.d/xntpd stop
#/sbin/init.d/cron stop
#date -u 020302172009; remsh node2 date -u 020302172009

this shall set the UTC time on both the cluster nodes to Feb 02, 02:17 hours (am) 2009.
then for check:

#date; remsh node2 date
after you are done with that and checking that the date command shows the time correct as per your TIMEZONE and keeping strictly point 5 in mind,

you can do
#/sbin/init.d/xntpd start

Start the cluster and the applications, packages and Databases.
#/sbin/init.d/cron start

Regards
Sujit






akarayil
Frequent Advisor

Re: changing time on a cluster node

There is no problem in TZ setting. Its IST-5:30.Server time running 15 min behind the exact time.As we use local system time as ntp source, there will be slight changes over years. For the last 4 years it was not updated.There is no time difference between servers, but its running behind the exact time that create issues on attendance system and all.
Do I need to restart, if date command is used to change the time.

Our DBA saying that DB has no connection with system time. So, can I change the time without halting the cluster?
sujit kumar singh
Honored Contributor

Re: changing time on a cluster node

Hi,


Still i will suggest to make sure not running into any problems of time, Please take a down time and do the change with all the precautions.

this is only to keep the DB down for 15-20 Minutes.

REgards
Sujit
likid0
Honored Contributor

Re: changing time on a cluster node

"Do I need to restart, if date command is used to change the time?"

you can use the date command without rebooting the machine, no need for a reboot

But you should stop the cluster and db/apps just to be sure you are not going to run into any problems.
Windows?, no thanks
akarayil
Frequent Advisor

Re: changing time on a cluster node

Thanks for all the sugestions