Subscribe

Issues with running pefstats on a unix system.

Hi,

I get the following error message when i try to run perfstats on a unix system:

~/Downloads$ ./perfstat.sh perfstat -S orion -t 2 -i 2 -I > perfstat.out

Perfstat: Perfstat v7.36 (4-2011)

Perfstat: Invalid perfstat invocation: './perfstat.sh perfstat -S orion -t 2 -i 2 -I' Please consult ./perfstat.sh -help.

Perfstat: Verify host rsh access

./perfstat.sh: 10039: rpm: not found

Perfstat: Allowing perfstat to run for a max 300 seconds

Perfstat: Collect Prestats

Perfstat: Prestats on ubuntu; OS: Linux

Perfstat: Sleep 120

Perfstat: Collect Poststats

Perfstat: Killing background processes...

Perfstat: Poststats on ubuntu; OS: Linux

I tried using  "-f orion " and "perfstat -l root : pwd orion -t 2 -i 2 -I > perfstat.out",but the i get the same result.But when i try to get the perfstat of the same filer through windows system then it works fine.I used "perfstat -l root : pwd orion -t 2 -i 2 -I > perfstat.out " on windows system.

Can any one tell me the correct invocation for unix system.

Thank you,

Rahul

Issues with running pefstats on a unix system.

The correct invocation can be found, with examples, on the page preceding the download page for perfstat.  I would suggest you try reading it again.  Try using a switch that avoids collecting local stats from your ubuntu server if you don't need them.

Issues with running pefstats on a unix system.

Hi Shaunjurr,

I thank you for your post.I tried all possible invocations from the perfstats download page and i think it is an issue with the authentication.We need to have SSH key authentication associated with individual user accounts from the back up server to the filer.

Re: Issues with running pefstats on a unix system.

Hi,

Key authentication works just fine.  You need to actually read what the script is telling you in your example  "Perfstat: Invalid perfstat invocation: './perfstat.sh perfstat -S orion -t 2 -i 2 -I' Please consult ./perfstat.sh -help."

You just haven't read carefully.  Why are you writing ':/perfstat.sh perfstat...' ?  That makes no sense and it is no wonder that the script is telling you that you are doing something wrong... because you are.

I can't tell if the last switch/option is -(capital i, or small L).

This should work (if the user that you are using to invoke it has its public key on the filer):  "perfstat.output" will contain all of the output besides what goes to STDERR  (standard error)

./perfstat.sh -f filer_name -t 2 -i 2 -S -I > perfstat.output    (the last option is capital "i")

You might want to add the -F option to avoid collecting everything about the linux/unix host, perhaps also -p to just capture performance info instead of also getting a full configuration dump of the filer, if it's not necessary.

-t should probably be a lot longer and you can adjust the sampling lengths within "-t"  by using the "-i" option with multiple values... like "-i 10,10" or something.  Again, ./perstat.sh --help will tell you all of this should you actually want to take the time to read it carefully.

The script works fine with public keys.  As far as I can see from your examples, you are just using it wrong.

Re: Issues with running pefstats on a unix system.

May be you haven't clearly seen what i have posted in the discussion.First take a good look at what i have posted in the discussion and give your reply politely.I have tried every single invocation,but could not get it right.I was right with my assumption because i have made it clear with one of the Technical Global Advisor for netapp.There will be a ssh authentication for individual user account from a unix server connecting to the filer and that has caused me of the above error.And for your reference i am posting the command invocation that you have posted:

ubuntu:~$  ./perfstat.sh -f orion -t 2 -i 2 -S -I > perfstat.output

Perfstat: Perfstat v7.36 (4-2011)

Perfstat: Verify host ssh access

./perfstat.sh: 10039: rpm: not found

Perfstat: Verify filer ssh access

Perfstat: Filer orion fails ssh test

Perfstat: Verify connectivity using: ' ssh -o BatchMode=yes -2 -ax orion -n -l root "version"' from ubuntu

Thank you for your post.

Re: Issues with running pefstats on a unix system.

Hi,

So what did 'ssh -o BatchMode=yes -2 -ax orion -n -l root "version' give you for output?

What user are you supposed to be using on the filer if not root?

Re: Issues with running pefstats on a unix system.

Hi,

i have the same problem with running perstat.sh in a script.

ssh -o BatchMode=yes -2 -ax orion -n -l root "version'   --> i get a Permission denied error (publickey,password)

How can i import a public key to run a perfstat script in a linux(debian) environment?

These hint is not working for me:

http://communities.netapp.com/blogs/fitforpurpose/2009/11/27/netapp-storage-system-automation-using-ssh-instead-rsh

Note: ssh and rsh is working, but only with enter passwordphrase

thx and br

Frank

Re: Issues with running pefstats on a unix system.

What exactly is not working?

I have over 50 filers (and probably 30+ vfilers) that I can use ssh keys with openssh.  The public key from whoever is going to login as root has to be in <root volume>/etc/sshd/root/.ssh/authorized_keys2 .  This key has to be created without a password/passphrase or you have to use ssh-agent on your host to deal with passwords/passphrase.

Try to login via ssh first... perhaps with 'ssh -vvv' to see what is going on.  You might want to make sure that you have no strange default local configuration that is breaking things for you.

Re: Issues with running pefstats on a unix system.

My folder look like this:

/vol/vol0/etc/sshd/.ssh      -> it contains   id_dsa ; id_dsa.pub ; known_hosts

Linux Debian Host

Create pair ssh keys, private & public by ssh-keygen from SSH pkg like

     ssh-keygen -t dsa -b 1024  [without paraphrase]  -> copied to /vol/vol0/etc/sshd/.ssh    -> .ssh doesnt exist -> created with 0600 rights

        

On the Netapp Storage System console

     o Run the Secure Admin Setup using the command  secureadmin setup ssh  Setup will now generate the host keys. It will take a minute. After Setup is finished the SSH server will start automatically.

     o make sure that ssh option on Netapp "ssh.pubkey_auth.enable" is on

4. Test the Connection from host

     o You can now run ssh remotely from your host to NetApp to get info like:

         [21:46][danielpr@siml9 ~] >ssh 192.168.1.2 -l root 'vol status -f'


          Broken disks (empty)

         [21:46][danielpr@siml9 ~] >

Something is wrong ...  i see your folders are different.

Which folders and which file will be copied to which directory?

Re: Issues with running pefstats on a unix system.

/etc/sshd/root/.ssh is not file - it is directory, just like on any Unix system. You put authorized keys into /etc/sshd/root/.ssh/authorized_keys (or may be authorized_keys2 for SSH-2 as pointed above, do not remember right now).

Read OpenSSH manual how authorized_keys is used.