ts-7000
[Top] [All Lists]

Re: [ts-7000] how to set server's time from web client?

To:
Subject: Re: [ts-7000] how to set server's time from web client?
From: Ken Lu <>
Date: Fri, 28 Oct 2011 06:48:43 -0700 (PDT)


Thanks, all.  

I did a program to telnet and execute command.  But I found the TS-Linux's date command does not receive the second value.  Whatever you set the second value by command last with .ss, the Linux clock is always start from 0 second.  Can any one confirm that?  


Ken


--- On Wed, 10/12/11, Jim Jackson <> wrote:

From: Jim Jackson <>
Subject: Re: [ts-7000] how to set server's time from web client?
To:
Received: Wednesday, October 12, 2011, 5:55 PM

 



On Wed, 12 Oct 2011, Ken Lu wrote:

> It seems my TS-7400(system shows 7200) does not have it.
> Basically I understand the reason, is by default, the Apache configed a
> user nobody as web client(when access from web page)  does not  have a
> root privilege to set time.  Unless we can chang that.

This is basic web stuff under Linux. There are several options, among which
is the sudo command, and edit the configuration file /etc/sudoers to allow
"nobody" to execute the date command as root.

An alternative is to write a short program to do what you want as root and
set the "s" bit on the, root owned, executable. For more info google for
linux setuid. Though this method is a bigger security problem :-(

>  
>
>
> --- On Wed, 10/12/11, Walter Marvin <> wrote:
>
>
> From: Walter Marvin <>
> Subject: Re: [ts-7000] how to set server's time from web client?
> To: "" <>
> Received: Wednesday, October 12, 2011, 9:43 AM
>
>
>
>  
>
>
>
>
>
> on the 7500 its ts7500ctl
>
>
>
>
>
> From: Ken Lu <>
> To:
> Sent: Wednesday, October 12, 2011 9:30 AM
> Subject: Re: [ts-7000] how to set server's time from web client?
>
>
>
>  
>
>
>
>
> Thanks, what commend for TS client?
> I found a clue, with "whoami" command, return "nobody".  That is the reason.
>
> --- On Wed, 10/12/11, Walter Marvin <> wrote:
>
>
> From: Walter Marvin <>
> Subject: Re: [ts-7000] how to set server's time from web client?
> To: "" <>
> Received: Wednesday, October 12, 2011, 12:27 AM
>
>
>
>  
>
>
> don't use date to set the time use the TS client
>
>
>
>
>
> From: Ken Lu <>
> To:
> Sent: Tuesday, October 11, 2011 5:54 PM
> Subject: Re: [ts-7000] how to set server's time from web client?
>
>
>
>  
>
>
>
>
> No luck.  I tested any command works, like touch, rm, cat, ps...  but not date setting, even add -s.  I can also use script to run other script file, works too.  Since I can run those command, I think is not root privilege problem.  I also tested using sh or ash to run, same result.  Don't under stand the "date" command has something special.
>
>
>
>
> --- On Tue, 10/11/11, Walter Marvin <> wrote:
>
>
> From: Walter Marvin <>
> Subject: Re: [ts-7000] how to set server's time from web client?
> To: "" <>
> Received: Tuesday, October 11, 2011, 3:51 PM
>
>
>
>  
>
>
> get the script to run at the Linux prompt first. If necessary use the set root method to give the script root privelage
>
>
>
>
>
>
> From: Ken Lu <>
> To:
> Sent: Tuesday, October 11, 2011 2:57 PM
> Subject: Re: [ts-7000] how to set server's time from web client?
>
>
>
>  
>
>
>
>
>
> Yes I have.  But we need accurate to second.   Now my cgi file includes this:
> echo "$(date 090909092011%n)"
> After running, I can see this:
> Fri Sep 9 09:09:00 UTC 2011
> from browser.  Same action as we type "date 090909092011" at Linux $ prompt.   But the Linux time did not change.  I don't know why.  Just suspect the time changed needs root?
>
> --- On Tue, 10/11/11, harry olar <> wrote:
>
>
> From: harry olar <>
> Subject: Re: [ts-7000] how to set server's time from web client?
> To: "" <>
> Received: Tuesday, October 11, 2011, 2:26 PM
>
>
>
>  
>
>
>
> See the threads about changing time.
>
> The RTC modules are optional on some boards. Do you have the module?
>
>
>
>
>
>
>
>
>
>
>
>



__._,_.___


Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required)
Change settings via email: =Email Delivery: Digest | m("yahoogroups.com?subject","ts-7000-fullfeatured");=Change Delivery Format: Fully Featured">Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | =Unsubscribe

__,_._,___
<Prev in Thread] Current Thread [Next in Thread>
Admin

Disclaimer: Neither Andrew Taylor nor the University of NSW School of Computer and Engineering take any responsibility for the contents of this archive. It is purely a compilation of material sent by many people to the birding-aus mailing list. It has not been checked for accuracy nor its content verified in any way. If you wish to get material removed from the archive or have other queries about the archive e-mail Andrew Taylor at this address: andrewt@cse.unsw.EDU.AU