The AVR side of the Yun is an ATmega32U4, the same processor as the Leonardo has. On these Arduino types the "Serial" object is not a HardwareSerial class instance but connected to the USB serial emulation. Use the "Serial1" object there to access pins 0 and 1.