Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7400861
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T04:18:52+00:00 2026-05-29T04:18:52+00:00

use Control::CLI; $cli = new Control::CLI(‘SSH’); $cli->connect(Host=>’10.10.10.10′,Username=>’user’,Password=>’pwd’); $cli->waitfor(‘>’); $cli->print(‘Show XXXXXXXXXXXXXXXXXXXX| grep Active’); @f=$cli->waitfor(‘>’); print

  • 0
use Control::CLI;
$cli = new Control::CLI('SSH');
$cli->connect(Host=>'10.10.10.10',Username=>'user',Password=>'pwd');
$cli->waitfor('>');
$cli->print('Show XXXXXXXXXXXXXXXXXXXX| grep Active');
@f=$cli->waitfor('>');
print @f;
$cli->disconnect;

The above code give me output as:

 Show XXXXXXXXXXXXXXXXXXXX| grep Active
Active
Sunday January 29 00:40:34 IST 2012
Active                  : 1106          Dormant                 : 0
[local]NOI-S57-XYXYX>

But I want to capture only “1106”( in the 3rd line, value between Active: “1106” and Dormant), Please help!!

Thanks in advance!!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T04:18:54+00:00Added an answer on May 29, 2026 at 4:18 am

    The following code worked for me:

    @myarray = ($f =~ m/(\d+)/g);
    print "@myarray['5'] ";
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Hai am having a WPF user control, when i use that control in another
How do I use a WinForms control written in C#, in a WinForms C++/CLI
I have an ASP.NET user control that is used in another use control. The
I only want to use CreateUserWizard Control to collect information from the user and
With WinForms, I can use Control.Scale to scale a control larger. When I do
I need to change the HTML rendered by the NumericPagerField. I can't use Control
We use Grid Control 10.2.0.4, with a catalog repository database also at 10.2.0.4. It
We use cruise control .net to do our Continuous Integration in our Delphi 2006
I use version control extensively. When I'm working by myself, I still use it,
I know you can use source control software for source code, but can you

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.