Sponsored Content
Full Discussion: add or modify if existent
Top Forums Shell Programming and Scripting add or modify if existent Post 302112338 by melanie_pfefer on Tuesday 27th of March 2007 10:59:55 AM
Old 03-27-2007
thanks. this is modiying but not adding in case the entry does not exist.
can you please advise?
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

how can i add/modify filename after output?

Hi All, I have a script to convert a file and output the filename with "_output", however it not work. Can help? echo Please input list file name: read listn for file in `cat $listn.txt` do convert $file > $file_output Thanks all!! (3 Replies)
Discussion started by: happyv
3 Replies

2. Shell Programming and Scripting

Checking for future / non existent dates

'm attempting to script an application for the bash shell. The application needs to check for birthday, but must check the birthday to see if the date is a) in the future b) exists at all (ie Feb 29th during non-leap years). The input is being entered in a YYYYMMDD format, so I was hoping someone... (2 Replies)
Discussion started by: DKNUCKLES
2 Replies

3. Shell Programming and Scripting

Help with search and delete/add/modify script

Gurus, I need to run a script on multiple XML files in different directories and do the following (the output can be redirected to create a new file) 1. Search a pattern like "abc.mno.xyz" in an XML file, once detected, the script should delete one line above and 3 lines below (including the... (2 Replies)
Discussion started by: inditopgun
2 Replies

4. Shell Programming and Scripting

Creating a directory if its non-existent within a script

Hi, is there a way to create a directory when its non-existent when trying to move files to this particular folder? Thanks much. (7 Replies)
Discussion started by: ida1215
7 Replies

5. Shell Programming and Scripting

Modify a file by another file: add new line and variable after string is found

hello, I have problem with writing/adjusting a shell script. I searched forum and unfortunately couldn't write scipt based on the information I found. I never wtire such so it's hard for me and I do need to modify one script immediately. case looks like: 1. 'file' that needs to be modified... (3 Replies)
Discussion started by: bipbip
3 Replies

6. Shell Programming and Scripting

Create a directory when its non-existent

Hi I need to create a directory when its non-existent Having an issue with the code here because it doesn't work can someone point what and how to change, please. ---------- Post updated at 11:08 AM ---------- Previous update was at 11:07 AM ---------- filelist=project_name/files/... (7 Replies)
Discussion started by: murari83.ds
7 Replies

7. Shell Programming and Scripting

Please modify solution

Hi Please check my code,here awk -vLIT="$line" '$0 ~ LIT { print LIT,"Found in ",FILENAME; }' $f it is not checking for small alphabets.can u pls modify my code #!/bin/ksh for f in /tmp/satemp/* do cat /tmp/sa/tt.txt| while read line do awk -vLIT="$line" '$0 ~ LIT { print LIT,"Found in... (3 Replies)
Discussion started by: coolboy98699
3 Replies

8. Red Hat

Postfix - want to send email to some non-existent user using alias

Hi, I know how to use email redirection using /etc/aliases file + postfix combination and it is working fine for existing users. The question I have is: I want to send an email to tony@server1.example.com while tony user is actually not there. Rather, I want to redirect that email to... (0 Replies)
Discussion started by: freebird8z
0 Replies

9. Shell Programming and Scripting

Shebang of non-existent interpreter not giving error

I read that whenever you provide wrong path at sha-bang it will generate an error with message "command not found", but when I run script with wrong path, it runs perfectly without generating any error. any reason ? #!/home/usrname/etc echo "hello" exit 0 (4 Replies)
Discussion started by: Qazi
4 Replies

10. Shell Programming and Scripting

File modify

Hi All I am getting a file with below pattern - 00150366 05/08/2015 07:14:32 8000186167+++ 50195281000000000371001010903236 800186167+++ 100209000000000 800000018617+++ 50295281000000000371001010900217================================3u4398482344334=432434 00150367 05/08/2015 07:14:32... (7 Replies)
Discussion started by: honey26
7 Replies
add entry(1m)															     add entry(1m)

NAME
add entry - Adds a name service entry to the name service database SYNOPSIS
rpccp add entry entry-name [-s syntax] OPTIONS
Indicates the name syntax of the entry name (optional). The only value for this option is the dce name syntax, which is the default name syntax. Until an alternative name syntax becomes available, specifying the -s option is unnecessary. ARGUMENTS
Specifies the name of the target name service entry. For an entry in the local cell, you can omit the cell name and specify only the cell- relative name. DESCRIPTION
The add entry command adds an unspecialized entry to the name service database. The name of the entry is required. The new entry initially contains no NSI attributes. This command creates a general name service entry for an application or user. The application or user can later use the export, add element, and add member commands to make the generic entry into a server entry, a group, or a profile (or a combination), as follows: For a server entry, specify the new entry as the target entry for the rpccp export command. For a group, specify the new entry as the target group for the rpccp add member command. For a profile, specify the new entry as the tar- get profile for the rpccp add element command. The add entry command enables administrators to add entries for users who lack the required permissions. If you have the permissions required by the add entry command, you can also add an entry using an export, add member, or add element command; if the entry you specify does not exist, the command creates the entry. Privilege Required To add an entry, you need insert permission to the parent directory and both read permission and write permission to the CDS object entry (the target name service entry). NOTE
This command is replaced at Revision 1.1 by the dcecp command and may not be provided in future releases of DCE. EXAMPLES
The following commands start RPCCP and add an unspecialized entry to the name service database: $ rpccp rpccp> add entry > /.:/LandS/anthro/Cal_host_2 The following command operates from the system prompt to add an unspecialized entry to the name service data- base: $ rpccp add entry > /.:/LandS/anthro/Cal_host_3 RELATED INFORMATION
Commands: remove entry(1m), show entry(1m) add entry(1m)
All times are GMT -4. The time now is 01:31 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy