We recently switched to an RDS instance and noticed that bunch of our database tasks were getting triggered 4 hours earlier than needed. On investigating further, the problem is caused by the default time-zone setting (UTC) on the RDS instance. Since this setting can not be altered, we would like to fix the issue on the code level globally across all our applications using this database instance. I tried to set the time-zone on the db instance I create to 'US/Eastern' by using
set GLOBAL time_zone = 'US/Eastern'" OR
set time_zone = 'US/Eastern'"
But that generates an error "Database error: Unknown or incorrect time zone: 'US/Eastern'"
What do you think I am doing wrong here? Does anyone has used any other solutions ?
To modify the time zone of a new or existing RDS Oracle instance, use the “Option Group” option in the AWS Management Console. Please note that this option changes the time zone at the host level and impacts all date columns and values.
On the AWS Elemental Server web interface, go to the Settings page and choose General. In Timezone, choose your required time zone. Choose Update.
In order to change the time zone of SQL Server you need to change it at the operating system level, changing the date time of the server.
Restoring your data creates a new Amazon RDS instance. Specify the backup you want to recover, and enter your Amazon RDS instance configuration as required. Then, click Restore to point in time. Upon completion of the restore, navigate to the Amazon RDS console to access the created database instance.
I did the following steps, So that I could change the timezone
login to RDS and Create New Parameter Group.
Edit the newly created Parameter Group
Set timezone Ex:Asia/Calcutta and Save Changes
Modify RDS instance, change DB's Parameter Group to newly created parameter group
Save And Reboot RDS instance
The time_zone setting of RDS database instances can now be modified: https://aws.amazon.com/de/premiumsupport/knowledge-center/rds-change-time-zone/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With