Updated

A judge says Chris Brown must serve five years of probation and perform six months of community labor for beating Rihanna.

The 20-year-old appeared in court Tuesday afternoon to be formally sentenced for the February attack on his then-girlfriend.

Brown's sentence will be served in his home state of Virginia. He will have to return to Los Angeles frequently to update a judge on his progress.

Brown was arrested hours after the February attack and pleaded guilty to felony assault in June.

Brown apologized to fans in a video released and said he has apologized to Rihanna, who did not appear in court Tuesday.

The judge says the chief of police in Richmond, Va., will supervise Brown's community labor directly.