Sponsored Content
Operating Systems Solaris Best practise for keeping cronjobs across 2 servers in sync Post 302985453 by MadeInGermany on Wednesday 9th of November 2016 05:00:56 PM
Old 11-09-2016
You still need to maintain identical crontabs on both servers.
Manual work might be okay.
If you have often changes, and if you have a shared directory say /shared/dir/ then you can go for another entry, for example (every hour)
Code:
1 * * * * ctab=/shared/dir/crontab.txt; if activecommand; then crontab -l >$ctab; elif [ -f $ctab ]; then crontab - <$ctab; fi

Note: most Unix crontab commands read from stdin by default, without the - argument.
This User Gave Thanks to MadeInGermany For This Post:
 

10 More Discussions You Might Find Interesting

1. AIX

Cronjobs

We recently upgrade from AIX 4.3.3 to AIX 5.3, We noticed that some cronjobs that run for our programmers did not fire off this morning. You can crontab -l and -e and see the jobs. Did AIX 5.3 change something? Thanks Mike (1 Reply)
Discussion started by: mcastill66
1 Replies

2. UNIX for Dummies Questions & Answers

Need Unix Terminal for practise on Rental basis ...plz help!

Hey Guys,, Have just got started with Unix , I need UNIX Terminal to practise commands. Does any website host such services ? Happy Holidays... (9 Replies)
Discussion started by: rrover1977
9 Replies

3. Solaris

Sync to Green vs. Separate Sync

Hi all....I have a Sun Ultra2 that I want to use with my PC monitor. I have purchased an adapter that does not work and I was told I need to change my video card setting (if I can) to Separate Sync.....my Monitor product number ends in 1343......I am running SunOS 5.7 ......anyone have any ideas? ... (0 Replies)
Discussion started by: psantinello
0 Replies

4. Red Hat

how to find the red hat servers in time sync

Hi all, Before i'm going to install application on my RHEL servers, I just wanted make sure servers in time sync. How can I find it. Thanks. (1 Reply)
Discussion started by: s_linux
1 Replies

5. Shell Programming and Scripting

sync files from two different servers.

I have a directory called UNIX 1 which contains 2 files and uploaded into two different servers. Now I want to check whether the directory contains both the files. If not, then need to sync the directory. Please let me know how to do that in shell scripting. (2 Replies)
Discussion started by: madan1
2 Replies

6. Shell Programming and Scripting

Is it bad practise to exit in function?

Question is title, I don't understand why all examples I am reading return constants error values instead of just exiting under certain conditions... then back in main script test return value and exit if true, to me seems like a lot of extra typing and test conditions which can make for bulky and... (5 Replies)
Discussion started by: gcampton
5 Replies

7. Web Development

How do you sync tables in mysql between two different servers?

Hi all, I have 2 mysql databases running on two different servers (both can be accessed via ssh to each other). If I have say table ABC on server 1, how can I sync it with table ABC on server 2 if the number of records is different? Both databases are the same structure though server 2 has... (2 Replies)
Discussion started by: muay_tb
2 Replies

8. UNIX for Advanced & Expert Users

How to Sync two servers

Hi All, want to sync. two servers , both are having solaris os. If am updating any thing in one server , it will automatically sync. with the other server . Is it possible , if so den how ? (3 Replies)
Discussion started by: natraj005
3 Replies

9. Solaris

Client does not sync date with ntp servers

We had a network problem a couple of days before that caused 1 interface to down and up. But today I have noticed that our date is wrong, our system have 4 servers and the other 3 are OK. I used <date> command, the result is: Fri Jan 2 17:57:55 ICT 1970 I have tried set date to be the same as... (3 Replies)
Discussion started by: salvation3103
3 Replies

10. What is on Your Mind?

Odd(?) shell script practise

Hello, I often stumble over a common shell coding practise. Example 1: #!/bin/sh # # Licensed Materials - Property of IBM # Rational ClearCase # (C) Copyright IBM Corp. 1999, 2010. All Rights Reserved # US Government Users Restricted Rights - # Use, duplication or disclosure restricted... (4 Replies)
Discussion started by: MadeInGermany
4 Replies
DPMSGetTimeouts(3)						    X FUNCTIONS 						DPMSGetTimeouts(3)

NAME
DPMSGetTimeouts - retrieves the timeout values used by the X server for DPMS timings SYNOPSIS
cc [ flag ... ] file ... -lXext [ library ... ] #include <X11/extensions/dpms.h> Bool DPMSGetTimeouts ( Display *display, CARD16 *standby, CARD16 *suspend, CARD16 *off ); ARGUMENTS
display Specifies the connection to the X server standby Specifies the current standby timeout in seconds suspend Specifies the current suspend timeout in seconds off Specifies the current off timeout in seconds DESCRIPTION
The DPMSGetTimeouts function retrieves the timeout values used by the X server for DPMS timings. The value standby is the amount of time of inactivity in seconds before standby mode is invoked. A value of zero indicates that this mode has been disabled. The value suspend is the amount of time of inactivity in seconds before the second level of power savings is invoked. A value of zero indicates that this mode has been disabled. The value off is the amount of time of inactivity in seconds before the third and final level of power savings is invoked. A value of zero indicates that this mode has been disabled. RETURN VALUES
TRUE The DPMSGetTimeouts function returns TRUE when values are returned. FALSE The DPMSGetTimeouts function returns FALSE when no values returned. SEE ALSO
DPMSCapable(3), DPMSInfo(3), DPMSSetTimeouts(3) X Version 11 libXext 1.3.2 DPMSGetTimeouts(3)
All times are GMT -4. The time now is 02:39 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy