Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

Cisco 300-215 Exam - Topic 1 Question 20 Discussion

A website administrator has an output of an FTP session that runs nightly to download and unzip files to a local staging server. The download includes thousands of files, and the manual process used to find how many files failed to download is time-consuming. The administrator is working on a PowerShell script that will parse a log file and summarize how many files were successfully downloaded versus ones that failed. Which script will read the contents of the file one line at a time and return a collection of objects?
D) Get-Content --Path \\Server\FTPFolder\Logfiles\ftpfiles.log | Select-String ''ERROR'', ''SUCCESS''
A) Get-Content-Folder \\Server\FTPFolder\Logfiles\ftpfiles.log | Show-From ''ERROR'', ''SUCCESS''
B) Get-Content --ifmatch \\Server\FTPFolder\Logfiles\ftpfiles.log | Copy-Marked ''ERROR'', ''SUCCESS''
C) Get-Content --Directory \\Server\FTPFolder\Logfiles\ftpfiles.log | Export-Result ''ERROR'', ''SUCCESS''

Cisco 300-215 Exam - Topic 1 Question 20 Discussion

Actual exam question for Cisco's 300-215 exam
Question #: 20
Topic #: 1
[All 300-215 Questions]

A website administrator has an output of an FTP session that runs nightly to download and unzip files to a local staging server. The download includes thousands of files, and the manual process used to find how many files failed to download is time-consuming. The administrator is working on a PowerShell script that will parse a log file and summarize how many files were successfully downloaded versus ones that failed. Which script will read the contents of the file one line at a time and return a collection of objects?

Show Suggested Answer Hide Answer
Suggested Answer: D

Contribute your Thoughts:

0/2000 characters
Marci
9 months ago
Option A looks interesting too, but I’m leaning towards D.
upvoted 0 times
...
Vonda
10 months ago
I’ve used similar scripts before, and D worked perfectly for me.
upvoted 0 times
...
Luis
10 months ago
Wait, are we sure about that? What if the log format is different?
upvoted 0 times
...
Haydee
10 months ago
Yeah, D makes the most sense here!
upvoted 0 times
...
Earleen
10 months ago
I think option D is the right choice. It uses Select-String correctly.
upvoted 0 times
...
Fausto
10 months ago
I'm leaning towards option D too, but I wonder if there's a better way to summarize the results after filtering.
upvoted 0 times
...
Tracey
11 months ago
I feel like I've seen something similar in our last practice exam, but I can't recall if we used --Path or something else.
upvoted 0 times
...
Nathan
11 months ago
I think option D sounds familiar; it uses Select-String, which is often used for searching through log files.
upvoted 0 times
...
Lachelle
11 months ago
I remember practicing with Get-Content, but I'm not sure about the exact syntax for filtering errors and successes.
upvoted 0 times
...
Lynelle
11 months ago
This seems like a straightforward question about managing requirements changes. I think the key is to develop a formal change control process, so I'll go with option A.
upvoted 0 times
...
Ona
11 months ago
For some reason, I keep mixing up invalid characters in the certificate name with other types of errors. I guess that might relate to answer B?
upvoted 0 times
...
Xenia
11 months ago
Hmm, I'm a bit confused on the difference here. I'll need to think through the key characteristics of each approach.
upvoted 0 times
...

Save Cancel