How to create iso file from CD/DVD-ROM on Linux/BSD/UNIX

Sometime you might need to back up your CD/DVD-ROM of Windows, Linux, or any other operating systems installer. The easiest way to backup them is to copy to other CD/DVD-ROM, but it is also better to backup them in an .iso file image. In Windows there are many third party software to do this job such as WinISO, MagicISO, etc.