I use
VirtualDubMod for this purpose. first you should copy the dvd files to hdd with dvddecrypter or just copy the VOB file that has the music,
open the VOB with VirtualDubMod and if the movie has several audio streams, you should select the correct one here, now you should edit the movie and delete the unnecessary section of movie from track bar.
goto streams->stream list->Demux, and save the AC3 file.
you can also rip the music with
DVD Audio Ripper but the output is only mp3 or wave.