Should NTP Processes Never End?

For my NTP needs, I've installed openntpd, removed /etc/cron.hourly/adjtime, and added this line to my crontab,
* * * * * ntpd -s && hwclock -w > /dev/null 2>&1 && rm /var/lib/hwclock/adjtime
It works like a charm; however, I have noticed that the ntpd processes never seem to complete. Here's a snippet from my "ps aux" output,
root 11746 0.0 0.0 18196 468 ? Ss 02:10 0:00 ntpd -s
ntp 11764 0.0 0.0 13984 860 ? S 02:11 0:00 ntpd -s
root 11769 0.0 0.0 18196 344 ? Ss 02:11 0:00 ntpd -s
ntp 11780 0.0 0.0 13984 860 ? S 02:12 0:00 ntpd -s
root 11785 0.0 0.0 18196 340 ? Ss 02:12 0:00 ntpd -s
ntp 11796 0.0 0.0 13984 860 ? S 02:13 0:00 ntpd -s
root 11801 0.0 0.0 18196 344 ? Ss 02:13 0:00 ntpd -s
ntp 11916 0.0 0.0 13984 860 ? S 02:14 0:00 ntpd -s
And if I pipe the ps aux output through grep and wc, I see that there are over a thousand unended ntp-related processes after running the machine for 9 hours,
[root@reformedtube ~]# uptime ; ps aux | grep ntp | wc -l
02:25:19 up 9:01, 1 user, load average: 0.06, 0.02, 0.00
1084
Does anyone have any ideas?

Yes you are completely right, I normally run it in a terminal so I forgot about that (I should have read the man page better ).
You would need to do something like:
ntpd -d -s & sleep 5 && pkill -n ntpd
EDIT: or even:
ntpd -d -s & sleep 5 && kill $!
Last edited by quigybo (2010-06-21 11:39:01)

