The adequate minimum is 1-2 minutes (100C water at the sea level). Mind the altitude. To kill bacteria you need a combination of temperature and time. At some altitudes (miles), without a pressurizer, you just can't kill some resilient strains in a reasonable time (low boiling temperature). Use other disinfection methods in addition.
Why no less?
For this method, you just need to know the local boiling temperature. Any pre-boiling temperature demands a thermometer to be sure that you're heating the water as intended. And the 1-2 minutes are enough to assure that it was boiling, not -5 -7C from the boiling point near the surface or so while you're thinking there was a full volume already boiled.
Why 1-2 min. is safe enough at most elevations?
See the tables about temperatures for pathogen killing and boiling temperature at different altitudes.
The maximum is 30 min. It's for Anthrax as an edge case, again 100C at the sea level. The most important thing - it's a misconception that 70C for 30 minutes; 85° C for 2 minutes, or alike low energy procedures are ultimate protection. It's a somewhat recommendation for your protection on average, not a guarantee. It isn't killing everything, just lowering the most common harmful pathogens (including parasites, viruses, etc., excluding spores and toxins) to safe for a healthy individual levels. Alas, 30 min 100C boiling either won't kill everything, but it's already a paranoid level of heating.
You can meet something like this bacterium in the wilderness; however, most of the time you will not.