"Printing the expiry date and batch number on a drug vial label" would normally be called "labelling". Google translate provides this, but also illustrates the problem of using it here:
Labelling and labelling of vials is carried out on the labelling machine. The serial number and expiry date on the label are applied with the labelling unit of the labelling machine.
I would agree that marking might be an alternative in the first sentence, but you could use a more technical expression for the second sentence. "Print unit" or "printer unit" are descriptions I've seen.
Labelling and marking of vials is carried out on the labelling machine. The serial number and expiry date on the label are applied with the print unit of the labelling machine.
Or, you might get away with a slightly looser translation (since you are changing words anyway):
Labelling of vials is carried out on the labelling machine. The serial number and expiry date on the label are printed by the labelling machine.
Since there is one machine, it's reasonable to describe what that machine does as "labelling". The second sentence makes it clear that part of what that machine does is print information on the sticker. Unless you specifically need to mention a "print unit", it's reasonable to infer that there is such a mechanism in order to do the printing.