Similar Messages

  • I created a new administrator USER account. I deleted the original one but the process never ends. It's been 3 days now.

    I created a new administrator USER account. I deleted the original one but the process never ends. It's been 3 days now. And I can't close preferences window or turn off the computer.
    It's stays in the "deleting" but I can't cancel it or close the window.
    What can I do?

    Here are two screen shots to show you what I am seeing.  The first screen shot shows it allowing me to select (highlighted in blue) my admin user (which is what I am locced in as).  The second screen shot shows it allowing me to select the "Guest" user (highlighted in blue).  However when I click on the user "Orion" nothing happens.  It will not change to highlight that user.

  • Controlling "CMD.EXE" via Process - Never ends?

    I'm trying to write a Java program that parses a text file & executes various command promt commands (I'm trying to keep it platform independant, because I know Lin/Un/nix users who would find this userful as well). I found a small tutorial on the web which gave an example of:
    Process p = Runtime.getRuntime().exec("<YOUR COMMAND HERE>");
    BufferedReader stdInput = new BufferedReader(new InputStreamReader(p.getInputStream()));
    BufferedWriter stdOutput = new BufferedWriter(new OutputStreamWriter(p.getOutputStream()));
    BufferedReader stdErr = new BufferedReader(new InputStreamReader(p.getInputStream()));
    Now; I have inserted "cmd.exe" for <YOUR COMMAND HERE>. If I write a command out to stdOutput, the first command executes, but not subsequent ones. Small segment looks like:
    while (line != null) {
    stdOutput.write("mkdir \"" + new_folder + "\"\n");
    stdOutput.flush();
    line = file_reader.readLine();
    This is an abridged version of my ode, but thats the problem. I get the first folder created, the process never terminates and I've tried emptying out the stdInput & stdErr bufferes, but it still won't execute subsequent commands issued to stdOutput.
    Can someone help me? I'd rather not write this all to a .BAT/.sh file :(

    I am quite perplexed now! I have just tried the following code on my PC, and have ended up with the most annoying two folders under my C:\ drive!
    import java.io.*;
    public class Cmd {
        public static void main(String[] args) {
            try {
                Process p = Runtime.getRuntime().exec("cmd.exe");
                BufferedReader stdInput = new BufferedReader(new InputStreamReader(p.getInputStream()));
                BufferedWriter stdOutput = new BufferedWriter(new OutputStreamWriter(p.getOutputStream()));
                BufferedReader stdErr = new BufferedReader(new InputStreamReader(p.getInputStream()));
    //            System.out.println(stdInput.readLine());
    //            System.out.println(stdInput.readLine());
    //            System.out.println(stdInput.readLine());
                stdOutput.write("mkdir \"c:\\folder1\"\n");
                stdOutput.flush();
    //            System.out.println(stdInput.readLine());
                stdOutput.write("mkdir \"c:\\folder2\"\n");
                stdOutput.flush();
    //            System.out.println(stdInput.readLine());
            } catch (IOException e) {
                e.printStackTrace();
    Perlexion over! Since you had your code in a loop I tried the same. I saw that in a loop creating 10 folders, the code created only two. See below the code that fixed this problem:
    import java.io.*;
    public class Cmd {
        public static void main(String[] args) {
            try {
                Process p = Runtime.getRuntime().exec("cmd.exe");
                BufferedReader stdInput = new BufferedReader(new InputStreamReader(p.getInputStream()));
                BufferedWriter stdOutput = new BufferedWriter(new OutputStreamWriter(p.getOutputStream()));
                BufferedReader stdErr = new BufferedReader(new InputStreamReader(p.getInputStream()));
                System.out.println(stdInput.readLine());
                System.out.println(stdInput.readLine());
                System.out.println(stdInput.readLine());
                stdOutput.write("mkdir \"c:\\folder1\"\n");
                stdOutput.flush();
                System.out.println(stdInput.readLine());
                stdOutput.write("mkdir \"c:\\folder2\"\n");
                stdOutput.flush();
                System.out.println(stdInput.readLine());
            } catch (IOException e) {
                e.printStackTrace();
    }Commenting out different combinations of System.outs gives different results.
    In summary: it is important that you match the correct number of output lines from the CMD.EXE output stream with readLines.
    I didn't like how the wording came out, but you get the gist.
    HTH,
    Manuel Amago.

  • Process never ends

    Hi,
    I'm developing -fixing somebody application- a SuperWaba application. SuperWaba is a poor minor release of Java Runtime. I'm transforming SQL Scripts into PDB files -i hate PDB files.
    I make a Class that extends MainWindow that is called by Waba Applet. Waba Applet extends Java Applet -I hope so. When I run my class from the shell (cmd, over a Windows XP), an Applet Window appears and execute without erros my script transforming a SQL script in one or multiple pdb files (depending number of create sentences).
    But, when i call my script from a PHP Script -i really hate this app, PHP + Java + ASP + Visual Basic ... can you believe it ? - the PHP Script launch Java, but Java app never ends blocking my PHP script. I think there is a problem in Applet Window creation, because there is no window or display to launch the app.
    There is a way to run an Applet in background with no visualization ?
    THX 4 Ur HELP

    i really appreciate your help but i forgot to explain the problem
    First, i decide to create a simple Java App that uses the PDBDriver JAR, but the #~"$%" Jar uses something from the Applet. When I run my class it launch these error.
    java.lang.NullPointerException
            at java.applet.Applet.getCodeBase(Unknown Source)
            at waba.applet.JavaBridge.openOutputStream(JavaBridge.java:533)
            at waba.applet.JavaBridge.writeBytes(JavaBridge.java:588)
            at waba.io.NativeMethods4JDK.catalogClose(NativeMethods4JDK.java:824)
            at waba.io.NativeMethods4JDK$CatalogBag.finalize(NativeMethods4JDK.java: 674)
            at java.lang.ref.Finalizer.invokeFinalizeMethod(Native Method)
            at java.lang.ref.Finalizer.runFinalizer(Unknown Source)
            at java.lang.ref.Finalizer.access$100(Unknown Source)
            at java.lang.ref.Finalizer$3.run(Unknown Source)
            at java.lang.Thread.run(Unknown Source)
    #2- url: file://localhost/nullfile.pdb
    found under localhost: file://localhost/nullfile.pdb
    file not found

  • Burning process never ends

    When I try to burn a CD, everything works fine until it begins "finishing" the disc. This process never actually finishes. I've let it run for more than an hour. I've ruined a handful of CDs already

    Had that a while ago, too with an old version of iTunes. I do not know why this happened. Although iTunes told me that it is still finishing the disc, I stopped that process and got the disc out of it's drive and I was surprised that the disc played fine.
    If you use an old version, try to update your iTunes.
      Windows XP   iPod mini 2nd gen.

  • Is the iTunes Match Updating (Library) Process Never Ending For You Too?

    I think that I added about 1200 songs to my iTunes Library over the past 3 days. A lot of those songs are obscure and are certainly NOT in the iTunes store so it will have to upload them, but this latest updating process is going so slow it seems like it might be stuck. I rebooted my system and started iTunes again. Maybe this will help. What's odd is that the process seems to linger near the end of 'Step 2: Matching Your Songs With Songs in The iTunes Store' indefinitely--which seems odd. I would think that if it was an 'uploading issue' that 'Step 3: Uploading artwork and remaining songs' would be where the process would hang up and not on Step 2, which should seemingly fly by.
    Has anyone else experienced this hang nail with iTunes Match?
    We have good speed broadband (cable supplied) Internet service through Time Warner.

    ST67 wrote:
    Going forward, I think Apple needs an iCoud/iTunes Match 'System Status Page' that users can check before they undergo big uploads at home.. Dropbox and many other Cloud-Based Services do that and I think Apple could certainly benefit from cluing in their customer base in Real Time.
    http://www.apple.com/support/icloud/systemstatus/
    But notice the date and status.  I also heard from phone support that this is really for iCloud and not necessarily iTunes Match itself.   I agree that they should extend this out to iTM as well - would make a lot of sense and would avoid the confusion we are experiencing.

  • PFI Compilation never ends

    Hi,
    I have been developping my app since 2 month now and I never had any problem with creating test ipas (ie:target = ipa-test). But when I decided to create my final build for the app store (target = ipa-app-store) the process never ends.
    I run the compilation and it seems to be doing something (I can see the temp files and hear the fans) but it just doesn't stop. I tried many times and usually kill the process after an hour or so.
    I know that other people had a similar problem but I didn't find any official answer for it. Is it a bug? Does it have a workaround?
    I'm on a Mac with Snow Leopard and tried to build the ipa from both Flash CS5 and a custom ant build.
    I would really appreciate some feedback about it.
    Cheers,
    Ben

    First and foremost, compiling for iOS takes a lot of resources, it cannot be compared to packaging for Android, because the process is completely different, AIR on Android runs interpreted code, while on iOS it is native code, before deciding the compilation is stuck you should check the java/adt processes aren't doing anything. It's been said future AIR versions will reduce iOS compilation times.
    Second, I've seen iOS compilation fail and take forever only when using certain ANEs and Flash Builder versions. FB doesn't take too well certain ANE warnings and errors, and instead of ignoring or finishing the process showing some alert, it just sits there making you wait forever. If you are using ANEs in your project, you should isolate the problematic one, and then determine what may be the cause... if some problem with the iOS SDK used with your AIR SDK, if the ANE is causing some unimportant warnings but your IDE doesn't like them, etc.

  • When I open iTunes , iTunes Match started to process step 1. Always same process and never ending

    When I open iTunes , iTunes Match started to process step 1. Always same process and never ending...
    I tried some suggestions but I cant fix my problem. Do you have any knowladge about this problem?

    For the past few months, and several iTunes upgrades, iTunes Match spends some time in Step 1 "Gathering" and sending information to Apple. Then Step 2 runs through the first 2092 of 2094 pretty quickly. Jumps to 2094. And then immediatly back to Step 1 again.
    Repeat every 5 minutes or so until Match is manually turned off.

  • Warp Stabilizer analysis process stopping and never ends (AE CC 2014)

    I'm running the latest 2014 AE CC and I've been getting this issue running Warp Stabilizer on my clips.  Intermittently, warp stabilizer analysis process would stop at certain frame and never ends.  I have to quit / kill AE.
    I'm running AE on 15" retina macbook pro 2013 with dedicated nvidia 750M video card, 16GB of RAM and plenty of disk space (over half a terabyte left), running Yosemite 10.10.2.
    Has anyone experienced this?  How do I solve this issue?

    "During the analysis and solving stages, the Warp Stabilizer effect and 3D Camera Tracker effect use memory outside of the pool shared by After Effects and Premiere Pro. Therefore, you can allocate more memory to the analysis and solving phases for these effects by increasing the RAM Reserved For Other Applications value in the Memory & Multiprocessing preferences."
    Thank you for that link.  I'm going to check the "RAM Reserved For Other Applications" and increase the value if it's too low.

  • Csimport that never ends

    Good morning,
    I am trying to import an ics calendar.
    This calendar has been export with csexport.
    The csexport takes a few seconds.
    But the csimport never ends (after several hours).
    There are 8000 events.
    A truss an the process show almost no nothing except:
    truss -p 16176
    brk(0x01B92320) = 0
    brk(0x01BA4320) = 0
    brk(0x01BB6320) = 0
    brk(0x01BC8320) = 0
    brk(0x01BDA320) = 0
    brk(0x01BEC320) = 0
    I have open call 70642348 because I am stuck.
    Would you know what I could do else to to import this ics file
    or to trace the problem?
    Thanks in advance for your help.

    Hi,
    I do not have other system, but I can provide you the ics file.
    You should immediatly see my problem.
    What I have find out also is that if I export with csexport rather than uwc,
    I do not have this problem although the files are very similar.It might be good to provide both .ics files on the Sun support call -- the calendar exported from uwc, and exported using csexport.
    Thanks.
    --Wei Yee                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • Essbase data load process never terminating

    Hi
    We are using Essbase 11.1.2.1.
    We try to load a data file into a BSO Essbase application (essbase export format, so no dataload). We are using "execute in background" option.
    If the file contents no unknown member : it is correctly loaded.
    If the file contents an unknown member : the data load is never terminated : we have killed it after more than 15 hours, and the request is still in "terminating" so we have to kill the essbase process on the server. No error message or file.
    Thanks in advance for your help
    Fanny

    Hi
    I try to start this discussion again, because we still have the same problem, and no idea of why (no idea from the Oracle support too) and my client is waiting for an explanation :-/
    So, some more details :
    Context :
    I have an export (essbase format) from a database.
    If I import this file in a database with all the members used in the file => no problem. The dataload takes around 10 seconds.
    If I import this file in a database with all the members used in the file, excepted 1 => problem. The data load never ends and I have to kill the Essbase application on the Essbase server.
    I have done another test :
    I have imported the file in a database with all the members used in the file (so no problem).
    I have exported level-0 data in columns.
    I have imported this new file in the database with all the members used in the file, using a DLR => no problem. The data load takes around 10 seconds, with a dataload.err generated.
    So, John, you are right, the client shoud really use a column format export. But I need to explain to him why he cannot (not should not) use an export format.
    If using an export format is possible : I have to identify my problem and make the right modification to solve the problem.
    If it not possible : this is a bug, and it is not my responsability anymore and I can close the project!
    Thanks in advance for your great ideas!
    Fanny

  • Generate New Database job never ends

    Hi all,
    We are trying to generate a new template in our DEV environment, the job remains active but never ends. On every attempt , the process stops in a different table or process.
    The log file (level 5) simply stops in a certain point and nothing else happens. The dbeng9 processes consumes almost 90% CPU but the process siebsh does not appear between the top processes.
    We already tried reset all the servers, gateway, reassign the remote component group, recreating diccache.dat, but nothing worked.
    We use siebel loyalty 8.1.1.1 and oracle 11g 11.2 , on top of aix 5.3
    Meanwhile, the workaround was to generate new template in another siebel enterprise and copied the templates to the DEV environment and extracted the databases.
    Will be very thankful if anyone can help.
    Thanks in advance

    But the problem is that the process really stucked. The siebel.dbf , which should be created during the job , stop increasing the size around 30M while in the other environment, when the process finished , the file reached 80M.
    The log file also suddenly stopped to increase. It really seems that the process is waiting for something.
    We are not having resource problems like disk space , cpu or memory lacking.
    Guys, do you know what kind of consistency should be checked for GennewDB? If the repository table definitions have differences when compared with actual physical schema, suppose that we forget to apply some new table definitions, would it be the root cause? Do you know a way to compare the repository definitions against the physical schema? I think "apply all" is not an option..
    Thanks in advance

  • [Help]: Web-Report is refreshed never end.

    Dear Collegues.
    Hi guys ...
    In the web-report,,, i intend to make the report can extend some Info Object automatically & programmatically.
    Hence, i use web-API & javascript to make it happened. How ??
    In the web-designer; especially in HTML part, i create javascript & web-API code:
    <script>
    function test() {
      SAPBWOpenURL("<SAP_BW_URL DATA_PROVIDER='ZCVP_CON' CMD='EXPAND' IOBJNM='ZBRSLSPR' AXIS='Y'>");
    test();
    </script>
    I add this before the row of code : </BODY>
    Virtually, this line of code worked (It can expand the InfoObject/Characteristi/Key Figure that i want to) .. But..
    The report Web-Report is Refreshed never ending.
    <b>Could somebody tell me how to make some function is run only once ??</b>
    Should i check the session/something?? For Example the catche.
    Could somebody give me the clues how to make it happened ??
    If any of you little bit don't understand with my explanation & questions, p/s don't hesitate to ask me to make it clear.
    Kind Regards,
    Niel

    Hi Deepu,
    Basically, we're gonna make the process automatically run therefore i didn't use button/link to make it.
    Do you have any idea how to make the function run once???
    Because if we refer on ASP programming, it has condition to make sure some function is run only once.
    Many Tks Deepu.
    Kind regards,
    Niel.

  • AdamSync from AD to LDS goes into a continuous never ending loop... can't figure this out.

    I THINK I've got this thing configured up to the point where it should be able to sync.  The XML config is set to just grab a single OU with roughly 12 accounts in it.
    Everything seems to connect OK, then it does a ton of "Processing Entry", even though there are only a few accounts in this OU.
    Then it begins to do "Adding target object..." and gets stuck in a never ending loop.
    Can someone point me in the right direction on how to troubleshoot this?
    This is what the log looks like:
    ==========================
    Adamsync.exe v1.0 (6)
    Establishing connection to target server localhost:6389.
    There is already an active sync session in progress. 
    Please allow the session to complete, or use -mai to seize the role.
    Saving Configuration File on CN=Test,DC=domain,DC=org
    Saved configuration file.
    ADAMSync is querying for a writeable replica of 10.10.10.10.
    Error: DCLocator call failed with error 1355. Attempting to bind directly to string.
    Establishing connection to source server 10.10.10.10:389.
    Using file .\dam9280.tmp as a store for deferred dn-references.
    Populating the schema cache
    Populating the well known objects cache
    Starting synchronization run from dc=domain,dc=org.
    Starting DirSync Search with object mode security.
    Processing Entry: Page 1, Frame 1, Entry 0, Count 0, USN 0
    Processing source entry <guid=94f6d930da2339439df75278a02accae>
    Previous entry took 0 seconds (0, 0) to process
    Processing Entry: Page 1, Frame 1, Entry 1, Count 1, USN 0
    Processing source entry <guid=bf15bc4b684ece4f99010548e79decb0>
    Previous entry took 0 seconds (0, 0) to process
    Processing Entry: Page 1, Frame 1, Entry 2, Count 1, USN 0
    Processing source entry <guid=fcea01637658134eab7ec74fe022d4fe>
    Previous entry took 0 seconds (0, 0) to process
    Processing Entry: Page 3, Frame 1, Entry 35, Count 1, USN 0
    Processing source entry <guid=5e768f4392863b4d86935e6bf01acc25>
    Previous entry took 0 seconds (0, 0) to process
    Processing Entry: Page 3, Frame 1, Entry 36, Count 1, USN 0
    Processing source entry <guid=b5d263a264aad045b8f42f19b49dd844>
    Previous entry took 0 seconds (16, 0) to process
    Processing Entry: Page 3, Frame 1, Entry 37, Count 1, USN 0
    Processing source entry <guid=f19994051c804846b7bcbd066d9e9d40>
    Previous entry took 0 seconds (0, 0) to process
    Processing Entry: Page 3, Frame 1, Entry 38, Count 1, USN 0
    Processing source entry <guid=b16cd765bafa4f4d8649d91f0f055e5f>
    Previous entry took 0 seconds (0, 0) to process
    Processing Entry: Page 3, Frame 1, Entry 39, Count 1, USN 0
    Processing source entry <guid=6be6a7d551978445aafd3803e60dc560>
    Processing in-scope entry 6be6a7d551978445aafd3803e60dc560.
    Adding target object CN=User Name,OU=Staff Accounts,OU=Users,OU=ITS,CN=Test,dc=domain,dc=org.
    Adding attributes: sourceobjectguid, instanceType, objectSid, sAMAccountName, lastagedchange, objectclass, 
    Adding target object CN=User Name,OU=Staff Accounts,OU=Users,OU=ITS,CN=Test,dc=domain,dc=org. Requesting replication of parent.
    Previous entry took 0 seconds (0, 0) to process
    Processing Entry: Page 3, Frame 2, Entry 0, Count 0, USN 53438354
    Processing source entry <guid=bbb4a760a8281741a11d9331efaa3d7a>
    Processing in-scope entry bbb4a760a8281741a11d9331efaa3d7a.
    Adding target object OU=Staff Accounts,OU=Users,OU=ITS,CN=Test,dc=domain,dc=org.
    Adding attributes: objectClass, instanceType, sourceobjectguid, lastagedchange, 
    Adding target object OU=Staff Accounts,OU=Users,OU=ITS,CN=Test,dc=domain,dc=org. Requesting replication of parent.
    Previous entry took 0 seconds (0, 0) to process
    Processing Entry: Page 3, Frame 3, Entry 0, Count 0, USN 52660067
    Processing source entry <guid=8d3ef319dff31f47819632af2da5df2c>
    Previous entry took 0 seconds (0, 0) to process
    Processing Entry: Page 3, Frame 2, Entry 0, Count 0, USN 53438354
    Processing source entry <guid=bbb4a760a8281741a11d9331efaa3d7a>
    Processing in-scope entry bbb4a760a8281741a11d9331efaa3d7a.
    Adding target object OU=Staff Accounts,OU=Users,OU=ITS,CN=Test,dc=domain,dc=org.
    Adding attributes: objectClass, instanceType, sourceobjectguid, lastagedchange, 
    Adding target object OU=Staff Accounts,OU=Users,OU=ITS,CN=Test,dc=domain,dc=org. Requesting replication of parent.
    Previous entry took 0 seconds (0, 0) to process
    Processing Entry: Page 3, Frame 3, Entry 0, Count 0, USN 52660067
    Processing source entry <guid=8d3ef319dff31f47819632af2da5df2c>
    Previous entry took 0 seconds (0, 0) to process
    ===================================================

    Hi,
    Are there any error messages from the event log?
    Here is a KB article which describes a similar issue below I suggest you refer to:
    Error message when you use the Adamsync tool in Windows Server 2003: "Error: We seem to be in an infinite recursive loop"
    http://support2.microsoft.com/kb/926933
    Best Regards,
    Amy

  • SOLUTION for the never ending reboot loop when charging

    I used my iPad until the battery was completely flat, then when I went to charge it, it got stuck in the never ending reboot loop where it shows the Apple logo for about 30 seconds, then shows the home screen for a split second before shutting down and repeating the whole process again and again.
    So here's what you need to do to fix this problem without having to restore or plug into iTunes.
    1. Plug in the charger
    2. When the Apple logo appears, unplug the charger
    3. As soon as you see the home screen appear, plug the charger back in. You need to do this quickly as the home screen only shows for a split second
    4. The loading wheel should appear and shut down the iPad
    5. Leave the iPad for a good 30mins or so just to get some battery life into before you start using it again.
    And that's it!

    Figured I'd start recording the errors I get in the Installer Log:
    localhost : BomFatalError - cpio read error: bad file format
    localhost : Install failed: some files for GarageBandinstrumentsTiger may not have been written correctly.
    localhost : BomFileError 0: Unknown error: 0 - ./Instrument Library/Sampler/Sampler Files/Grand Piano/054F#2KM56M.wav
    localhost : Install failed: some files for GarageBandinstrumentsTiger may not have been written correctly.
    localhost : BomFatalError - cpio read error: bad file format
    localhost : Install failed: Some files for iDVDThemes_Tiger may not have been written correctly.
    localhost : BomFatalError - cpio read error: bad file format
    localhost : Install failed: Some files for iWeb_App may not have been written correctly.
    localhost : Install failed: Error encountered while writing receipt for iWebtempja.
    localhost : BomFatalError - cpio read error: bad file format
    localhost : Install failed: Some files for iWork Trial may not have been written correctly.

Maybe you are looking for