Skip to content

Metasploitable3 Installing and Building (Step by Step)

hello folks,

In this post, I am going to explain how to download and install Metasploitable3 in Linux with Virtual box.


  1. Introduction of Metasploitable3
  2. Setup RequiredTools.
  3. Build Metasploitable3 Automatically ( for Pen tester )
  4. Build Metasploitable3 Manually ( For Developers )
  5. Pro Tip. (Optional)
  6. Download Metasploit3 ( VirtualBox OVA ) (Noo Need to Build)
  7. Acknowledgements

Introduction Metasploitable3

Metasploitable3 is a VM that is built from the ground up with a large number of security vulnerabilities. It is intended to be used as a target for testing exploits with Metasploit.

Differences between Metasploitable 3 and the older versions

Previous versions of Metasploitable were distributed as a VM snapshot where everything was set up and saved in that state. Metasploitable 3 introduces a new approach: dynamically building the VM image. It utilizes PackerVagrant, and a ton of scripts to go from nothing to a fully functional, exploitable VM within minutes.

Setup Required Tools

Git Installation.

sudo apt-get install git

Packer Installation 

sudo apt-get install packer

Vagrant Installation 

Download Link:

cd /tmp/
sudo dpkg -i vagrant_1.9.1_x86_64.deb

NOTE: Currently 1.9.1 is recommended as there are build issues with newer versions.

Vagrant Plugin

vagrant plugin install vagrant-reload

For Virtual Box installation follow the OFFICIAL site.

If you don’t have Brain, stop reading here.  😛

If you reading this Online Means you have internet already.

Minimum 8BG Physical Memory required on the Host system for Build Metasploitable. if don’t have 8GB go to Pro Tip Section it will help you.

Go Ahead. 😉

Download Metasploitable3

Actually, Our Metasploitable3 Installation journey starts from here. We have to download Metasploitable 3 from Official Sources and Build it step by step.

Official Project Source Link:

Download Project

Using Git

git clone

Any Browser 

Visit this:

Build Metasploitable3 Automatically  ( for Pentester )

Run the command

vagrant box add jbarnett-r7/metasploitable3-win2k8


vagrant box add metasploitable3-win2k8

download metasploitable3

This will download the 6.5+ GB box file from Vagrant cloud. This may take a while depending on your Internet connection.

List vagrant Box

vagrant box list

vagrant metasploitable3 list

To start the VM

vagrant up

This will start up the VM network. This takes about 5-10 minutes.

Once this process completes, you can open up the VM within VirtualBox and log in.

The default credentials are

  • Username: vagrant
  • Password: vagrant.

Build Metasploitable3 Manually ( for Developer )

Here, I assume you already downloaded a Metasploitable 3 Project using Git or Browser. If you downloaded using any Browser or Download manager, Please extract it in any Directory where you have to written permission.

Let’s Build Begin,

Fire up terminal and Change Directory to metasploitable3’s folder.

metasploitable3 directory

Now, Download Windows Template.

Syntax : packer build –only=<provider>-iso windows_2008_r2.json

Here <provider> means, Which virtualization platform you are going to use for Importing.

I’m Going to use Virtual Box.


  • Virtual Box: virtualbox 
  • Vmware: vmware

Warning: This Below command automatically Download Windows Template and Installed it in your Virtual Box and do all the required steps like setting up ssh, and other vulnerability. 

packer build --only=virtualbox-iso windows_2008_r2.json

The above Command help u to Download all Pieces Which u required for the Next Step. It will take some mins or hours (Depending on Your Internet Speed and System 😛 ).

Let’s add this is a Vagrant environment.

vagrant box add windows_2008_r2_<provider>.box --name=metasploitable3

building metasploitable3

install the reload vagrant provisioner if you haven’t already

vagrant plugin install vagrant-reload

To start the VM

vagrant up

This will start up the VM and run all of the installation and configuration scripts necessary to set everything up. This takes about 20 minutes.

Once this process completes, you can open up the VM within VirtualBox and log in.

The default credentials are

  • Username: vagrant
  • Password: vagrant.

Pro Tips

If you are building for Virtual Box Provider. Modify windows_2008_r2.json files according to your host system.

LineNumber  Code

85 "--memory",
86 "1200"

This is for Ram

91 "--cpus",
92 "2"

This is for the CPU.

And For VM-Ware users

 41 "memsize": "2048",
 42 "numvcpus": "2",

Modify these lines.

Download Metasplotitable 3 ( OVA file)

If you tried up by manually downloading and building and got frustrated or if you don’t have tools.

Just Download metasploitable3 OVA File and import into Virtual Box. (Like a Boss)

Download Link: click here


The Windows portion of this project was based on GitHub user [joefitzgerald’s]( [packer-windows]( project.
The Packer templates, original Vagrantfile, and installation answer files were used as the base template and built upon for the needs of this project.

Greetz : jbarnett ( for Cloud vagrant File )

This is all for this post.

Special thanks to my HackTheBox’s Friends @B00gie , @Danners and all other HackTheBox Telegram Group Members. 🙂

If you Like this post, Please Comment below and share it with others.

Published inganeral


  1. Emmy Emmy

    Hey, thanks for the Metasploitable3, however can you provide a torrent or magnet link.

  2. DanTheMan DanTheMan

    Yes, thanks for effort and work you’ve put into this, but is there a torrent or Google Drive link? Mega only allows 5GB download for free users 🙁

    • yes. sure…. i ll update soon with link …. or just ping me on twitter @touhidshaikh22

  3. dany dany

    thank you friend do not know how many times I try it and I have not managed to make it work … downloading …..

  4. unnamed unnamed

    hello! can you creat ova file and put it in google drive for free downloading!

  5. unnamed unnamed

    Thank! I would like both systems. on ubuntu and Windows

  6. sathish sathish

    Mega has download limit, it’s prompting to signup. Please share torrent link to download OVA file.

  7. unnamed unnamed

    where are you???

  8. D33g D33g is not user friendly download hoster! I need a vm-file (like the .OVA) for vmware.

  9. sarhadil sarhadil

    thanks a lot for sharing this article.
    but i need the OVA file of metasploitable3 for VMWARE Work Station only not with VirtualBox.
    is it possible or not?
    thanks for bests

  10. D33g D33g

    Why is there no network device installed in your metasploitable3?
    I can’t have a ip address because of no network device.
    How can i fix it?

    Nice, you have installed the VirtualBox guest additions, but i use vmware!
    So i can’t install the vmware tools.
    How can i fix that?

  11. bugsec bugsec

    Thanks a lot for sharing this article.

    But I’m getting an error after I ran vagrant up…(I used pentester phase)
    can u help me out ….for fixing that issue

  12. Valec31 Valec31

    There is a problem with the download in google drive. Drive tells me i can’t download the file because too many users did, so i should try again later. I’ve been waiting a few days now but it’s still not working… could you fix it by charging it again or something please? Thank you very much

Leave a Reply

Your email address will not be published. Required fields are marked *