Saturday, 10 January 2009

 

Setting up NTP on Debian

Introduction

What is NTP? It is a UDP protocol for correcting system clocks.

Why am I using it? I've got a couple of Debian based machines running on VMWare, and the clock keeps going out of sync. I want to have as little overhead on these boxes as possible, so I set up an NTP Daemon on the VMWare host, and then the NTP Clients on the VMWare Guests.

My Sources

I followed this guide, but it was a little unclear, so I figured I'd follow it up and add my notes to the mix.

Setting up the server

Firstly, I had to get the NTPd running on the server. The Host machine is running Debian, but if you aren't, then provided you can install an NTP server on the server, you'll be OK.

I installed ntpdate and ntp from the Debian repositories using the following apt command:
apt-get install ntp ntpdate
Next, I stopped the NTPd using this command:
/etc/init.d/ntp stop
I then ran the ntpdate command (which won't run while the ntpd is running) to bring the clock into sync with the upstream server:
ntpdate pool.ntp.org
If you've got a more local NTP server, use that in place of the pool.ntp.org.

Next, use the date command to ensure the clock is closer to being in sync.

  • If you've got a local NTP server, you should edit the file /etc/ntp.conf and either add to the server lines (if you also want to keep access to the existing pool of NTP servers) or comment out the existing server lines.

  • Add your server in the format (where the server's IP address is 111.222.333.444):
    server 111.222.333.444
  • Start the NTP daemon using the command:
    /etc/init.d/ntp start
    Finally, type the following command:
    ntpq -p
    This may take a few moments, but should return some sort of text like the following:
         remote           refid      st t when poll reach   delay   offset  jitter
    ==============================================================================
    11.111.11.11 222.222.2.222 2 u 21 64 377 0.603 65.748 7.470
    Setting up the clients

    Essentially, the steps here are exactly the same as with the server, except, where you point all of your NTP sources at a common IP address for the host machine.

    Labels: , , , ,


    Thursday, 11 December 2008

     

    Explaining the gibberish in my status updates

    I was asked yesterday what the "gibberish" was in my status update on Facebook. I tried to explain it in a comment, but really, I ran out of space, and not being able to show people what I was talking about makes it a bit difficult!

    So, here's what I wrote:
    @nikdoof @dantheman @fabsh A #LUGCamp or #FOSSCamp would be a good idea, perhaps with keynotes by #UUPC, #LinuxOutlaws?
    Because of the way that Facebook works, it can be updated by an external website - for example identi.ca or twitter



    You will notice that both of these sites have a pretty standard template. Picture on one side, name of person next to the photo and then a message, finished by the date of the message. Like blogs, facebook and myspace, these systems are starting to become ubiqutious. Most news channels now have a twitter feed, and during the recent Presidential Elections, Barack Obama used Twitter (amongst other Social Networking systems) to rally support.

    Twitter and Identi.ca (and others) are collectively known as Micro-blogs, or Microblogging sites, because of the size of the updates, which is limited to 140 characters, which is set at this size to be used (initially) with SMS, as a single SMS message would contain the nickname of the person who sent the message and their message.

    Most microblogging sites follow a common convention for referring to things, so people are usually prefixed by an @ sign (for example @jontheniceguy), and a subject of interest will be prefixed by the # symbol (for example #bcliverpool). So that explains the symbols, but how about the words?

    Here's what I wrote again:
    @nikdoof @dantheman @fabsh A #LUGCamp or #FOSSCamp would be a good idea, perhaps with keynotes by #UUPC, #LinuxOutlaws?
    So, we now know that I wrote to three people, nikdoof, dantheman and fabsh, the last two are presenters of a podcast, and the first the organiser of the Liverpool Linux Users Group, and I proposed that we should organise a "LUGCamp or FOSSCamp". LUG stands for Linux Users Group and FOSS (sometimes written as FLOSS) stands for Free (Libre) and Open Source Software. Linux is the basis of an alternative operating system to Windows or MacOS, but unlike Windows or OS X, it has a permissive license, which allows it to be given away for free, and installed on as many computers as the user wishes, without requiring any license feeds to be paid.

    My inspiration for this event was another event I attended this past weekend, which was a "BarCamp". Now, a BarCamp is not something to do with drinking (although plenty occurred), but instead refers to computing jargon. A BarCamp is an "Unconference", where participants of the event, on their arrival, decide if they will be doing a talk, and if so, indicate to all the other participants by putting the details of their talk on a post-it note, which they then place on the schedule, which is usually a blank sheet of paper just detailing the available rooms. A BarCamp will tend to discuss computer topics, but can just as easily have a discussion about hypnotism, environmental issues or football! It tends to be a "geeky" event, but that isn't to say that non-geeks aren't welcome - in fact, frequently they will be welcomed to the group and encouraged to talk about what they are expert in.

    By proposing that we organise a LUGCamp (a BarCamp for Linux Users) or a FOSSCamp (a BarCamp for those involved in Free and Open Source Software), I want to encourage the use of truely Free Software (which includes Linux based Operating Systems), and Open Source Software (of which Free Software is a subet), and I think a BarCamp like event would be a good way to start something up.

    The last part of my text suggested that the keynote speeches (usually the inspirational talk given by a community leader or business director at the beginning or end of a conference) would be given by podcasters from the Ubuntu UK PodCast or the LinuxOutlaws Podcast. A podcast is a recorded audio or video show that is distributed via a web server and announced to RSS readers or specific "Pod Catching" software using an RSS feed.

    I hope I've not missed anything out in explaining this properly, and if there's anything here I've missed, please let me know, either in the comments of this blog, or by e-mail.

    Labels: , , , , , , ,


    This page is powered by Blogger. Isn't yours?

    Subscribe to Posts [Atom]