Sponsored Content
Top Forums Shell Programming and Scripting How to trim space in output variable ? Post 74500 by Perderabo on Friday 10th of June 2005 07:58:08 AM
Old 06-10-2005
V_RUNID=`echo $V_RUNID`
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

how to merge two variable in one variable with space between them?

Dear all I had two separate variable. Now i want to make them merge into one new variable with space between them. Kindly suggest me. var1=dec 15 var2=10 i want var3=dec 15 10 My main aim is as below: op of date command: >date >Sat Dec 15 10:17:35 IST 2007 i want only Dec... (2 Replies)
Discussion started by: jaydeep_sadaria
2 Replies

2. Programming

How to trim the white space around a string in C program

I am coding a C program to read a plain text file. There are a lot of blank fields or a string with white spaces. I want to know is there such a function called trim() in C to clean the white space around a string? Or some other way can do this efficiently? Thanks. (18 Replies)
Discussion started by: hxm1303
18 Replies

3. Shell Programming and Scripting

Using Variable With Space In It?

Hey , I'm new to Bash and am having trouble with writing a script. I have a variable and want to use it to create a tar file, but, I am having problems. Can anyone tell me what I'm doing wrong? filestr=`date "+%y-%m-%d %H.%M.%S"`.tar tar -cvf $filestr test.txt So, basically,... (3 Replies)
Discussion started by: beefeater267
3 Replies

4. Shell Programming and Scripting

How to trim variable in linux?

Hi guys , I m developing a script in linux.but getting confused about how would i trim my variable if there is any space. for example. I m storing value in a variable named MACHINE_NAME if MACHINE_NAME=<space><space><space>ABCDF<space><space> How would i trim it to have my MACHINE_NAME=ABCDF... (5 Replies)
Discussion started by: pinga123
5 Replies

5. Shell Programming and Scripting

trim spaces in unix for variable

HI Guys I have written a script using awk to split a file based on some identifier and renaming the file based on two values from specific length. ts a fixed width file. When I am trying to fetch the values a = substr($0,11,10) b = substr($0,21,5); i am getting spaces in a and b values .... (6 Replies)
Discussion started by: manish8484
6 Replies

6. Shell Programming and Scripting

awk - trim white space from a field / variable

Hi, Consider the data (FS = |): 1| England |end 2| New Zealand |end 3|Australia|end 4| Some Made Up Country |end 5| West Indies|end I want the output to be (i.e. without the leading and trailing white space from $2) England New Zealand Australia Some Made Up Country West... (4 Replies)
Discussion started by: Storms
4 Replies

7. Shell Programming and Scripting

Trim sed output & assign to variable

Hi, I have the following command that parses an xml file to read a node <port>'s value. Hoever the output comes with spaces. My requirement is to trim the spaces around the value and assign to a variable. sed -n 's|<port>\(.*\)</port>|\1|p' ../cfg.xml How do I go about it? (6 Replies)
Discussion started by: sai2013
6 Replies

8. UNIX for Advanced & Expert Users

Passing variable as input & storing output in other variable

I have a below syntax its working fine... var12=$(ps -ef | grep apache | awk '{print $2,$4}') Im getting expected output as below: printf "%b\n" "${VAR12}" dell 123 dell 456 dell 457 Now I wrote a while loop.. the output of VAR12 should be passed as input parameters to while loop and results... (5 Replies)
Discussion started by: sam@sam
5 Replies

9. Shell Programming and Scripting

Trim Space

In Shell, I have output of a unix command as test1 test2015 but I want it as test1 test2015 can anyone help me out. Use code tags, thanks. (3 Replies)
Discussion started by: OscarS
3 Replies

10. Shell Programming and Scripting

Gawk --- produce the output in pattern space instead of END space

hi, I'm trying to calculate IP addresses and their respective calls to our apache Server. The standard format of the input is HOST IP DATE/TIME - - "GET/POST reuest" "User Agent" HOST IP DATE/TIME - - "GET/POST reuest" "User Agent" HOST IP DATE/TIME - - "GET/POST reuest" "User Agent" HOST... (2 Replies)
Discussion started by: busyboy
2 Replies
TIGERCRON(8)						      Administrator Commands						      TIGERCRON(8)

NAME
tigercron - Cron utility for Tiger UNIX Security Checker SYNOPSIS
tigercron [controlfile] [-B basedir] [tigeroptions...] DESCRIPTION
Tigercron is used to run periodically checks from the Tiger UNIX Security Checker. Tigercron reads a control file which is usually located in '/etc/tiger/cronrc' although it can also be specificied as the first argument when calling the program. The format of this control file is the same as for the cron program, each line indicates when different checks from Tiger will be run. The user can indicate where Tiger is installed through the -B basedir parameter, any other additional options provided in the command line will be passed on to configure to configure Tiger based on them (as described in tiger (8)). Tigercron runs the specified checks and compares their reports with previous stored reports (under /var/log/tiger). It will then mail the user defined in '/etc/tiger/tigerrc' (Tiger_Mail_RCPT) the results. When a module is run, tigercron checks: o If Tiger_Cron_Template is set to Y in tigerrc. If it is, it checks if there is a template stating which are the expected results. o If Tiger_Cron_CheckPrev is set to Y in tigerrc. If it is, it checks if there is a previous run of the module it can check against. A differential report is generated depending on the module reports and previous run and is sent through e-mail. These reports provide an easy way to detect intrusions even if no configuration of templates has been done. In the event of an intrusion a Tiger check might detect something specific (file changes, new processes, new users, etc.) and this alert mechanism provides a way to turn Tiger into a Host Intru- sion Detection System (HIDS). The ability of it to work as a proper HIDS is based on a good customization of the cronrc file. Modules that check events to which the host is most exposed to should be run often in order to detect deviations from normal behaviour. OPTIONS
Tigercron uses the same options as Tiger. A controlfile can be defined also to override the default. FILES
/etc/tiger/tigerrc Configuration file for the Tiger tool. /etc/tiger/cronrc Configuration file for the Tigercron tool. /var/log/tiger Location of the log messages generated by Tiger when run through cron /var/lib/tiger/work Working directory used by Tiger scripts to create temporary files. SEE ALSO
tigexp(8),tiger(8),cron(8),crontab(5) The deficiencies of using tigercron as a HIDS are described in the file README.hostids which is provided with the package. In Debian GNU/Linux you will find this (and other related) documentation at /usr/share/doc/tiger/ BUGS
Currently Tigercron has only one alert mechanism (mail) and signatures are not supported. Thus, alerts could be faked. Also, it is depen- dant on cron and will not work if cron is not working. AUTHOR
This manpage was written by Javier Fernandez-Sanguino. Security 19 September 2003 TIGERCRON(8)
All times are GMT -4. The time now is 11:19 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy