Usando grep com extensões GNU
$ grep -ozP '[$][^$]*[$][^\n]*\n' logfile
$onMaxCapacityList: 5
Y100
X069
Y010
Y400
Y401
$aboveMaxCapacityList: 0
Usando o Python
$ python -c 'import re; print(re.search(r"[$][^$]*[$][^\n]*", open("logfile").read()).group())'
$onMaxCapacityList: 5
Y100
X069
Y010
Y400
Y401
$aboveMaxCapacityList: 0
Usando sed:
$ sed -n '/^[$]/,/^[$]/p' logfile
$onMaxCapacityList: 5
Y100
X069
Y010
Y400
Y401
$aboveMaxCapacityList: 0
Usando o awk:
$ awk '/^[$]/{print; f=!f; next} f{print}' logfile
$onMaxCapacityList: 5
Y100
X069
Y010
Y400
Y401
$aboveMaxCapacityList: 0