Putty Session using PowerShell

This topic contains 6 replies, has 4 voices, and was last updated by Profile photo of Max Kozlov Max Kozlov 10 months, 2 weeks ago.

  • Author
    Posts
  • #34493
    Profile photo of Narayan Gupta
    Narayan Gupta
    Participant

    Hi Mates,

    I have around 60 chassis and I want to automate the below steps and get the output from all the chassis to a single file (text/csv) on my local computer using PowerShell. Is it possible ? If yes, how can I start with?

    1. Login to Chassis using Putty.
    2. Run the command to get information.
    3. Copy the output to local file.
    4. Log off from Putty Session.

    Cheers,
    Narayan

  • #34495
    Profile photo of Jason Colotario
    Jason Colotario
    Participant

    I would use Plink to automate "if" you want to go down that route. Other options could be PowerShell itself – meaning you would use PowerShell to remote into the target machines and then use say WMI to retrieve system/hardware information.

    Regards,

    Jason

  • #34496
    Profile photo of Brian B
    Brian B
    Participant

    I agree with Jason regarding Plink due to the fact that you said Chassis... and I assume you mean either Cisco, HP, Dell, or IBM Chassis and not a Windows machine where WMI would work. Which is it, btw? I know you can do some neat stuff with Powershell and other utilities with the HP Onboard Administrators... but i'm not familiar with others yet.

    Brian

  • #34505
    Profile photo of Narayan Gupta
    Narayan Gupta
    Participant

    Thanks Jason and Brian

    @Brian, I have Hitachi chassis not a windows machine. btw, how can we proceed with HP. I will try to relate and see what comes up.

    Cheers,
    Narayan

  • #34507
    Profile photo of Brian B
    Brian B
    Participant

    I'm not at work right now, but it's literally commands made just for HP. There are some ILO cmdlets you can install. It will not work for Hitachi. I know Hitachi has some powershell cmdlets, but i'm not sure they apply to their chassis. We were looking at the HNAS and they work with that, but that's my only knowledge of Hitachi

    Brian

  • #34508
    Profile photo of Narayan Gupta
    Narayan Gupta
    Participant

    I saw download link of cmdlets for Hitachi Servers. Will check and update here.

    Cheer,
    Narayan

  • #34527
    Profile photo of Max Kozlov
    Max Kozlov
    Participant

    take a look to Posh-SSH, I use it for my Linux/Windows interoperation tasks

    https://github.com/darkoperator/Posh-SSH

You must be logged in to reply to this topic.