Abstract


Socket


Network Domain SocketUnix Domain Socket
ScopeNetwork-wide communicationCommunication within the same machine
AddressingIP Address + PortFilesystem path
ProtocolsTCP/IP (TCP, UDP, etc)Unix-specific IPC protocols
OverheadHigher due to network layersLower, everything happens on the same machine, no network overhead
SecurityMore exposedMore restricted with file permissions