0

I tried installing gdb and pstack on EC2 Instance with Amazon Linux AMI (it was not installed by default), and it's not working.

Tried:

[ec2-user@ip-172-21-ab-xyz ~]$ sudo yum install gdb
Loaded plugins: priorities, update-motd, upgrade-helper
No package gdb available.
Error: Nothing to do

[ec2-user@ip-172-21-ab-xyz ~]$ sudo yum install pstack
Loaded plugins: priorities, update-motd, upgrade-helper
No package pstack available.
Error: Nothing to do

Tried to manually put gdb tar on AMI and compile it, but it didn't work. Not sure where to get RPMs for AMI. Where to download the packages from ?

Can anyone guide me on how to install GDB and pstack on AMI ?

K.K
  • 2,647
  • 1
  • 26
  • 32
  • I think you can install gdb from [source code](http://ftp.gnu.org/gnu/gdb/), and it is very easy: ./configure, make, make install. – Nan Xiao Oct 09 '14 at 01:07
  • @Nan Xiao - I tried it, but it didnt work. Used gdb-7.8.tar.gz and make fails. configure: error: no termcap library found make[1]: *** [configure-gdb] Error 1 make[1]: Leaving directory `/home/ec2-user/gdb/gdb-7.8' make: *** [all] Error 2 – K.K Oct 09 '14 at 02:33
  • Any recommendations for pstack? – K.K Oct 09 '14 at 02:38
  • "`no termcap library found`", please install [it](http://ftp.gnu.org/gnu/termcap/). For the `pstack`, it is only a shell script. Do you understand Chinese? If yes, please refer this [post](http://csrd.aliapp.com/?p=718), else tell me a mail address, I will send the script to you. – Nan Xiao Oct 09 '14 at 03:46
  • Thanks! I'll try installing termcap and let you know if it works. I don't understand chinese. You can email it to: kishykumar@yahoo.co.in – K.K Oct 09 '14 at 03:53

1 Answers1

1

I would suggest you to kindly execute the below command:

sudo yum groupinstall "Development Tools"

This will install all the tools required for development and build on Amazon AMI.

More on Amazon Development tools can be found here.

Srijan Chaudhary
  • 637
  • 1
  • 8
  • 18