Disclosed herein is a compound of formula (I) and/or a pharmaceutically acceptable salt thereof that can serve as Erk inhibitors. They are potentially useful in the treatment of diseases treatable by inhibition of Erk, such as cancers. Also disclosed herein is a pharmaceutical composition, comprising a compound of formula I and/or a pharmaceutically acceptable salt thereof and a pharmaceutically acceptable carrier.