LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 01-06-2002, 10:18 PM   #1
xanthium
Member
 
Registered: Apr 2001
Location: Bombay ( INDIA )
Distribution: RedHat 7.x
Posts: 218

Rep: Reputation: 30
Time


Hi ,

Iam writing a script which will let me know the time on a remote linux machine.

I dont want to use NTPD but i can use any of the "r" series of command ... security is no issue. Since iam using a shell script i need non-interactive solution.

Can anybody help?

Regards,
Xanthium.
 
Old 01-12-2002, 09:41 PM   #2
crabboy
Senior Member
 
Registered: Feb 2001
Location: Atlanta, GA
Distribution: Slackware
Posts: 1,821

Rep: Reputation: 121Reputation: 121
Hmm..
Code:
rsh machine date
 
Old 01-14-2002, 12:57 AM   #3
kervin
Member
 
Registered: Jan 2002
Location: Melbourne, FL.
Distribution: redhat
Posts: 168

Rep: Reputation: 31
You do not have to use ntp or sntp, although I'd recommend them.

use the 'rdate' command. Most servers have the rdate port open by default, but if it isn't then it's only one line in the inetd.conf or xientd.conf. the time server for rdate is internal to the inetd superserver ( just as the 'echo' server is, etc. ) so it should be a resource issue.

If you do not use rdate, may I suggest 'ssh' instead of rsh. if you configure ssh with public key encryption you can run remote commands very easily, and very sucurely. eg.
'ssh remote_server ls -la /' will list files in the root directory on remote_server. Just like with rsh.
 
Old 01-14-2002, 05:19 AM   #4
xanthium
Member
 
Registered: Apr 2001
Location: Bombay ( INDIA )
Distribution: RedHat 7.x
Posts: 218

Original Poster
Rep: Reputation: 30
Thumbs up Thanks

Hi ,

thanks a lot for all the help.

Regards,
Xanthium.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Doub about `net time set` and daylight saving time Thakowbbery Linux - Software 0 10-17-2005 05:23 AM
ps2 mouse freezing on FC1/FC2 from time to time farpoint Linux - Hardware 5 08-14-2005 02:20 PM
How to syncronize my system time by public time server? hakansun Linux - Networking 1 09-10-2004 05:10 AM
no signal when starting xorg for the 1st time (but the second time works fine) bungalowbill Linux - Software 0 06-04-2004 09:56 AM
Setting System Time: kernel in wrong time zone warrenweiss Linux - General 7 05-15-2004 03:25 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 10:37 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration