In a medium-size pan, bring the barley and 4 cups of water to a boil. Cover, reduce heat to medium-low, and simmer until tender, 30 to 35 minutes.
Meanwhile, heat the oil in a large pot over medium-low heat. Add the onions, ½ teaspoon salt, and ¼ teaspoon pepper. Cover and cook until the onions have softened, 5 to 7 minutes.
Add the carrot and celery and cook, covered, for 6 minutes more.
Add the mushrooms, increase heat to medium-high, and cook, covered, until they release their juices, about 4 minutes.
Add the broth, bay leaves, and thyme and simmer, uncovered, for 10 minutes.
Stir in the cooked barley; remove and discard the bay leaves. If desired, season with additional salt and pepper and serve with the sourdough toast.