To do a barrel roll, get the "Airtime" challenge, then go up as fast as you can. Then hit the side of the ramp and you should do a full barrel roll and land safely on your wheels.
You will lose a little bit of control after landing, but just for a couple of seconds.
If you want to ride on two wheels, go on challenges, then pick airtime. During the challenge, go fairly around 30 mph, then hit the side of the ramp. You should ride on two wheels for around 5 seconds.