I am using the date command in a shell script to increment startdate
by a given number of days (1 day for example):
EndDateTime=$(date -d "$StartDateTime 1 days" "+%Y-%m-%d %H:%M:%S");
The problem is that i get wrong result for somes cases:
StartDateTime | EndDateTime
2016-02-04 15:57:21 | 2016-02-05 15:57:21
2016-02-04 16:01:18 | 2016-02-05 15:59:41
The first result is exact but the second is wrong and they are computed on same computer by same script in same time.
I am working on Ubuntu with intel 64 family 6 model 23 stepping 10 processor.
Please advice me and thanks in advance.