Sponsored Content
Top Forums Programming Conditional replace after reading in a file Post 302602777 by Corona688 on Tuesday 28th of February 2012 10:23:23 AM
Old 02-28-2012
which port? port1, port2, or port3?
This User Gave Thanks to Corona688 For This Post:
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

sed conditional string replace for each line

Hi all, I appreciate the enormous amount of knowledge that flows in this forum. I am an average UNIX user. I have many files with lines like the below. I have separated each line with space for ease of reading. I need to replace the first occurance of "/00" with null on those lines that have... (6 Replies)
Discussion started by: Nanu_Manju
6 Replies

2. Shell Programming and Scripting

awk help to do conditional find and replace

Hi, I have a Line input for awk as follows DROP MATERIALIZED VIEW MCR.COMM_STACK; CREATE MATERIALIZED VIEW "MCR"."COMM_STACK" ON PREBUILT TABLE WITHOUT REDUCED PRECISION USING INDEX REFRESH FAST ON DEMAND START WITH sysdate+0 NEXT SYSDATE + 7 WITH PRIMARY KEY USING DEFAULT... (3 Replies)
Discussion started by: rajan_san
3 Replies

3. Shell Programming and Scripting

Replace a column with a value conditional on a value in col1

Hi, Perhaps a rather simple problem...? I have data that looks like this. BPC0013 ANNUL_49610 0 0 1 1 BPC0014 ANNUL_49642 0 0 2 1 BPC0015 ANNUL_49580 0 0 1 1 BPC0016 ANNUL_49596 0 0 2 1 BPC0017 VULGO_49612 0 0 1 1 BPC0018 ANNUL_49628 0 0 1 1 BPC0019 ANNUL_49692 0 0 2 1 170291_HMG... (4 Replies)
Discussion started by: genehunter
4 Replies

4. Shell Programming and Scripting

Search & Replace in Multiple Files by reading a input file

Hi, I have a folder which contains multiple config.xml files and one input file, Please see the below format. Config Files format looks like :- Code: <application name="SAMPLE-ARCHIVE"> <NVPairs name="Global Variables"> <NameValuePair> ... (0 Replies)
Discussion started by: haiksuresh
0 Replies

5. Shell Programming and Scripting

Sed conditional replace

Given this row: |lastname1|middlename1|firstname1|lastname2|middlename2|firstname2 produce this result: |lastname|middlename|firstname where the resultant names are based on the presence of the #2 names above. I.e., if a #2 name is passed (usually will be null,) use that - otherwise... (8 Replies)
Discussion started by: tiggyboo
8 Replies

6. Shell Programming and Scripting

Conditional Search/Replace

I'm looking for an awk or (preferably) sed solution to search a pipe delimited file for any occurrence of an email address that does not include a designed domain, and replace the email address with a blank. E.g. hello|smith@designateddomain.com|jones@anotherdomain.edu|1234| turns into: ... (2 Replies)
Discussion started by: tiggyboo
2 Replies

7. Shell Programming and Scripting

Search & Replace in Multiple Files by reading a input file

I have a environment property file which contains: Input file: value1 = url1 value2 = url2 value3 = url3 and so on. I need to search all *.xml files under directory for value1 and replace it with url1. Same thing I have to do for all values mentioned in input file. I need script in unix bash... (7 Replies)
Discussion started by: Shamkamde
7 Replies

8. Shell Programming and Scripting

sed conditional \n replace for each line

How could be removed \n only if appearing at position 80 in the line? (4 Replies)
Discussion started by: RomanF
4 Replies

9. Emergency UNIX and Linux Support

sed replace file contents by reading from another file

Hello, My input file1 is like this by tab-delimited chr1 mm10_knownGene stop_codon 3216022 3216024 0.000000 - . gene_id "uc007aeu.1"; transcript_id "uc007aeu.1"; chr1 mm10_knownGene CDS 3216025 3216968 0.000000 - 2 gene_id "uc007aeu.1"; transcript_id "uc007aeu.1"; ... (3 Replies)
Discussion started by: jacobs.smith
3 Replies

10. Shell Programming and Scripting

Replace query by reading the file

