Split large file and assemble the parts








split -b 256mb large-file.tgz large-file.tgz.
cat large-file.tgz.* > /path/to/output/large-file.tgz



Thread-safe, fixed-size map remove the eldest element automatically








    public static final int MAX_SIZE = 1000;
    Map map = Collections.synchronizedMap(new LinkedHashMap() {
       private static final long serialVersionUID = 12345L; 
       @Override
       protected boolean removeEldestEntry(Entry eldest) {
           return size() > MAX_SIZE;
       }               
    });



See also stackoverflow

  • https://stackoverflow.com/a/28654664
  • https://stackoverflow.com/a/1963881



Unlock Telstra 4G My Pocket WIFI LITE (ZTE MF90)








  1. Download and install the driver
    • Download ZTE MF90 driver to a Windows 7 PC, extract the zip package
    • Turn the device on, and connect it to Windows 7 PC via USB cable. It should detect the device and install the driver. For me it does not find the driver automatically. Instead it shows "ZTE xxx installation" unsuccessfully.
    • Go to Control Panel then search and open Device Manager, you should see three unknown devices with name "ZTE xxx xxx xxx". Right click each unknown device, then select Update drivers, then select the directory where the ZTE MF90 driver was extracted to. NOTE: You need to update drivers for each unknown device.
  2. Download and run DCCRAP
    • Google DCCRAP, download and make sure it does NOT contain virus (you can check the file using VirusTotal).
    • Run DCCRAP on the Windows 7 PC, select ZTE data cards then Auto detect the device. Once the device is detected, you can click the Unlock button to unlock it.
  3. Set to use non-telstra APN
    • Put a telstra sim into the device and turn it on
    • Login the web portal in 192.168.0.1, using password: password
    • Set apn to vfprepaymbb for Vodafone