Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have installed the AWS Command line tools and have also set the Env Variables, but why I type mon-cmd I am getting this error, I am not able to figure it out,kindly help me.

/usr/local/aws/bin/mon-cmd: line 12: /home/ubuntu/usr/local/aws/bin/service: No such file or directory
/usr/local/aws/bin/mon-cmd: line 12: exec: /home/ubuntu/usr/local/aws/bin/service: cannot execute: No such file or directory
share|improve this question
    
Do you have a user called ubuntu? –  Bart De Vos Jan 25 '12 at 12:09
    
Can you post the output of ls -l /home/ubuntu/usr/local/aws/bin/service? –  Khaled Jan 25 '12 at 12:09
    
@Khaled ls: cannot access /home/ubuntu/usr/local/aws/bin/service: No such file or directory –  Jeevan Dongre Jan 27 '12 at 4:54

2 Answers 2

up vote 2 down vote accepted

It looks like the mon-cmd is looking for the binaries path in /home/ubuntu instead of /.

Can you show how you set the EC2_HOME environmental variable? You an run something like env |grep EC2.

I have mine set like:

export EC2_HOME=~/ec2

I suspect you have it set similarly, but you probably want it set to / (i.e., export EC2_HOME=/) or something similar.

You may need to add /usr/local/aws/bin to your PATH, additionally.

share|improve this answer
    
I have set the EC2 home path as /usr/local/aws by export EC2_PATH=/usr/local/aws –  Jeevan Dongre Jan 27 '12 at 4:56

It's not EC2_PATH. Do this:

$ export EC2_HOME=/usr/local/aws
$ export PATH=$PATH:$EC2_HOME/bin

Then, with your private key and certificate:

$ export EC2_PRIVATE_KEY=~/.ec2/pk-XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX.pem 
$ export EC2_CERT=~/.ec2/cert-YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY.pem

Change X and Y for your respectives.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.