...
Another way quick way to determine the server ip is to log out and then log in. The initial welcome text banner displays the ip when you login.
Synchronize Server Time
Note |
---|
With Ubuntu 12, I am looking at simplifying this using the Ubuntu approach to Crons or using the Deamon ntp if the memory is minimal and archiving Dickson's version. |
First make sure you have the correct time zone.
Info |
---|
As described in Ubuntu Help Pages - Time Synchronisation with NTP there are many ways of doing this. The method shown here was taught to me by Dickson as the more universal Unix approach. |
The ntp daemon calculates the drift of your system clock and continuously adjusts it.
Code Block | ||
---|---|---|
| ||
date # determine current timezone |
If need be change your time zone,
Code Block | ||
---|---|---|
| ||
sudo dpkgapt-reconfigureget tzdata # sets the timezone |
Next we make sure the time stays correct.
Make ntpdate Scheduled in the chrontab (Scheduled Job):
Code Block | ||
---|---|---|
| ||
sudo crontab -e |
At this point you will be asked to choose a default editor. I recommend selecting nano if you are a beginner. You can always change the default editor later with, select-editor.
Add to the bottom of the file,
Code Block | ||
---|---|---|
| ||
# update time and date every morning at 5:00.
00 05 * * * ntpdate ntp.ubuntu.com pool.ntp.org |
Hit keys, CTRL-O and Enter (save in nano)
Hit keys, CTRL-X (exit in nano)
Panel |
---|
Here is another method using a file creation. |
Next, verify that the crontab was updated successfully by listing the crontab. (Note: you don't need sudo to do this).
Code Block | ||
---|---|---|
| ||
crontab -l |
install ntp |
The advantage over the traditional cron tab approach is less inconsistency in logs for when there are large time corrections. The cost is a little processing power and memory, but for a modern server this is negligible.
Info |
---|
If you do not want to spare the processing power and memory, consider using other approaches documented by the Ubuntu Community or the traditional cron approach. |
Select a Locale
If you used a hosting company like Slice or Rackspace chances are the server image they provided is minimal and has no locale set. This is bad because it will cause problems with Perl (used to install quite a few things) and in my case, it caused me head-aches setting up PostgreSQL.
...