सही सिस्टम समय लॉग, SSL प्रमाणपत्र और क्रोन कार्यों के लिए महत्वपूर्ण है।
📋 पूर्वापेक्षाएँ
- root/sudo VPS, SSH कनेक्शन
- Ubuntu/Debian
🔍 वर्तमान टाइमज़ोन जाँचें
Bash# Display current timezone timedatectl # Or simply date # Display only the timezone timedatectl | grep "Time zone"
🌍 विधि 1: timedatectl (अनुशंसित)
Bash# List all available timezones timedatectl list-timezones # Filter to find European timezones timedatectl list-timezones | grep Europe # Search specifically for Paris timedatectl list-timezones | grep Paris
Bash# Set timezone to Europe/Paris sudo timedatectl set-timezone Europe/Paris # Verify that the change was applied timedatectl
उदाहरण आउटपुट:
Local time: Mon 2026-01-11 14:30:00 CET
Universal time: Mon 2026-01-11 13:30:00 UTC
RTC time: Mon 2026-01-11 13:30:00
Time zone: Europe/Paris (CET, +0100)
System clock synchronized: yes
NTP service: active
RTC in local TZ: no
🔧 विधि 2: प्रतीकात्मक लिंक
Bash# List available timezones ls /usr/share/zoneinfo/Europe/ # Verify that Europe/Paris exists ls -la /usr/share/zoneinfo/Europe/Paris
Bash# Backup the old timezone (optional) sudo mv /etc/localtime /etc/localtime.backup # Create the symbolic link to the Paris timezone sudo ln -sf /usr/share/zoneinfo/Europe/Paris /etc/localtime # Verify the change date
Bash# Edit the timezone file echo "Europe/Paris" | sudo tee /etc/timezone # Verify the content cat /etc/timezone
✅ सत्यापन
Bash# Display date and time with timezone date # Display all time information timedatectl # Display UTC time date -u
Bash# Verify the symbolic link ls -la /etc/localtime # Should display something like: # /etc/localtime -> /usr/share/zoneinfo/Europe/Paris
🕐 डेलाइट सेविंग (DST)
Europe/Paris स्वचालित रूप से CET (UTC+1) और CEST (UTC+2) संभालता है।
🔄 NTP सिंक्रनाइज़ेशन
Bash# Check if NTP is active timedatectl status # If NTP is not active, enable it sudo timedatectl set-ntp true
Bash# Install NTP sudo apt update sudo apt install ntp -y # Check status systemctl status ntp # Enable NTP on boot sudo systemctl enable ntp sudo systemctl start ntp
🎯 अन्य फ़्रांसीसी टाइमज़ोन
Bash# Mainland (Paris) sudo timedatectl set-timezone Europe/Paris # Antilles (Guadeloupe, Martinique) sudo timedatectl set-timezone America/Martinique # French Guiana sudo timedatectl set-timezone America/Cayenne # Réunion sudo timedatectl set-timezone Indian/Reunion
📝 उपयोगी कमांड
Bash# Local time (Paris) date # UTC time date -u # Time in a specific timezone TZ='America/New_York' date TZ='Asia/Tokyo' date
🔍 समस्या निवारण
Bash# Check NTP status timedatectl status # Enable NTP if disabled sudo timedatectl set-ntp true # Check connection to NTP servers sudo ntpq -p
Bash# Enable NTP for automatic synchronization sudo timedatectl set-ntp true # Install chrony (NTP alternative) sudo apt install chrony -y sudo systemctl enable chrony sudo systemctl start chrony
✅ सर्वोत्तम अभ्यास
- timedatectl उपयोग करें
- NTP सक्षम रखें
- समय मैन्युअल न बदलें — NTP पर भरोसा करें
❓ अक्सर पूछे जाने वाले प्रश्न
प्र: CET और CEST में अंतर?
उ: सर्दी (UTC+1) और गर्मी (UTC+2) — Europe/Paris स्वचालित संभालता है।
प्र: NTP सही काम कर रहा है?
उ: timedatectl status — "NTP service: active" और "System clock synchronized: yes"
सही समय! 🕐