-
Notifications
You must be signed in to change notification settings - Fork 79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
using cssh to generate multiple terms, each with a diff initial launch cmd #104
Comments
in your configure file you can set up many different commands to open certain server windows. I use mine for patching. I would set it up when I type, cssh prod1 will bring up just the first set of servers in a cluster. I would also set it up with cssh dev, cssh test, cssh stage, or cssh prod. Its all in the configure file. it will error until you have it setup right. |
Hi zabbix112 As far as I can tell the /etc/clusters config file allows you to set up the different user@hosts and you can even group them in as many different ways as you choose. However, I have yet to be able to set up a process where I can pass an action to a user@host within the /etc/clusters file. from the cmd line this works If you can show me a /etc/clusters file that allows you to have something like and run it from the cmdline as so you then see two terms get displayed I'd lie to see it. I can't figure out how to get an action (or separate actions) to work in the /etc/clusters file |
Deehill, So when you installed it did you install it as root and or under the rood dir? if so do ls -la and you will see something .clusterssh file... cd to .clusterssh and then do a ls and Oh also you need to download ximg "its what I use if you have something different" now I say ximg is cause I have to work off a corporate windows laptop and then this allows me to create multiple windows of each server I am working on. let me know if any of this helps. |
hey... Installed as root .. yum install .... in the root dir ~/.csshrc which is consistent with what I've seen from other people Are you telling me you can do something like (even from the cmdline) cssh -a "vi /tmp/cat" [email protected] -a "vi /tmp/dog" [email protected] and you then have 2 windows displayed in the same/single cssh process with one editing the tm/cat file and the other editing the tmp/dog file... If I could get this to work.. that would be great as it would show how to initiate multiple terms with different actions passed in |
now... cssh -a "vi /home/crawl_user/cssh1.php" [email protected] [email protected] works,, as it kicks off two windows each of which edits the same file... but the above isn't the same as this.. cssh -a "vi /home/crawl_user/cssh1.php" [email protected] -a "vi /home/crawl_user/cssh2222.php" [email protected] which edits a different file in each window. (and which doesn't work!) |
What version of ClusterSSH are you using? The |
I think the feature @deehill is after is the equivalent of --hosts in csshX (the MacOSX version) which I need as well. Ref: https://github.com/brockgr/csshx/blob/533b2626b5812cf9e1b7ff69589d6c98f4375d19/csshX#L2893-L2897 |
Trying to figure out how/if cssh can be used to generate multiple terms with different launch actions
/etc/clusters
testcluster7 -a '-t screen -r crawl1Session' [email protected]
cssh testcluster7
Doesn't work as cssh doesn't appear to be able to handle options
cssh -a '-t screen -r crawl1Session' [email protected]
This works, generates a term running the "screen -r crawl1Session cmd..
I could run separate cssh cmds from the local cmdline but the resulting cssh terms don't "tile" as they're unique processes.
Thoughts/Comments??
The text was updated successfully, but these errors were encountered: