'Unsubscribe a system from subscribed channels
Args:
serials(list or None): list of serials to unsubscribe. If
serials is none or an empty list, then
all subscribed channels will be removed.
Raises:
* Exception - if error occurs while running command'

def unsubscribe(self, serials=None):

    items = []
    if ((serials is not None) and serials):
        items = [('--serial=%s' % s) for s in serials]
    if (serials is None):
        items = ['--all']
    if items:
        args = (['subscription-manager', 'unsubscribe'] + items)
        (rc, stderr, stdout) = self.module.run_command(args, check_rc=True)
    return serials
