DB:
MySQL “innodb” row-level lock
# Start transaction
mysql> START TRANSACTION;
# IX (intention exclusive lock) on certain rows -- lock until transaction ends (committed)
mysql> SELECT * FROM Rig WHERE RigID > 251 FOR UPDATE;
# Do what u want (e.g. update to some cols for the specific rows)
mysql> UPDATE Rig Set State = 2 where RigID > 251;
# End transaction with commit (and thus lock will be released after this)
mysql> COMMIT;
- Note: mysql-python connector, by default, use transaction (so no need to ‘start transaction’ at first
- Prolong ur sql-connection
- MySQL cheat sheet
Murmur:
- Gateway point (from inner node)
- Ubuntu (Linux-based) firewall setting
- CHT (floating ‘fix’ ip)
- Release the PAWA on ur server
- How, the fuck, would u successful scripting reboot