NTP error on boot

Asked by XnimrodunterX

I am running ubuntu 8.10 server, when i boot up my server i get error

Starting NTP server ntpd /etc/rc2.d/S23ntp: line 41: 4631 Terminated lockfile-touch $LOCKFILE

what is this error and how do i resolve this?

i am fairly new to linux.

Thanks

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu ntp Edit question
Assignee:
No assignee Edit question
Solved by:
Craig Huffstetler
Solved:
Last query:
Last reply:
Revision history for this message
Craig Huffstetler (xq) said :
#1

Is this installation on a laptop or a computer with a connection to the Internet that is temporary or not always stable? It looks like it is trying to get the time from the NTP server, however the NTP server is unreachable so it stops boot-up. This should not be happening.

I used to see this a lot of on laptops that used PCMCIA cards. The reason was PCMCIA started later in the boot sequence than NTP, thus the connection could not occur to the NTP server.

NTP is an Internet function so it needs Internet access.

One way you can fix this is:
1) Making sure you are wired in, via Ethernet, and have Internet access at boot-time.
2) After booting up disable NTP.
3) To do this simply open up Synaptic Package Management, search for NTP and un-install it. Or you can disable it via the clock interface.

We can also make sure that it comes later on in the boot sequence, however this is a bit more complicated. But we just want to get you booted up for now.

Sincerely,

Craig H.

Revision history for this message
XnimrodunterX (sgoldschmidt) said :
#2

this is installed on a pc with an internal nic card.

The nic card does connect to the internet as it is working as my web-server.

i do not have synaptic package management because i don't have a gui installed. i do all my installations with apt-get

i did do an apt-get remove ntp and booted my server and did not get the error when i rebooted. i then installed ntp again with apt-get install ntp and recived the same error again. but i noticed that ntp loaded twice. but the scrren goes by so fast that i can't be really positive.

how do i boot in "selective mode" so that i can pick and choose what gets loaded at boot during boot up? i hate to go back to windows but what i am referring to is with windows you can hit f8 key and do a selective startup and see what is getting loaded and choose wheter or not to load the program or driver.

Revision history for this message
Craig Huffstetler (xq) said :
#3

When you begin to boot you select "Recovery Mode" instead of the regular mode that you are booting from. This should be an option at boot time.

Craig H.

Revision history for this message
Craig Huffstetler (xq) said :
#4

The Services settings are under the System > Administration menu. This is used to configure daemons to be started every time when the system boot up and I think it's what you're looking for.

Unless manually stopped by administrative user, the daemons, such as NTP, will stay running until the system is shutdown.

Manually, their startup/shutdown scripts can be found in /etc/init.d. This is where you will find daemons such as NTP.

Craig H.

Revision history for this message
XnimrodunterX (sgoldschmidt) said :
#5

ok.

so i remove ntp by doing "sudo apt-get remove ntp" and removed ntp.

but when i go to /etc/init.d/ there is an ntp file there.

I've also loaded webmin onto my server and when i click on "system - bootup and shutdown" i see that ntp is set to begin at startup. so i am assuming this is becuase /etc/init.d/ntp.

so could this be causing my error? becuase if it is being loaded without ntp even installed and when i install it i crashes because it is already installed?

how do i remove ntp from startup so that i can install it so that my time is sync with a ntp server.

Revision history for this message
Best Craig Huffstetler (xq) said :
#6

You have a few options:

1) Uncheck it/remove it in "Services" from the System > Administration menu.

OR

2) You should be able to manage startup/shutdown from Webmin. Remove it from the startup sequence from Webmin directly. It should be pretty straightforward.

As a last resort, remove the script file from init.d's directory. This will remove it from startup.

OR

2) You can manually remove it from init.d's startup sequence (sudo rm ntp).
sudo rm /etc/init.d/ntp

Regards,

Craig H.

Revision history for this message
XnimrodunterX (sgoldschmidt) said :
#7

Thanks Craig Huffstetler, that solved my question.

Revision history for this message
Craig Huffstetler (xq) said :
#8

I'm glad you finally got this fixed. What finally solved the problem if you don't mind me asking? It was an unusual problem. Usually installing NTP does not cause this error on boot-up when there is a permanent ethernet/network connection (with Internet established). It must have been a software error.

Did re-installing NTP solve it?

Again, I'm glad to have helped.

Revision history for this message
XnimrodunterX (sgoldschmidt) said :
#9

i performed the steps above and then reinstalled ntp.

Thanks your help