---------- Post updated at 12:13 PM ---------- Previous update was at 08:27 AM ----------
... and let the bleeding commence.
It's been a while and I'm sure this is over complicated:
Code:
#!/bin/ksh
if [ $# -lt 3 ]; then
print "usage: $0 <group> <userID> <serverfile>"
exit 1
fi
NEWGROUP=$1
NEWUSER=$2
SERVERFILE=$3
for SERVER in `cat ${SERVERFILE}`
do
if [ -n "`ping -c1 ${SERVER} 2>/dev/null | grep icmp_seq`" ]; then
ISGROUP=`ssh ${SERVER} grep ${NEWGROUP} /etc/group`
if [ ! -z "${ISGROUP}" ]; then
ISUSER=`ssh ${SERVER} grep ${NEWUSER} /etc/passwd`
if [ ! -z "${ISUSER}" ]; then
ssh ${SERVER} usermod -g ${NEWGROUP} ${NEWUSER}
else
print "${NEWUSER} does not exist on ${SERVER}"
fi
else
print "${NEWGROUP} does not exist on ${SERVER}"
fi
else
print "${SERVER} is not reachable"
fi
done
Hi all, working on script to create a user acct on all our servers.
for i in `cat $host_file`; do
ssh $i /usr/bin/sudo /usr/bin/mkuser id='bpadm' gecos='NetBackup Admin' 2>&1 >> $log
done
error i get is: 3004-692 Error changing "id" to "bpadm" : Value is invalid.
I have tried this in... (1 Reply)
does a command exist to add users to more than one group?
i think the usermod command can do this but i'm not really sure. past ways of me doing this has always been to just hack the /etc/group file and put the user in whatever group i need him to be in. however, vi..ing files like /etc/groups... (2 Replies)
Hi,
Can any one tell me is it possible to setup private key public key pairing(SSH ) for a group of users , instead of setting it up for individual users ?
Eg:
Say i have 3 users A,B and C and i want the users to connect to SERVER1. instead of generating public private keys for each user , is... (3 Replies)
Hi All,
Okay, I need help.
I need to ssh in to multiple linux servers execute certain commands and get them to email and print on the screen when the script is being executed.
So below is my script. Its not working :-(.
#!/bin/bash
#linux/UNIX box with ssh key based login... (7 Replies)
Requirement:
Run a shell script with below inputs
file name
checksum
path
the script should go to multiple servers (around 35) and verify the input cksum and if there is a mismatch display a simple message to the user that cksum verification failed.
host details, user id /... (1 Reply)
Hello,
I have access to several linux servers (mostly centos based) located in a DC in another country.
from day to day I need to login to each of them to do some work (they dont have gui/window manager installed, I work only from console), or even to just do a check like df -h for disc usage.... (3 Replies)
Hi Y'all,
I need help adding 30 users to 50 servers.
Is there a way to automate this?
I'm using this command:
sudo mkuser pgrp=srvadm gecos=Spears, Brittney auditclasses=ALL sugroups=system,security user01
But I'm doing it per user, per server...HOW CAN I MAKE THIS EASIER?... (7 Replies)
Hi Team,
Hope you are doing good.I am new to scripting.I have a requirement of deleting around 10 users in 100 servers.It is very time consuming by logging into each servers and delete the user.Here I have redhat 6 ,Suse linux 10&11 environment servers.
In one set of servers I have... (5 Replies)
Hi
I have an ssh 'for' loop script to login and put a key on multiple servers. I need to append a file on each server but the command which works ok from the prompt does not work via the script. I have
cat filename | ssh user@servername "cat >>append.file.name"
I have tried to 'spawn' this in... (0 Replies)
Hi folks.
I'm pretty new to unix, while I'm learning a lot I'm finding bash scripting quite confusing. Im sure it's not really, my head just hasn't clicked with it.
Anyway, I need a script to loop the ip addresses stored in a file and run a "pgrep <process>" and return the pid or some... (2 Replies)
Discussion started by: MuntyScrunt
2 Replies
LEARN ABOUT DEBIAN
quake-server
QUAKE-SERVER(6) Games Manual QUAKE-SERVER(6)NAME
quake-server - dedicated server for Quake
SYNOPSIS
quake-server [WRAPPER-OPTIONS] [ENGINE-OPTIONS] [ENGINE-COMMANDS]...
DESCRIPTION
This manual page documents briefly the quake-server command.
Quake is a popular first-person shooter game that appeared in 1996, released by iD Software. This wrapper script will launch the Quake
dedicated server.
The game data needs to be installed independently using the 'game-data-packager' program, and by default it will be looked for at
/usr/share/games/quake.
This wrapper script accepts the two common GNU-style options to get information on the program. Any further arguments are passed to the
engine unmodified. Consult the engine documentation for full details, but most engines support a syntax whereby engine switches are pre-
fixed with a minus sign, and you can give console commands by prefixing with a plus sign. See the examples section for some common cases.
OPTIONS
These options are accepted for WRAPPER-OPTIONS in the synopsis.
-h, --help
Show summary of options.
-v, --version
Show version of program.
SEE ALSO quake(6), quakespasm(6), game-data-packager(6).
AUTHOR
This manual page, and the Quake wrapper script, were written by David Banks and Simon McVittie for the Debian project (and may be used by
others).
2011-06-22 QUAKE-SERVER(6)