How to set the system clock in win2000? in linux? (RH)

hi There,
I need to set the system time on a pure java application.
what is the proper way to do so? (I can't find any system property which corresponds to the system clock).
if it's platform dependent , then I need to do so on win2000 and on linux RH.
thanks

I don't know about Windows but on RedHat, I would use the date command. Check the man pages for date and look at the -s or --set options.  Do a Runtime.exec to execute that.
Of course, doing the in Java is not the best option. If you are trying to synchronized clocks on Windows and Linux systems, I would use some freely available Network Time Protocol programs. RedHat has a free NTP daemon available as an RPM in the standard distribution. For Windows, theres a free program called "Net Time" that runs as a service. Both can act as clients and servers.

Similar Messages

  • How to set the System Setting

    Hi guys
    I have Final Cut Express for a few years but I don’t practice very often, I use it once or twice a year when I have a family project to do. I am confused with the Scratch Drive vs the Final Cut Express Document Folder (Scratch disk>F.C.E. Documents>). About 2 months ago, I start a New project. Before that, I cleared up all the previous project files and from the Preferences I trashed the com.apple FinalCutExpress Plist and from the Final Cut Express User Dater File I trashed the F.C.E. 4.0 Pref and the Ojb Cache and reset my Scratch Disk for capturing (not the startup). Now my editing is almost done. Last week I open the Scratch Drive >Final Cut Express Document Folder, I notice there is no captured files (captured materials,data or media) anywhere in the Capture Scratch, Autosave Vault,Thumbnail Cache File and the Waveform Cache File but there are files in the Audio Render File and the Render File (I suppose this Render File is the Video Render). I open the System Setting, I notice I have set the Scratch Disk for Video Capture, Video Render and Audio Render, the rest are set for Startup Disk; I went to the Startup disk, I found them all filled with something, but I have no idea where to locate my captured materials and I am not sure if these settings are correct or they should all be set to store in the Scratch Disk instead. I am all confused. Right now my questions are where to locate my captured materials (data/medias) and how do I reset the above settings if they need to be reset? I appreciate some one will take time to explain all these to me. My equipment is G4, Final Cut Express 4.0 with OX 10.5. If further info is needed, please adv.
    Thank you ALL.

    If I understand your advice correctly, after the current project is done, I should reset the Thumbnail >Cache File and the Waveform Cache File to the Scratch Disk and leave the Autosave Vault in the >Startup Disk because it is safer.
    Yup. Plus back up your Project file to another media type, CD etc. for double security.
    not to change the clip names either.
    Changing names is fine if you do this within the FCE application because FCE still knows where to find the file. If you change the name in the Scratch Disc through the Finder, FCE will loose the link.
    don’t know how to reconnect them
    Right click an offline clip in the Browser and select reconnect, navigate to where the clip is stored through the window that appears.
    You can search this forum for details and all is explained in the FCE manual.
    Here's one:
    http://discussions.apple.com/thread.jspa?threadID=1968953&tstart=15
    Al

  • How to set the system date and time in LabVIEW 6i?

    Hi,
    How can I set the time of the computer from Labview 6i? Is there any function to do this?
    Thanks.

    Arnau wrote in message news:<[email protected]>...
    > Hi,
    >
    > How can I set the time of the computer from Labview 6i? Is there any
    > function to do this?
    >
    > Thanks.
    Not natively that I know of. You could use a LabVIEW DLL call to link
    to a Win32 API call which sets the date and time. You would need to
    have privileges to do it.
    Doug D.
    [email protected]

  • How to set the system time in the program

    Hi All,
    How do we update the system time inside java programme.

    AFAIK there is no easy (pure java) way: either you exec something (depending on your paltform) or use native code. Appropriate privileges will be necessary.

  • How to set the working directory for reports in linux

    Hi All,
    Can you anyone help me to set the working directory for oracle application server 10g reports? I am using RHEL4 and AS10g. Actually i want to run my reports from my define
    working directory. How can I do this?
    Thanks in advance
    Arif

    Hi,
    your rep_srv.conf should look like something like
    +<?xml version = '1.0' encoding = 'ISO-8859-1'?>+
    +<!DOCTYPE server PUBLIC "-//Oracle Corp.//DTD Reports Server Configuration //EN" "file:D:\oracle\FRHome_1/reports/dtd/rwserverconf.dtd">+
    +<server version="10.1.2.0.2">+
    +<!--Please do not change the id for reports engine.-->+
    +<!--The class specifies below is subclass of _EngineClassImplBase and implements EngineInterface.-->+
    +<cache class="oracle.reports.cache.RWCache">+
    +<property name="cacheSize" value="50"/>+
    +<!--property name="cacheDir" value="your cache directory"-->+
    +<!--property name="maxCacheFileNumber" value="max number of cache files"-->+
    +<!--property name="ignoreParameters" value="parameter names to be ignored in constructing cache key, separated by comma ','"-->+
    +</cache>+
    +<engine id="rwEng" class="oracle.reports.engine.EngineImpl" initEngine="1" maxEngine="3" minEngine="0" engLife="50" maxIdle="30" callbackTimeOut="90000" jvmOptions="-Xmx512M -Xss512K">+
    +<!--property name="sourceDir" value="your reports source directory"/-->+
    +<!--property name="tempDir" value="your reports temp directory"/-->+
    +<!--property name="keepConnection" value="yes"/-->+
    +</engine>+
    +...+
    some more definitions
    +..+
    +<!--pluginParam name="proxy" type="file">proxyinfo.xml</pluginParam-->+
    +<pluginParam name="xmlpds" type="file">xmlpds.conf</pluginParam>+
    +<pluginParam name="jdbcpds" type="file">jdbcpds.conf</pluginParam>+
    +<pluginParam name="textpds" type="file">textpds.conf</pluginParam>+
    *<environment id="APP1">*
    *+<envVariable name="REPORTS_PATH" value="/application1/reports"/>+*
    *+</environment>+*
    *+<environment id="APP2">+*
    *+<envVariable name="REPORTS_PATH" value="/application2/reports"/>+*
    +</environment>+
    +</server>+
    The environment ids you can choose yourself and you have to put them in there yourself too (here I put two environments for two different applications "1" and "2").
    If you call a report from Forms, then you have to code something like
    ADD_PARAMETER(p_list,'ENVID',TEXT_PARAMETER,'APP1');
    Details depend on how you call your reports, my example is for using a parameter list and calling a report out of application1
    Hope that helps.
    Volker

  • How to set the system default file character encoding to UTF-8?

    Hi all. This is driving me nuts, on both my Windows box and Snow Leopard; I figure much more chance of finding the answer for OS X.
    My language and locale are set to Australian English. $LANG=en_AU.UTF-8
    However, as I believe is expected, OS X (and Windows for that matter) will create files by default with character encoding of Cp1252 (Latin-1). That is, the FILE encoding in the file metadata - the Byte Order Mark I believe. The file itself, not the characters written to it.
    This, in a word, bites. I don't want to be restricted to only ASCII by default, and it is causing me problems with certain software (a Firefox plugin) that creates text files, passing in UTF-8 encoded content, which is then mangled because the file encoding itself is still Cp1252. (I know, I've tested this by changing the file encoding manually and having it overwritten again by the plugin: works correctly.)
    As a simple example, just `touch somefile` from terminal creates a file in Cp1252 -- I'm obtaining that info by opening in jEdit by the way (anyone know of something better?).
    In other locales that are not English-based, I believe the default file encoding is UTF-8. But surely this can be controlled independently? There must be a system configuration value somewhere that specifies file encoding default. Can someone please tell me what it is?
    Thanks!

    However, as I believe is expected, OS X (and Windows for that matter) will create files by default with character encoding of Cp1252 (Latin-1). That is, the FILE encoding in the file metadata - the Byte Order Mark I believe. The file itself, not the characters written to it.
    Apps like TextEdit and Mail have settings that let you determine the encoding of text produced. The default would normally depend on the character content of the file, ranging from ASCII for basic English to Windows Latin-1 (Win 1252) or ISO Latin -1 (ISO 8859-1) to UTF-8 for other content.
    Win 1252 is not ASCII, but has twice the number of characters in the latter.
    Byte Order Mark is something totally different --it's a particular character used to signal certain encodings.
    http://en.wikipedia.org/wiki/Byteordermark
    As a simple example, just `touch somefile` from terminal creates a file in Cp1252 -- I'm obtaining that info by opening in jEdit by the way (anyone know of something better?).
    For what Terminal does and how to change it, it might best to post in the Unix forum:
    http://discussions.apple.com/forum.jspa?forumID=735
    For problems with a FireFox plugin, it might be good to ask on their own forums as well.

  • How do set the system parameter for user defaults?

    When we are creating new users they are getting the European default for date format and decimal format.  I have found is there is a structure BAPIDEFAUL that contains these values.  However, I have not found the configuration for changing these values.  Does anyone have the answer to this problem?

    Ronald,
    with USERS_GEN, users are created with BBP_USER_CREATECP.
    This function uses DEFAULTS to pass parameters.
    But those parameters are not available in interface or file upload
    USERS_GEN will take default values in system parameters:
    Set date format and decimal format like in system parameters
      data: defaults   type bapidefaul.
      clear defaults.
      CALL 'C_SAPGPARAM'
           ID 'NAME' FIELD 'zcsa/moddatfm'
           ID 'VALUE' FIELD DEFAULTS-DATFM.
      CALL 'C_SAPGPARAM'
           ID 'NAME' FIELD 'zcsa/moddcpfm'
           ID 'VALUE' FIELD DEFAULTS-DCPFM.
    So, this is the only way to "customize" it: define system parameters zcsa/moddatfm & zcsa/moddcpfm in RZ10.
    Rgds
    Christophe

  • Have a compaq nc6320 laptop the system clock is set to 6/3/9999

    why can't I seem to change the clock on this laptop couldnt find in bois where to set bois clock and tgried to change in windows 7 and it will not change

    I am not a Mac user, but have multiple versions and profiles of Firefox. I note you ask about Macs, but have system details showing as Windows 7.
    I can only speak from a PC perspective, but no doubt you can sort it out yourself. It is down to the OS which browser is the default, although firefox has the option to check and reset that at startup.
    No doubt if I delved into the registry I could find how it sets the default browser, but in practical terms what I do is allow the OS to set itself up.
    # Choose any other alternative browser such as IE, make that the default, and allow that to take effect.
    #Then deselect IE as default browser checking.
    #Now start up the chosen version of Firefox, use Firefox's options to set that as default browser. (Options -> advanced -> general system defaults )
    It works, although some applications may choose IE regardless.
    *You may be interested in http://kb.mozillazine.org/Default_browser
    With luck something similar may work on a Mac

  • 1.5 How to globally set the System Cache location

    FROM ANOTHER USER ON ANOTHER BOARD:
    This one did not get answered completely.
    ************************* Question:
    Hello,
    I want to deploy JWS on a client PC with Microsoft XP OS. This client have multiple users. JWS put a file deployment.properties in the directory "documents and setting" for the current user.
    How can I create a uniquely file deployment.properties for all users of this client (new and existing profiles) ?
    Create a directory "documents and setting/all users/application data/sun/java/deployment/" with the file deployment.properties don't work.
    Create a directory "documents and setting/default user/application data/sun/java/deployment/" with the file deployment.properties is working but is not good for the existing users. This is good uniquely for new users.
    is there a solution ?
    King regards,
    funchung
    ************************* ANSWER:
    For windows, the system config file is at:
    {Windows Directory}\Sun\Java\Deployment\
    The value of the {Windows Directory} is determined by using the Win32 API GetWindowsDirectory.
    So for example, on XP, the system config file is:
    c:\WINDOWS\Sun\Java\Deployment\deployment.properties
    The settings in this system config file will be used by all users on the system.
    ***************************** HIS REPLY
    I've tried this and it doesn't seem to work.
    I've also tried createing a deployment.config file as per the http://java.sun.com/j2se/1.5.0/docs/guide/deployment/deployment-guide/properties.html article and this doesn't work for me.
    Has anyone done this successfully??
    ******************************** MY REPLY:
    This is true.
    I can get the system install to work if I add the parameter:
    deployment.system.cachedir=C\:\\testcache
    to the deployment.properties file found under:
    C:\Documents and Settings\username\Application Data\Sun\Java\Deployment
    but it will NOT work by adding it to the:
    C:\WINDOWS\Sun\Java\Deployment
    directory. It just creates a new default one in the user's folder.
    What am I doing wrong?
    If there is not a way to globally set the System Cache location, then this isn't much better than the user cache for being able to "install" the software once on the PC and let any user that signs in access that application.
    We had high hopes for this, since this functionality was taken away from us once the java cache started being stored in the user's folders.
    More details:
    I just tried setting the mandatory=true setting and it tells me that it is not allowed to start because it can't find the
    deployment.properties in the same folder (full path is displayed) but I know it is there, because it is the same folder. I even double checked the spelling.
    Maybe there is a bug in the way it finds that properties file, or maybe I need to include something in that file that I didn't find in documentation?
    All it has in it is the one line:
    deployment.system.cachedir=C\:\\testcache
    Can anybody help shed light on this?
    It seems to be a bug that it can't find the deployment.properties file in the 'system' folder.
    -Chris

    I now found more on another thread:
    http://forum.java.sun.com/thread.jspa?messageID=3500778&#3500778
    You can close this one.
    Sorry.

  • How do you get permission for FlexLm/HASP to access the system clock?

    I've got animation software that accesses the system clock to verify a security dongle. It works fine under 10.4.3, but I recently got a dual processor G5 with 10.4.5 on it. According to the s/w tech people, the dongle mgmt s/w doesn't have permission to access the system clock because of new security fixes. Anybody have any idea how I can open permissions to the system clock so I can get back to work?
    Thanks for any help you can offer...
    Brian

    Moving this discussion to the Using Flash Builder forum. 
    I believe the software though is working as designed.  From previous discussions I have seen the Design view was removed in Flash Builder 4.7.  The users in this forum may be able to provide additional information around this.

  • How to set a system property via the config tool?

    Hello,
    how can I set a system property via the config tool? Before I chose WAS from SAP I used java with option -D<name>=<value> to set the system properties.
    Very much thanks in advance.
    Regards
    Carsten

    Hi Carsten,
    WAS config tool is located under
    e.g. usr\sap\J2E\JC00\j2ee\configtool
    start configtool.bat
    there will be opened a configuration tool GUI
    Click on the instance_ID.... leaf of the tree in the left pane and then on the server_ID.... leaf.
    Java settings will appear in the right pane after this steps.
    Best Regards,
    Violeta

  • How to set the classpath in windows operating system

    hi,
    how to set the classpath in window operating system
    i want this help for setting the classpath for the tomcat
    please help me
    thank you
    darshan soni

    Open autoexec.bat in texteditor. This is an example from my autoexec, win me. Running resin
    SET CLASSPATH=c:\jdk1.3.1_01\bin\;c:\andreas\resin\bin\jsdk23.jar;c:\Jimi\JimiProClasses.zip;
    SET PATH=C:\WINDOWS;C:\WINDOWS\COMMAND;c:\jdk1.3.1_01\bin\;c:\andreas\resin\bin\jsdk23.jar;c:\Jimi\JimiProClasses.zip;C:\Program\MtsAndreas

  • How do I set the master clock output frequency on the PCI-1424?

    I want to use the master clock to generate the pixel clock to the imaging chip.

    Hi,
    We have tried everything to be able to set the Master Clock Frequency (please confirm pins 89 and 90 on the 100 pin connector). Everything we try including opening NI supplied camera files sets the Master clock to 40MHz.
    You're code however does do something, the Master clock frequency is set to 5MHz when we open a camera file with your code included. All the attributes show up in MaX but changing the values from Max has no effect, and the frequency remains at 5MHz. We undertake an apply and snap after each change of value with no effect.
    Am I missing something as the command OnBoardClock is supposed to be used to set the Master Clock Frequency, but you don't use that in your text at all. I would appreciate an explanation of the text yo
    u use, if you have the time, as I cannot find any reference to how the software knows what "Frame Grabber Clock" is.
    Thank you in advance for your help.
    Andy

  • How do I set the system time?

    Hello
    The system time can be read using System.currentTimeMillis(), but, how can I set it?
    Thanks

    several approaches:
    you could use the OS function to set and call it via Runtime.exec().
    For WIndows e.g.: "time 08:15:00" to set the system time.
    another solution: http://www.rgagnon.com/javadetails/java-0285.html

  • How can I use the system clock.

    My java program need to use the system clock to initiate some functions. Is there a method to do this or do I need to create one ??
    Any help appreciated.

    The following article will likely contain information useful to you:
    Working in Java time: Learn the basics of calculating elapsed time in Java

Maybe you are looking for

  • Sun Application Server 8.2

    When I try to debug my enterprise application in netbeans 5.0, I get the following errormessage: Deploying application in domain failed; Could not rename C:\Sun\AppServer\domains\domain1\applications\j2ee-apps\entityautocomp to C:\Sun\AppServer\domai

  • How to get and save the incoming filename in to db in biztalk.

    Hi, I need to save the incoming file name in to a table in biztalk. Below are the steps which are needed 1) Need to get the incoming file in orchestration 2) Map the incoming file in to field from source to destination schema(db) - such that file nam

  • Getting cfgrid (flash) to submit a row

    Hi all, I'm at about my wits end on this...I can submit a row from a query set in cfgrid if I set it to format=html and it works just fine.  However, with that format, I cannot sort columns which is necessary.  So, I set format=flash and the formatti

  • Batch Exporting  Color Corrected Clips, QT issues

    Hello, I work for a small ad company with a couple guys on the road shooting video, a video editor(me) and a few graphic designers. For company workflow reasons I take video footage from guys on the road and export to Quicktime movies(5-50 per client

  • Warcraft3-Problem (Doesn't connect to Bnet)

    Hi! I am having a strange problem with Warcraft3: When starting with wine it starts normally but then hangs on connecting to the Battle.net (it says "initiating connection to Battle.net" but nothing happens, no error-message whatsoever. When starting