Sedang Disiapkan

Script to delete a specific line within a group of files

I need a very simple and quick Script (it could be a bash Script), to run under a Centos Linux Server, to do exactly:

1) It would read a text file, with the names of a series of Domains names, one per line, this way:

aambrosio

aanoseguros

abcmack

abrasivacorretoradeseguros

abscorretor

...

...

and so on.

2) For each of these Domains the Script would search a file in a path always like this:

/home/domainname/www/tabelas_de_saude/[url removed, login to view]

So, as in the example above, the files to be found would be:

/home/aambrosio/www/tabelas_de_saude/[url removed, login to view]

/home/aanoseguros/www/tabelas_de_saude/[url removed, login to view]

/home/abcmack/www/tabelas_de_saude/[url removed, login to view]

/home/abrasivacorretoradeseguros/www/tabelas_de_saude/[url removed, login to view]

/home/abscorretor/www/tabelas_de_saude/[url removed, login to view]

...

...

and so son.

3) When finding such a file, the Script would look for a line within, where it would find a string saying:

This line must be deleted from each of those files.

OBS: when rewriting those files, if possible, not to change their original ownership.

That's all.

Kemahiran: Skrip Kekerang

Lihat lebih lanjut: in this line, find on-line, shell bash, in linux shell script, example shell script, bash file, above the line, OBS, linux bash script, bash script, delete file shell script, linux server files, read file specific line, linux read text file, linux bash shell, script search domains, series script, deleted domains, bash search, search specific file, deleted files centos, linux simple shell, delete files disk specific date, deleted file centos, centos bash script

Tentang Majikan:
( 39 ulasan ) Brazil

ID Projek: #4118220

Dianugerahkan kepada:

kaloyan13

Bash coder and Linux(Fedora) user/admin.

$30 USD dalam sehari
(5 Ulasan)
2.5

8 pekerja bebas membida secara purata $36 untuk pekerjaan ini

k1ng440

Full time freelance web developer with over 8 years of commercial experience.

$50 USD dalam 2 hari
(2 Ulasan)
3.0
sumitgarg44

Can do this

$50 USD dalam 0 hari
(5 Ulasan)
2.3
NanoTitanium

Dear Sir, I have 3 years experiences in writing Linux Script (bash) to manage servers (CentOS/RHEL, SuSE). I can provide you the script right away with high quality. Thanks.

$30 USD dalam sehari
(0 Ulasan)
0.0
prashantsax3na

Very easy. Tell me when to start!

$30 USD dalam sehari
(0 Ulasan)
0.0
Nimesh01

hi please contact me..

$30 USD dalam 2 hari
(0 Ulasan)
0.0
noeand

Hi, Linux Admin with experience in scripting various tasks - from the simplest one to complex automation systems. Please check your message box for more information on my experience.

$40 USD dalam 0 hari
(0 Ulasan)
0.0
ashalalfah

Very Familiar with shell scripting.

$30 USD dalam sehari
(0 Ulasan)
0.0