($UUID) = map { (split (/"/, $_))[-1] } grep { /IOPlatformUUID/ } `ioreg -d2 -c IOPlatformExpertDevice`; print $UUID;