87Rb Stratum 1 NTP Server – SOFTWARE

20150310_174511

All is mounted inside my old 2850 rack case, ready to launch

The software it’is basically a shell script that resides in  FreeBSD sources , and usually you can find it as nanobsd.sh under the folder /usr/src/tools/tools/nanobsd/ . It creates a very little version of FreeBSD that fit into a common 512 MB Compact Flash card. If not configured the script takes the GENERIC kernel inside /usr/src/ source. Of course a complete kernel will not fit into a 512 MB Card Flash cause it’s just too big , full of unneccesary things such SCSI , multimedia options and other stuffs. I’ve tried to cross compiling the kernel starting from a x64 architecture ( since the Net 4501 require i386 option in the kernel) with some problems: it  still ends with  errors. To save time , i’ve virtualized a  copy of FreeBSD 7.0 inside a i386 virtual machine to make a correct kernel compilation. Anyway you can customize the kernel as you need, the essential part must just be the one relative to the ELAN PPS driver to use the high resolution timer of the ELAN CPU in conjuction with NanoBSD and GPS 1PPS:

options CPU_ELAN
options HZ=1000
options CPU_SOEKRIS
options CPU_ELAN_PPS

Inside the tarball  you’ll find everything you need to flash the disk image into a Compact Flash. This is the content of the compressed archive:

  • NET4501 = my kernel version
  • kronoslord.nano = kernel configuration file

As i’m writing, i did’t find any source on net for a ready-to-go kernel version with configuration files.You can download it here : http://www.sidmonitor.net/gallery/FrancioneNTP.tar.bz2 You will find also all configuration files that you will have to modify in order to work into your system , like rc.conf,ntp.conf,sysctl.conf and others. Create a Files/etc/ directory inside the /nanobsd one before starting the nanobsd.sh script with the command:

#sh nanaobsd.sh -c kronoslord.nano

The file kronoslord.nano is the configuration file . After a while (2-3 hours) of compiling, you should be able to have a  _.disk.full  file inside the folder /usr/obj/ Then just insert a formtatted CF reader (ex usb one) inside your pc and flash the image with dd:

#dd if=_.disk.full of=/dev/sdb

where sdb will be your  CF reader. Check out with a #dmesg to see it. Remember that the filesystem is in read-only mode , wich is good for a security point of view. After you login with root (without password) you’ll find in the /root directory two important scripts to save the ssh rsa keys and the root password. They are save_sshkeys and change_password. You can use them with sh. Another important consideration, every time you wanto to make a change inside a configuration file like rc.conf, ntp.conf you can do it without recompiling the entire kernel. Just mount the /cfg partition with the command :

#mount /cfg

then for example you can make some changes at ntp.conf then copy inside the /cfg partition. Each time you will restart the NanoBSD it will read inside that partition the configurations file. When you have finish unmount the /cfg partitiion with :

#umount /cfg

And you shoud be done to have persistent changes with a read only filesystem. Next session we’ll see performance test on LAN and WAN , how many clients as NTP server can manage and, finally ,if there are any differences between a 10Mhz from a not diciplined rubidium and a disciplined OCXO like Lucent RFTG-u in long period stability.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s