Sponsored Content
Top Forums Shell Programming and Scripting Search for a particular file in the server Post 302266100 by methyl on Tuesday 9th of December 2008 12:12:12 PM
Old 12-09-2008
In unix but not Windows a fullstop can mean any character or characters. It needs to be escaped with a preceding back solidus. Also you want asterisk expanded by find and not by shell.
If directories are linked at root level you will need "//" rather than "/".

find // -name abc\.lvc\.\* -print
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

use ind command to search files on differnet server

Hi, I am writing script to search the directories on different server. I have 3 servers. eg. ser1, ser2, ser2 find <absolute_path>-type d -user <user_name> -ctime +5 -exec ls -ltd {} \; can someone please suggest me some way how can i use find command for this. i have ssh connectivity... (1 Reply)
Discussion started by: vikash_k
1 Replies

2. Shell Programming and Scripting

sed help - search/copy from one file and search/paste to another

I am a newbie and would like some help with the following - Trying to search fileA for a string similar to - AS11000022010 30.4 31.7 43.7 53.8 60.5 71.1 75.2 74.7 66.9 56.6 42.7 32.5 53.3 I then want to replace that string with a string from fileB - ... (5 Replies)
Discussion started by: ncwxpanther
5 Replies

3. Shell Programming and Scripting

Perl - use search keywords from array and search a file and print 3rd field when matched

Hi , I have been trying to write a perl script to do this job. But i am not able to achieve the desired result. Below is my code. my $current_value=12345; my @users=("bob","ben","tom","harry"); open DBLIST,"<","/var/tmp/DBinfo"; my @input = <DBLIST>; foreach (@users) { my... (11 Replies)
Discussion started by: chidori
11 Replies

4. Shell Programming and Scripting

Search string within a file and list common words from the line having the search string

Hi, Need your help for this scripting issue I have. I am not really good at this, so seeking your help. I have a file looking similar to this: Hello, i am human and name=ABCD. How are you? Hello, i am human and name=PQRS. I am good. Hello, i am human and name=ABCD. Good bye. Hello, i... (12 Replies)
Discussion started by: royzlife
12 Replies

5. UNIX for Dummies Questions & Answers

Transfer file from server B to server C and running the script on server A

I have 3 servers A, B, C and server B is having some files in /u01/soa/ directory, these files i want to copy to server C, and i want to run the script from server A. Script(Server A) --> Files at Server B (Source server) --> Copy the files to Server C(Target Server). We dont have RSA key... (4 Replies)
Discussion started by: kiran_j
4 Replies

6. Shell Programming and Scripting

Nested search in a file and replace the inner search

Hi Team, I am new to unix, please help me in this. I have a file named properties. The content of the file is : ##Mobile props east.url=https://qa.east.corp.com/prop/end west.url=https://qa.west.corp.com/prop/end south.url=https://qa.south.corp.com/prop/end... (2 Replies)
Discussion started by: tolearn
2 Replies

7. Shell Programming and Scripting

Retrieving the relevant search from search file in the main file

I have two files: file 1: hello.com neo.com,japan.com,example.com news.net xyz.com, telecom.net, highlands.net, software.com example2.com earth.net, abc.gov.uk file 2: neo.com example.com abc.gov.uk file 2 are the search keys to search in file 1 if any of the search... (7 Replies)
Discussion started by: csim_mohan
7 Replies

8. UNIX for Dummies Questions & Answers

Search file and print everything except multiple search terms

I'm trying to find a way to search a range of similar words in a file. I tried using sed but can't get it right:sed 's/\(ca01\)*//'It only removes "ca01" but leaves the rest of the word. I still want the rest of the information on the lines just not these specific words listed below. Any... (3 Replies)
Discussion started by: seekryts15
3 Replies

9. Shell Programming and Scripting

Read in search strings from text file, search for string in second text file and output to CSV

Hi guys, I have a text file named file1.txt that is formatted like this: 001 , ID , 20000 002 , Name , Brandon 003 , Phone_Number , 616-234-1999 004 , SSNumber , 234-23-234 005 , Model , Toyota 007 , Engine ,V8 008 , GPS , OFF and I have file2.txt formatted like this: ... (2 Replies)
Discussion started by: An0mander
2 Replies

10. Shell Programming and Scripting

How to search the multiple strings in app server.log?

Hi Team, Could you please suggest the below requirement. using the below server log, i just want only the order_id with combination of customer name , error code value as 5000111 & amount value using the shell script i tired using the command grep "error_code>50001111"... (6 Replies)
Discussion started by: venkat918
6 Replies
BACKUP_ADDVOLENTRY(8)					       AFS Command Reference					     BACKUP_ADDVOLENTRY(8)

NAME
backup_addvolentry - Defines a volume entry in a volume set SYNOPSIS
backup addvolentry -name <volume set name> -server <machine name> -partition <partition name> -volumes <volume name (regular expression)> [-localauth] [-cell <cell name>] [-help] backup addvole -n <volume set name> -s <machine name> -p <partition name> -v <volume name (regular expression)> [-l] [-c <cell name>] [-h] DESCRIPTION
The backup addvolentry command adds a volume entry definition to the existing volume set named by the -name argument. A volume entry definition can match one or more volumes, depending on the combination of the -server, -partition, and -volumes arguments. For the -server and -partition arguments, provide either o The name of one machine or partition. o The metacharacter expression .* (period and asterisk), which matches every machine name or partition name in the Volume Location Database (VLDB). For the -volumes argument, specify a combination of alphanumeric characters and one or more metacharacters to wildcard part or all of the volume name. OPTIONS lists the acceptable metacharacters. CAUTIONS
It is best to issue this command in interactive mode. If issuing it at the shell prompt, enclose any strings containing metacharacters in double quotes, or escape the metacharacters with other delimiters, to prevent the shell from interpreting them. Adding volume entries to a temporary volume set is possible only within the interactive session in which the volume set was created. OPTIONS
-name <volume set name> Names the volume set to which to add this volume entry definition. The volume set must already exist (use the backup addvolset command to create it). -server <machine name> Defines the set of one or more file server machines that house the volumes in the volume entry. Provide either one fully-qualified hostname (such as "fs1.abc.com") or the metacharacter expression ".*" (period and asterisk), which matches all machine names in the VLDB. -partition <partition name> Defines the set of one or more partitions that house the volumes in the volume entry. Provide either one complete partition name (such as "/vicepa") or the metacharacter expression ".*" (period and asterisk), which matches all partition names. -volumes <volume name> Defines the set of one or more volumes included in the volume entry. Specify the volumes by name, by using any combination of regular alphanumeric characters and one or more of the following metacharacter expressions: . The period matches any single character. * The asterisk matches zero or more instances of the preceding character. Combine it with any other alphanumeric character or metacharacter. [ ] Square brackets around a list of characters match a single instance of any of the characters, but no other characters; for example, "[abc]" matches a single "a" or "b" or "c", but not "d" or "A". This expression can be combined with the asterisk. ^ The caret, when used as the first character in a square-bracketed set, designates a match with any single character except the characters that follow it; for example, "[^a]" matches any single character except lowercase "a". This expression can be combined with the asterisk. A backslash preceding any of the metacharacters in this list makes it match its literal value only. For example, the expression "." (backslash and period) matches a single period, "*" a single asterisk, and "\" a single backslash. Such expressions can be combined with the asterisk (for example, ".*" matches any number of periods). Perhaps the most common metacharacter expression is the period followed by an asterisk (".*"). This expression matches any string of any length, because the period matches any character and the asterisk means any number of that character. As mentioned, it is the only acceptable metacharacter expression for the -server and -partition arguments. In a volume definition it can stand alone (in which case it matches every volume listed in the VLDB), or can combine with regular characters. The following example matches any volume name that begins with the string "user" and ends with "backup": user.*backup -localauth Constructs a server ticket using a key from the local /etc/openafs/server/KeyFile file. The backup command interpreter presents it to the Backup Server, Volume Server and VL Server during mutual authentication. Do not combine this flag with the -cell argument. For more details, see backup(8). -cell <cell name> Names the cell in which to run the command. Do not combine this argument with the -localauth flag. For more details, see backup(8). -help Prints the online help for this command. All other valid options are ignored. EXAMPLES
The following command adds a volume entry to the volume set called "sys". The entry matches all volumes on any machine or partition whose names begin with the string "sun4x_56" followed by a period: backup> addvolentry sys .* .* sun4x_56..* The following command adds a volume entry to the volume set called "fs2", to match all volumes on the /vicepb partition of file server machine "fs2.abc.com". Because it is issued at the shell prompt, double quotes surround the metacharacters in the -volumes argument. (The command is shown here on two lines only for legibility reasons.) % backup addvolentry -name fs2 -server fs2.abc.com -partition /vicepb -volumes ".*" The chapter in the OpenAFS Administration Guide about configuring the AFS Backup System presents additional examples as well as advice on grouping volumes. PRIVILEGE REQUIRED
The issuer must be listed in the /etc/openafs/server/UserList file on every machine where the Backup Server is running, or must be logged onto a server machine as the local superuser "root" if the -localauth flag is included. SEE ALSO
backup(8), backup_addvolset(8), backup_delvolentry(8), backup_delvolset(8), backup_listvolsets(8) COPYRIGHT
IBM Corporation 2000. <http://www.ibm.com/> All Rights Reserved. This documentation is covered by the IBM Public License Version 1.0. It was converted from HTML to POD by software written by Chas Williams and Russ Allbery, based on work by Alf Wachsmann and Elizabeth Cassell. OpenAFS 2012-03-26 BACKUP_ADDVOLENTRY(8)
All times are GMT -4. The time now is 09:33 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy