Using CSS to Validate Input


// Should not match
' '
'  '
'   '
// Should match
'one-word '
' one-word'
' one-word '
'one phrase with whitespace'
'one phrase with whitespace '
' one phrase with whitespace'
' one phrase with whitespace '
Read More

Disable auto reboot after update on Windows Server 2016

Usually all servers need to be reboot mannually instead of do it automatically because we need to make sure all services are online after reboot. I cannot find Download only option on GUI Windows Update Settings on Windows Server 2016. But we can run command sconfig with admintrators privilege to change it.

Read More

Python Generator

What is generator in Python?

  • A simple way of creating iterators
  • A function with yield statement instead of return statement. It can have mutilple yield statements.
  • Iterator methods __iter__() and __next__() are implemented automatically.
  • yield statement pauses the function saving all its states and later continues from there on successive calls.
  • When called, it returns an object (iterator) but does not start execution immediately.
Read More

Mysql Slave Node Last-IO-Error Got fatal error 1236

Problem 1

  • Error Message
    Last_IO_Error: Got fatal error 1236 from master when reading data from binary log: ‘log event entry exceeded max_allowed_packet; Increase max_allowed_packet on master; the first event ‘binlog.000201’ at 5480571
Read More