First thing I'd suggest, is check wherever you have the machine is properly earthed.
Then make sure you're using a good quality USB cable (ideally one with a ferrite bead on it).

After that, the easy option is a USB isolator. Just search eBay for ADUM3160 for numerous options.