original file:
define host{
use solaris-server
host_name test
alias DevOps Test
address test
hostgroups devops-testing
}
define host{
use solaris-server
host_name test1
alias DevOps Test1
address test
hostgroups devops-testing
}
modified file:
define host{
use solaris-server
host_name test
alias DevOps Test
address test
hostgroups devops-production
}
define host{
use solaris-server
host_name test1
alias DevOps Test1
address test
hostgroups devops-testing
}
I am getting request to change hostgroups or servicegroups of the servers. I do not want to do manually edit file. I am having file contain old hostgroups/servicegroups details with new one and hostaname. just want script or idea, how to proceed with that.
Please let me know if more details require from my side.
Hi,
I'm newbie in UNIX. I would like to ask how to read a file which in Microsoft word format? Inside the doc file is just a few sentences . "It is a text. Help me with it". and I would like to replace the the word of text to message.
I was trying with this
for i in `find . -type f -name... (8 Replies)
File having data in following format :
file name : file.txt
--------------------
111111;name1
222222;name2
333333;name3
I want to read this file so that I can split these into two paramaters i.e. 111111 & name1 into two different variables(say value1 & value2).
i.e val1=11111 &... (2 Replies)
Hi,
I want to replace a word in a file which occurs after a particular word.
For example :
$cat file.txt
CASE
WHEN
AND c1 = 'I'
AND c2= '2'
THEN 1
WHEN
AND c1= 'I'
AND c2= '0'
THEN 2
So in this example i want to replace... (4 Replies)
Hi All,
I have a file in which a number of lines are starting with similar first word but different next words.
I want to replace the any nth word(not 1st or 2nd) with another word.
Eg:- My file contains are like this:-
Ram is a boy.
Ram is a good boy.
Ram plays cricket.
Here I want to... (2 Replies)
Hi
i am having a shell script reading two arguments.
when the shell script is passed with argument containing $ in it, the value from $ onwards is getting truncated and my script is failing.
i have to do in reading the arguments in the shell script only as i am not having control on the... (3 Replies)
Hi Everyone,
I am looking for a simple way for replacing all the files under a directory that use the server "xsgd1234dap" with "xsdr3423pap".
For Example:
In the Directory,
$pwd
/home/nick
$ grep -l "xsgd1234dap" *.sh | wc -l
119
I have "119" files that are still using... (5 Replies)
Hi All,
Hope you guys had a wonderful weekend
I have a scenario where in which I have to read a file line by line
and check for few words before redirecting to a file
I have searched the forum but,either those answers dint work (perhaps because of my wrong under standing of how IFS... (6 Replies)
Hi All,
I have a XML file which is looks like as below. <<please see the attachment >>
<?xml version="1.0" encoding="UTF-8"?>
<esites>
<esite>
<name>XXX.com</name>
<storeId>10001</storeId>
<module>
... (4 Replies)
USERMAPPING(5) File Formats Manual USERMAPPING(5)NAME
usermapping - user mapping entry file format
DESCRIPTION
A usermapping entry is used to define alias names for a cluster user. The user's name known by the scheduling system is known as the clus-
ter user. If the cluster user doesn't match the user account name on an execution host, the usermapping feature can solve the problem.
Each line in the usermapping entry file specifies a user name and the host(s) where he has an account.
A list of currently configured user mapping entries can be displayed via the qconf(1)-sumapl option. The contents of each enlisted user
mapping entry can be shown via the -sumap switch. The output follows the usermapping format description. New user entries can be created
and existing can be modified via the -aumap, -mumap and -dumap options to qconf(1).
FORMAT
A user mapping entry contains two parameters:
cluster_user
The cluster_user keyword defines the cluster user name. The rest of the textline after the keyword "cluster_user" will be taken as cluster
user value.
remote_user
The user name on an execution host. Please note that the value for this attribute might be overwritten for a certain hostgroups or single
host. Find an example below.
EXAMPLE
This is a typical user mapping entry for a cluster user mapping:
cluster_user peter
remote_user peter,[@linux=pet1],[fangorn=peter1]
The entry will map the user peter which is defined in the cluster system to the user peter on all hosts in the cluster except for all hosts
which are referenced in the hostgroup @linux. For all these hosts the user will be mapped to pet1. For the host fangorn the remote user
will be peter1. hostgroup(5) to obtain for more information about that.
SEE ALSO qconf(1), hostgroup(5).
COPYRIGHT
See sge_intro(1) for a full statement of rights and permissions.
$Date$ USERMAPPING(5)