08-19-2011
can you set the no-password ssh between two servers?
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
For vertitas netbackup 6.0
I have media server :Solaris
Client server: Windows
I want to restart the netbackup service on the media server .
plz suggest ASAP. (1 Reply)
Discussion started by: saurabh84g
1 Replies
2. Shell Programming and Scripting
Hello, I am trying to write a script which will monitor few processes(winbind) for cpu utilization, If the process consumes more than say 99% cpu for 3 minutes, I want to run a script to restart the service which forks the process.
---------- Post updated at 11:21 AM ---------- Previous update... (5 Replies)
Discussion started by: linuxaddict7
5 Replies
3. Solaris
Can any one please tell me the command for NFS client service restart.This is to resolve, NFS mount slowness issue.Mount is very slow for both read and write operations.The below commands are not helping out in this situation.
---------- Post updated at 08:59 AM ---------- Previous update was... (1 Reply)
Discussion started by: ksvaisakh
1 Replies
4. HP-UX
Hi All,
May i please know if it is possible to write a script to check the log messages and automatically restart a service if it is failed or it is stopped.
Appreciate your suggestions.
Thanks in advance.
regards,
Eajaz (2 Replies)
Discussion started by: ajazshariff
2 Replies
5. Shell Programming and Scripting
Hi All,
Requirement : I need to check for some services in my environment and restart the service if its not running.
I have written script to check the script if its running or not. While if its not running i need to restart it using ./start command. But it will ask for password prompt and i... (4 Replies)
Discussion started by: pradeepbaliga
4 Replies
6. Shell Programming and Scripting
Hello,
Currently i am handling admin activity of wasserver, its parts of teamcenter,
wasserver is used to maintain IDSM service which is involved in data transfer activity. due to some reason IDSM service gets down and have to restart this service manually. ... (0 Replies)
Discussion started by: chetan0412
0 Replies
7. SuSE
Hi,
Beside using crontab, what is other application we can set it? Normally I check using command crontab -l.
Any other path I need to check? Please guide me.
Thanks. (2 Replies)
Discussion started by: mzainal
2 Replies
8. Red Hat
Hello,
I'l like to create a script that restart a service (/etc/init.d/httpd restart) and also check if after restart the service is actually running. Sometimes it happen that at the first try the service fails to restart.
Thanks (2 Replies)
Discussion started by: bazzola
2 Replies
9. Red Hat
Hello
How do I restart init.d ?? (centos 6.5)
Thanks (2 Replies)
Discussion started by: mnnn
2 Replies
10. Red Hat
When I update the server with new SSL certificates, and restart httpd, I get errors :
# service httpd restart
Stopping httpd:
rm: cannot remove `/usr/local/apache2/bin/httpd/logs/httpd.pid': Not a directory
Starting httpd: ... (0 Replies)
Discussion started by: anaigini45
0 Replies
LEARN ABOUT PHP
mongocursor.slaveokay
MONGOCURSOR.SLAVEOKAY(3) 1 MONGOCURSOR.SLAVEOKAY(3)
MongoCursor::slaveOkay - Sets whether this query can be done on a secondary [deprecated]
SYNOPSIS
public MongoCursor MongoCursor::slaveOkay ([bool $okay = true])
DESCRIPTION
Warning
This method is deprecated since version 1.5.0. Instead, please use MongoCursor::setReadPreference and "Read Preferences".
Calling this will make the driver route reads to secondaries if:
o You are using a replica set, and
o You created a MongoClient instance using the option
"replicaSet" => "setName", and
o There is a healthy secondary that can be reached by the driver.
You can check which server was used for this query by calling MongoCursor.info(3) after running the query. It's server field will show
which server the query was sent to.
Note that you should use this function even if you do not use the automatic routing to secondaries. If you connect directly to a secondary
in a replica set, you still need to call this function, which basically tells the database that you are aware that you might be getting
older data and you're okay with that. If you do not call this, you'll get "not master" errors when you try to query.
This method will override the static class variable $MongoCursor::$slaveOkay. It will also override Mongo.setSlaveOkay(3), MongoDB.set-
SlaveOkay(3) and MongoCollection.setSlaveOkay(3).
PARAMETERS
o $okay
- If it is okay to query the secondary.
RETURN VALUES
Returns this cursor.
ERRORS
/EXCEPTIONS
Throws MongoCursorException if this cursor has started iterating.
EXAMPLES
Example #1
MongoCursor.slaveOkay(3) example
<?php
MongoCursor::$slaveOkay = false;
// cannot query secondary
$cursor = $collection->find();
// can query secondary
$cursor = $collection->find()->slaveOkay();
MongoCursor::$slaveOkay = true;
// can query secondary
$cursor = $collection->find();
// cannot query secondary
$cursor = $collection->find()->slaveOkay(false);
?>
SEE ALSO"Read Preferences ,
MongoCursor::setReadPreference, MongoCursor::getReadPreference.
CHANGELOG
+--------+---------------------------------------------------+
|Version | |
| | |
| | Description |
| | |
+--------+---------------------------------------------------+
| 1.5.0 | |
| | |
| | This method has been deprecated in favour of |
| | MongoCursor::setReadPreference and "Read Prefer- |
| | ences". |
| | |
+--------+---------------------------------------------------+
PHP Documentation Group MONGOCURSOR.SLAVEOKAY(3)