04-25-2011
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Is there an easy method to do an on the fly conversion of a standard epoch time (seconds from 1970) to more readable date format?
Does Unix have anything built in to do this? (4 Replies)
Discussion started by: LordJezo
4 Replies
2. UNIX for Advanced & Expert Users
hi all :confused:
i am wondering if there is a way to convert from EPOCH time to the standard tim, may be using a script or some thing else???????
thanks............................ (5 Replies)
Discussion started by: TheEngineer
5 Replies
3. Shell Programming and Scripting
I have a file named "suspected" with series of line like these :
{'protocol': 17, 'service': 'BitTorrent KRPC', 'server': '219.78.120.166', 'client_port': 52044, 'client': '10.64.68.44', 'server_port': 8291, 'time': 1226506312L, 'serverhostname': ''}
{'protocol': 17, 'service': 'BitTorrent... (3 Replies)
Discussion started by: rk4k
3 Replies
4. Shell Programming and Scripting
Hi guys,
I know that this topic has been discuss numerous times, and I have search the net and this forum for it.
However, non able to address the problem I faced so far.
I am on Solaris Platform and unable to install additional packages like the GNU date and gawk to make use of their... (5 Replies)
Discussion started by: DrivesMeCrazy
5 Replies
5. Solaris
how can I get the current standard epoch time (seconds from 1970) in a shell script?
I know I could do this with a bit of perl of even c++ but i want to do it in Bourne shell..... (14 Replies)
Discussion started by: robsonde
14 Replies
6. Shell Programming and Scripting
Hi,
Is there any easy way to convert date time(stored in shell variable ) to epoch time in solaris box? As +%s is working on linux but not on solaris, also -d option is not working.
Any suggestion please? (6 Replies)
Discussion started by: anshuman0507
6 Replies
7. Shell Programming and Scripting
Hi there
I came across this script online to convert Epoch time to proper date format, but I am receiving the following error
Also, I have HISTTIMEFORMAT set in user's .profile so that their history output shows time stamps. Additionally I have changed their .history location to a dedicated... (9 Replies)
Discussion started by: hedkandi
9 Replies
8. Shell Programming and Scripting
how can i modify the following command to instead provide the epoch time of the interfaces file?
perl -le 'print scalar localtime ((stat "/home/skysmart/interfaces"))'
Tue Feb 19 03:44:52 2013
i'm hoping to get the equivalent of this command:
stat --format=%Y /home/skysmart/interfaces
... (2 Replies)
Discussion started by: SkySmart
2 Replies
9. Shell Programming and Scripting
# date +%s -d "Mon Feb 11 02:26:04"
1360567564
# perl -e 'print scalar localtime(1360567564), "\n";'
Mon Feb 11 02:26:04 2013
the epoch conversion is working fine. but one of my application needs 13 digit epoch time as input
1359453135154
rather than 10 digit epoch time 1360567564... (3 Replies)
Discussion started by: vivek d r
3 Replies
10. Shell Programming and Scripting
Team,
I am working on a shell script and i am extracting a date string in "SunOS server" with below format.
Mon Jan 21 04:13:48 EST 2021
Can you please assist me the best way to convert the extracted string to epoch time like "date +%s" in Linux.
Thanks in advance (1 Reply)
Discussion started by: Girish19
1 Replies
LEARN ABOUT HPUX
set_directory_epoch
set directory to new epoch(1m) set directory to new epoch(1m)
NAME
set directory to new epoch - Reconstructs a directory's replica set, allowing you to designate a new master replica or to exclude a replica
SYNOPSIS
cdscp set directory directory-name to new epoch master clearinghouse-name [readonly clearinghouse-name...] [exclude clearinghouse-name...]
ARGUMENTS
The full name of the directory. The full name of the clearinghouse in which an individual replica is located. The first clearinghouse-
name specifies where the master replica is stored.
DESCRIPTION
The set directory to new epoch command reconstructs a directory's replica set, allowing you to designate a new master replica or to exclude
a replica. You must list each existing replica and indicate whether an existing replica needs to be included in or excluded from the new
replica set. You can include or exclude more than one replica. The ellipses (...) indicates that you can specify multiple clearinghouse
names, separated by spaces.
When you set a new epoch on a directory, you must disable the clearinghouse containing the replica that is being excluded. To do this, use
the disable server command (if the server has more than one clearinghouse, all its clearinghouses will be disabled). Note that all clear-
inghouses that are not excluded must be enabled and available before you issue the disable server command.
Privilege Required
You must have administer permission to the directory, and the server principal needs administer, read, and write permission to the direc-
tory. When designating a new master replica, you also need write permission to the clearinghouse that stores the new master replica, and
the server principal needs write permission to each clearinghouse where the replica type is changed to read-only.
NOTE
This command may be replaced in future releases by the dcecp command, and may no longer be supported at that time.
EXAMPLE
The following command sets a new epoch for the directory /.:/mfg. The master replica is in the clearinghouse /.:/Paris1_CH, and read-only
replicas are in the clearinghouses /.:/Chicago1_CH, /.:/Seattle_CH, and /.:/NY1_CH. The new replica set excludes the replica in the clear-
inghouse /.:/NY1_CH. cdscp> set directory /.:/mfg to new epoch master /.:/Paris1_CH > readonly /.:/Chicago1_CH /.:/Seattle_CH exclude
/.:/NY1_CH
RELATED INFORMATION
Commands: set directory to skulk(1m), show directory(1m), show replica(1m)
set directory to new epoch(1m)