Database Synchronization

Shared Disk Failover

PROS

CONS

File System ( Block-Device ) Replication

Warm and Hot Standby Using Point-In-Time Recover ( PITR )

PROS

Trigger-Based Master-Standby Replication

Statement-Based Replication Middleware

Asynchronous Multimaster Replication

PROS

Synchronous Multimaster Replication

CONS

Transactions

A transaction is a set of database reads and writes that is handled as a unit with a few crucial properties. Reads in the transaction see the same snapshot of the data base, writes within a transaction either all succeed or all fail, after a transaction succeeds, the writes are permanently stored.

Foundation DB’s Transaction Manifesto

It is becoming clear that supporting transactions is a matter of engineering effort, not a fundamental trade off in the design space.

Foundation DB’s Transaction Manifesto

FoundationDB decouples its data storage technology from its data model.

High Level Overview of Dist. Systems

There are two basic tasks that nay computer system needs to accomplish:

The performance advantage of high-end hardware is limited in tasks that require large amounts of communication between nodes.

Scalability: The ability of a system, network, or process, to handle a growing amount of work in a capable manner or its ability to be enlarged to accommodate that growth.

In distributed systems there are two types of latency that cannot be overcome:

Availability = uptime / (uptime + downtime)

FLP Impossibility Result

Examines the consensus problem under the asynchronous system model. It is assumed that nodes can only fail by crashing; that the network is reliable, and that the typical timing assumptions of the synchronous system model hold: e.g. there are no bounds on message delay.

there does not exist a (deterministic) algorithm for the consensus problem in an asynchronous system subject to failures, even if messages can never be lost, at most one process may fail, and it can only fail by crashing (stopping executing).

CAP Theorem

Network Architecture and Protocols

PURPOSES OF NETWORK PROTOCOLS

Internet Protocol Suite

Link Layer: Ethernet PPP

Internet Layer: IPv4, IPv6

Transport Layer: TCP, UDP

Application Layer: HTTP, SMTP, DNS

Service Multiplexing allows a single node to support multiple different services by assigning a different number for each service; this number is called a port.

17f1d15f5acb40ef02bf23a3dd6dd6a6.png

Default Gateway is the catchall IP address to which a router can send IP packets

ALTERNATIVE MODEL

CAPTURING NETWORK TRAFFIC

Passive network capture via tools like wireshark

Tracing System Calls

Common Unix Systems Calls for Networking

Types of Network Proxies

Port Forwarding: set up a listening server and wait for a new connection. When the new connection is made to the proxy server, it will open a forwarding connection to the real service and connect the two.

SOCKS Proxy: Forwards TCP connections to the desired network location, and all new connections start with a simple handshake protocol that informs the proxy of the ultimate destination rather than having it fixed. It also supports listening connections. Generally preserves the destination of the connection from the point of view of the client application.

HTTP Proxy: HTTP can be co-opted as a transport mechanism for non-web protocols like RMI and RTMP because it can tunnel through most restrictive firewalls. Two main types of HTTP proxy: forwarding proxy and reverse proxy. CONNECT HTTP method creates transparent, tunnelled connections over HTTP proxies. HTTP proxies can be used to tunnel out an application’s own binary protocols, so it’s common to find deployments of HTTP proxies restricting the ports that can be tunnelled to a very limited subset.

NETWORK PROTOCOL STRUCTURES

Binary Protocol Structures: Operate on the single binary digit level though bytes are the defacto unit of network protocols.

#systems_programming