I have a variable which is not being populated with the contents of a text file, and I'm wondering if anyone happens to know how to do this for a sh type script?
#!/bin/sh
set alertperson = cat /export/home/bdodym/alert.person
if
then
cat /export/home/bdodym/callout6.msg |... (6 Replies)
Hi,
I need to place a number located in a text file in a variable so I can perform if/then comparison. How would I go about doing this? Using A=awk '{print $2}' maintenance_date.tmp does not seem to work.
Thanks (1 Reply)
Hi Gurus,
I am new to unix.I have a requirement as below
I have text file like a.txt which contains
a.txt
hi hello
process update
status
Ok to Proceed no issues good
data arrangement
My requirement here is i need to read the file and check for the words
"OK to Proceed" and if... (2 Replies)
Hi
I have a text file (mytext.txt), the content of which is as following:
My name is <@MY_NAME@> and my age is <@MY_AGE@> .
Now i have another property file (myprops) which is as following:
MY_NAME=abcdefgh
MY_AGE=000000
I was wondering, how can i replace the tags of mytext.txt, with its... (1 Reply)
I have a txt file
output.txt
Freq = 1900
L = 159I want to assign the values to a variable so that i can further use it in some other script.
like
F=1900
Len=159
etc
i tried doing something with awk but dosent work
F=$(awk 'BEGIN {}/Freq/ {split ($2,a);depth=a};printf "%d\t,... (2 Replies)
Hi,
I'm making a script that automaticaly set file size and path in xml file.
I tried with :
sed -i 's/BOOTPATH/TEST/g' file.xml
it works fine
but if I use a viriable :
sed -i 's/BOOTPATH/$bootpathf/g' file.xml
with this one, no change are made.
I don't understand why. If a make a ... (13 Replies)
Hi Guys,
I have one text file ABC.txt...It have 3 lines
List=/home/klk/dir/ABC.txt
Leajnk123
KJUHIO1234
IJOKIJ7676
I want use as different variable of each line.Just like
X=firstline
Y=Secound Line
Z=Third Line (4 Replies)
i have a text file consists of different file names like:
line 1: lib/libIMb.so message broker file
line 2: lil/imbdfg.lil message broker file
i need to extract libIMb.so and imbdfg.lil files from those lines and save them in a variable. so that i can search for... (9 Replies)
Hey guys,
I need to write a script that will add a specific text at the end of a specific line (of a text file). but the line is a variable
this is my text file :
device_2 ansible_ssh_host=127.0.0.1 ansible_ssh_port=30000 ansible_ssh_user='root'
device_2 ansible_ssh_host=127.0.0.1... (1 Reply)
I have a text file that has many lines, and for each line I need to extract different sections of text, then write several variables from the data.
I can split out the various sections by selecting their position on each line as the column sizes will never vary.
A sample of my text file is below... (2 Replies)
Discussion started by: kcpoole
2 Replies
LEARN ABOUT OPENSOLARIS
in.lpd
in.lpd(1M) System Administration Commands in.lpd(1M)NAME
in.lpd - BSD print protocol adaptor
SYNOPSIS
/usr/lib/print/in.lpd
DESCRIPTION
in.lpd implements the network listening service for the BSD print protocol specified in RFC 1179. The BSD print protocol provides a remote
interface for systems to interact with a local spooling system. The protocol defines five standard requests from the client to the server:
starting queue processing, transferring print jobs, retrieving terse status, retrieving verbose status, and canceling print jobs.
The in.lpd service is managed by the service management facility, smf(5), under the service identifier:
svc:/network/lp
Administrative actions on this service, such as enabling, disabling, or requesting restart, can be performed using svcadm(1M). Responsibil-
ity for initiating and restarting this service is delegated to inetd(1M). Use inetadm(1M) to make configuration changes and to view config-
uration information for this service. The service's status can be queried using the svcs(1) command.
in.lpd uses the config/log_from_remote property to allow or disallow remote access. The default value of this property, localhost, disal-
lows remote access.
inetd waits for connections on TCP port 515. Upon receipt of a connect request, in.lpd is started to service the connection. Once the
request has been filled, in.lpd closes the connection and exits.
EXAMPLES
Example 1 Allowing Remote Access
The following command allows remote access to in.lpd.
# inetadm -m svc:/application/print/rfc1179:default bind_addr=""
EXIT STATUS
The following exit values are returned:
0 Successful completion.
non-zero An error occurred.
FILES
/etc/printers.conf
System printer configuration database.
printers.conf.byname
NIS version of /etc/printers.conf.
printers.org_dir
NIS+ version of /etc/printers.conf.
/usr/lib/print/bsd-adaptor/bsd_*.so*
Spooler translation modules.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWpcu |
+-----------------------------+-----------------------------+
SEE ALSO svcs(1), inetadm(1M), inetd(1M), svcadm(1M), printers.conf(4), attributes(5), smf(5)SunOS 5.11 1 Aug 2006 in.lpd(1M)