Hi Guys, I am having below file which holds data like this file.txt name,id,flag apple,1,Y apple,2,N mango,1,Y mango,2,Y I need to read the above file and frame a query like this hive -s -e "create apple_view as select 1 from main_table;" hive -s -e "create mango_view as select... (11 Replies)
Discussion started by: rohit_shinez
11 Replies
gufw(8) 						      System Manager's Manual							   gufw(8)

NAME
Gufw - Graphic user interface for managing ufw DESCRIPTION
Gufw is an easy to use Ubuntu / Linux firewall, powered by ufw. Gufw is an easy, intuitive, way to manage your Ubuntu firewall. It supports common tasks such as allowing or blocking pre-configured, com- mon p2p, or individual ports port(s), and many others! Gufw is powered by ufw. Introduction iptables is already a very powerful tool by itself, but it's syntax can get awkward at times and hard to figure out, so Ubuntu developers decided to make ufw ("The reason ufw was developed is that we wanted to create a server-level firewalling utility that was a little bit more for `human beings`"), which was to be simpler. Now, on the graphical side of things, Firestarer already existed. But why not make an even easier to use GUI for desktop `human beings`, powered by ufw? This is where Gufw comes in. RUN
You can run Gufw in GNOME menu: /System/Administration/Firewall configuration USAGE
BASIC SETTINGS
Gufw has two states: Enabled and disabled. When Gufw is enabled, you can allow/reject/deny all incoming and outgoing connections. ADD PRECONFIGURED RULE(S) You can select between more Programs and Services preconfigured. Once Program/Service can have multiples rules. ADD SIMPLE RULE(S) You can specify the port or service, and protocol to be allowed (allow traffic), reject (reject traffic without reply), denied (deny traf- fic with reply), limit (limit traffic) on the host, or limit an IP or Port (Protecting against brute-force login attacks). The port can be a number of 5 digits, from 1 to 65535. The service can be any of /etc/services file (By example tcpmux, echo, discard, systat...). The protocol can be: 1. TCP: Apply rule for all traffic in protocol TCP. 2. UDP: Apply rule for all traffic in protocol UDP. 3. both: Apply rule for all traffic in protocol TCP and UDP. ADD ADVANCED RULE(S) You can add an advanced rule. You can specify: 1. Protocol: TCP, UDP or both. 2. From IP Addres: You can allow/deny/reject/limit traffic from IP address. Example for a range: 192.168.1.0/9 3. From Port: You can allow/deny/reject/limit traffic from a port. This parameter is optional. The port can be a number of 5 digits, from 1 to 65535. You can use a range ports with this format port1:port2 (by example 3234:3237), or add multiple ports with port1,port2 (by example 3234,3254). 4. To IP Addres: You can allow/deny/limit traffic to an IP address. This parameter is optional. Example for a range: 192.168.1.0/9 5. To Port: You can allow/deny/reject/limit traffic to a Port. This parameter is optional. The port can be a number of 5 digits, from 1 to 65535. You can use a range ports with this format port1:port2 (by example 3234:3237). GENERAL TO PRECONFIGURED
/ SIMPLE / ADVANCED With the extended parameters you can: 1. Insert a rule in a specific row. 2. Set the log level for ufw. REMOVE ONE RULE
Steps: 1. Select a rule in the list. 2. Click in Remove button. You can delete more rules if you select it. RESET CONFIGURATION
You will remove all rules and reset the ufw configuration to intial status (disable)! EDIT PREFERENCES
You can edit your preferences in /Edit/Preferences menu. Preferences: 1. Gufw log: Gufw will register all commands sent to ufw. 2. ufw log: Enable/disable and set the level of the ufw log. 3. Listening Report: Will display the ports on the live system in the listening state for TCP and the open state for UDP. 4. Notification popups: Gufw will notify the new connections in the Listening Report. SEE ALSO
ufw(8) AUTHOR
Gufw is (C) 2008-2011, Marcos Alvarez Costales <https://launchpad.net/~costales>. This manual page was originally written by Marcos Alvarez Costales <https://launchpad.net/~costales>. 13 Feb 2011 gufw(8)
All times are GMT -4. The time now is 05:15 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy