I'm trying to figure out how to build a small shell script that will find old .shtml files in every /tgp/ directory on the server and delete them if they are older than 10 days...
The structure of the paths are like this:
/home/domains/www.domain2.com/tgp/
/home/domains/www.domain3.com/tgp/... (1 Reply)
The following command works fine in my cshell script:
set Deliverables = `find . -name "eliverables" -print`
The following command does not work:
set LASFiles = `find . -name "*." -print`
In the first example, when tested in an if statement, the script will continue whether a... (3 Replies)
Hi,
Under my parent diectory I have directory named "Response" in many of its subfolders. I am interested to see all files with extention .pro in Response Directory. I am giving following command -
find . -name "Response" -type d | xargs -i ls -lrt {}/*.pro
but it is not giving result.
... (3 Replies)
Hi
I am having a csv file in which lots of data are available wherein i need to find a particular kind of data and replace it with null value.
here is the sample data..
I need to find the string starting with 404-064- and up to the first space i have to remove the data and keep the... (4 Replies)
I want to look if there is any file inside a specific directory which was modified before 2 days.
I wrote the find command, but the problem is there is one directory and that is a random directory generated by unix, so not sure on how to code for that on the find command.
find... (5 Replies)
Hi All,
My server is AIX and i am trying to search for a file in a specific path in directory.
The file name can be of two types:
Position_20131114.csv
Position123333_20131114.csv
I am trying to assign a SOURCEFILE variable as mentioned below:, but i am unable to find/locate the files... (2 Replies)
Hi
I am unable to find files, those are present anywhere in the same directory tree, based on the creation date. I need to find the files with their path, as I need to create them in another location and move them. I need some help with a script that may do the job.
Please help (2 Replies)
HI there,
I am trying to find and replace with wildcard with
data
chr1 69511 69511 A G 1/1:0,34:791,78,0:78:34 0/1:55,60:1130,0,1513:99:116 1/1:0,28:630,63,0:63:28 0/1:0,34:626,57,0:57:34
To this
chr1 69511 69511 A G homo hetero homo hetero
Where I find and replace 0/1 with... (3 Replies)
Hi,
This has been pestering me for quite a while, any help will be highly appreciated
The current directory has a file with below name
npidata_20050523-20171210.csv
The below wildcard matched the above file
ls -ltr npidata_????????-201712??.csv
But when the part '201712' is put... (6 Replies)
I wish to check if my file has a line that does not start with '#' and has
1. Listen and 2. 443
echo "Listen 443" > test.out
grep 'Listen *443' test.out | grep -v '#'
Listen 443
The above worked fine but when the entry changes to the below the grep fails... (2 Replies)
Discussion started by: mohtashims
2 Replies
LEARN ABOUT MOJAVE
inetconv
inetconv(1M) System Administration Commands inetconv(1M)NAME
inetconv - convert inetd.conf entries into smf service manifests, import them into smf repository
SYNOPSIS
inetconv -?
inetconv [-f] [-n] [-i srcfile] [-o destdir]
inetconv -e [-n] [-i srcfile]
DESCRIPTION
The inetconv utility converts a file containing records of inetd.conf(4) into smf(5) service manifests, and then import those manifests
into the smf repository. Once the inetd.conf file has been converted, the only way to change aspects of an inet service is to use the
inetadm(1M) utility.
There is a one-to-one correspondence between a service line in the input file and the manifest generated. By default, the manifests are
named using the following template:
<svcname>-<proto>.xml
The <svcname> token is replaced by the service's name and the <proto> token by the service's protocol. Any slash (/) characters that exist
in the source line for the service name or protocol are replaced with underscores (_).
The service line is recorded as a property of the converted service.
During the conversion process, if a service line is found to be malformed or to be for an internal inetd service, no manifest is generated
and that service line is skipped.
The input file is left untouched by the conversion process.
OPTIONS
The following options are supported:
-?
Display a usage message.
-e
Enable smf services which are listed in the input file.
-f
If a service manifest of the same name as the one to be generated is found in the destination directory, inetconv will overwrite that
manifest if this option is specified. Otherwise, an error message is generated and the conversion of that service is not performed.
-i srcfile
Permits the specification of an alternate input file srcfile. If this option is not specified, then the inetd.conf(4) file is used as
input.
-n
Turns off the auto-import of the manifests generated during the conversion process. Later, if you want to import a generated manifest
into the smf(5) repository, you can do so through the use of the svccfg(1M) utility.
If the -e option is specified, the -n option only displays the smf services that would be enabled.
-o
Permits the specification of an alternate destination directory destdir for the generated manifests. If this option is not specified,
then the manifests are placed in /var/svc/manifest/network/rpc, if the service is a RPC service, or /var/svc/manifest/network other-
wise.
EXAMPLES
Example 1: Generating smf Manifests from inetd.conf
The following command generates smf(5) manifests from inetd.conf(4) and places them in /var/tmp, overwriting any preexisting manifests of
the same name, and then imports them into the smf repository.
# inetconv -f -o /var/tmp
100232/10 -> /var/tmp/100232_10-rpc_udp.xml
Importing 100232_10-rpc_udp.xml ...Done
telnet -> /var/tmp/telnet-tcp6.xml
Importing telnet-tcp6.xml ...Done
Example 2: Generating Manifests from an Alternate Input File
The following command specifies a different input file and does not load the resulting manifests into the smf repository.
# inetconv -n -i /export/test/inet.svcs -o /var/tmp
100232/10 -> /var/tmp/100232_10-rpc_udp.xml
telnet -> /var/tmp/telnet-tcp6.xml
EXIT STATUS
The following exit values are returned:
0
Operation completed successfully (no errors).
1
Invalid options specified.
2
One or more service lines are malformed, and thus no manifest(s) were generated for them.
3
An error occurred importing one or more of the generated manifests.
4
A system error occurred.
FILES
/var/svc/manifest/network/{rpc}/<svcname>-<proto>.xml
default output manifest file name
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWcsu |
+-----------------------------+-----------------------------+
|Interface Stability |Evolving |
+-----------------------------+-----------------------------+
SEE ALSO inetadm(1M), inetd(1M), svccfg(1M), inetd.conf(4), attributes(5), smf(5)SunOS 5.10 21 Oct 2004 inetconv(1M)