Ubuntu – How to download .mp3 files whole site

httrackwget

I want to download all mp3 files in the website (even in home page and sublinks).

For example I want to download all .mp3 links from the "http://example.org/musics/" and all sub-links.

How can I do this by using wget or httrack commands?

Best Answer

With wget command you can use:

wget -c -A '*.mp3' -r -l 1 -nd http://example.org/musics/
  • -c: continue getting a partially-downloaded file.
  • -A: only accept mp3 files. change this format with another format you want to download.
  • -r: recurse
  • -l 1: one level deep (ie, only files directly linked from this page)
  • -nd: don't create a directory structure, just download all the files into current directory.
Related Question