"kcott, tnx for reply i thing you are write. ... And what are the other options for the prompt.."

I've never used Net::Telnet, so I've had to do what you need to do, i.e. Read The Fine Manual.

At the very least, search for prompt. You'll find all sorts of information, including default value, hints, tips and gotchas.

The author of Net::Telnet appears to have gone to a fair amount of effort to provide the necessary information. However, there does seem to be some expectation regarding a basic knowledge of Perl's regular expressions: if you don't have that, I suggest reading "perlretut - Perl regular expressions tutorial".

"... im new to perl and still learning, and i think this is a noob question so dont judge me :) ..."

I am not judging you. I never judge someone on the basis of not knowing some particular piece of information: we start off life knowing nothing and we all learn different things. Until a few hours ago, I didn't know this information either.

Having said that, I note your last question, "Telnet Cisco routers", involved using Net::Telnet::Cisco. The first and third sentences in that documentation are:

"Net::Telnet::Cisco provides additional functionality to Net::Telnet for dealing with Cisco routers."

...

"Before you use Net::Telnet::Cisco, you should have a good understanding of Net::Telnet, so read it's documentation first, and then come back here to see the improvements."

So, perhaps this is something you should have known about.

Finally, I'm not trying to put you off from posting here. We're happy to help but we do expect you to show some effort yourself: asking for information that's clearly documented does not indicate any such effort. This is all explained in more detail in "How do I post a question effectively?".

-- Ken


In reply to Re^2: Telnet to a switch by kcott
in thread Telnet to a switch by IvanAK

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.