Monday, 9 January 2017

The Tale of a New Machine

Just before Christmas, my old desktop PC died.  Well, actually only the main hard drive died, and I managed to limp through the Christmas break on the solid state drive alone.  However, it was 4 years old (my previous machine having died just after Christmas 2012), and the 120 GB SSD was constantly full and in need of management.  So I decided to bite the bullet and get a new machine, despite knowing what it would entail.

I ordered a new machine (Intel i7-6700, 4MHz, 4 cores, 8MB cache; 8GB RAM, 240GB SSD, 1TB HD; Windows 10; external DVD writer) and picked it up late on Wed 4 Jan.

I have since been reinstalling my life.  Many of the steps below took some persistent googling to find web instructions on what the problem was, and how to fix it.  Stack Exchange is a godsend!

  • install ZoneAlarm firewall and virus checker
  • connect to the internet
  • use IE to download Chrome
  • download and install Evernote – sync 10,000 notes, over the piece of wet string that is my home internet connection
  • download and install Google Drive – sync 15,000 files (10 GB), over said wet string
  • go to download Adobe Acrobat Reader DC, but discover it is already installed – yay!
  • download and install Notepad++ – now I can edit files
  • restore relevant files from previous machine backup
So endeth the first day.

  • download and install MS Office 365 (which I have access to via work)
    • 50 minutes to download.  See "wet string", above
  • download and install MikTeX and TeXnicCenter
  • download and install PaintShopPro X8 (via work)
  • download and install Power PDF (via work)
  • download and install Dropbox (more synching...)
  • download and install HP ScanJet drivers and software
  • download and install Python 2.7 
    • look at installing matplotlib, numpy and scipy – looks complicated, so pause for now
  • download and install 7-zip
So endeth the second day.

  • download and install Ace Money, my finacial software
    • plugged in the licence number from the original install, and it all works
  • get LaTeX to work...
    • fiddle with TeXnicCenter PDF profile to make it work with Adobe Acrobat Reader DC
    • add a new profile to work with Biber
    • discover the version of biber in MikTeX is incompatible with the version of pdflatex, despite have downloaded them in the same package
    • update MikTeX – except it will only update some parts
    • update MikTeX again – all now works
  • think about Python
    • decide to bite another bullet, and move up to Python 3, having checked that all the modules I use in my various bits of software (book review page generation, solar PV graphs, Trello backup code, etc) have Python 3 versions
    • WinPython apparently comes with matplotlib, numpy and scipy already, and allows both Python 2 and Python 3, so I decide to go for that
    • uninstall the “vanilla” Python 2.7
    • download WinPython 2.7
      • discover it isn’t actually fully supported, in that it doesn’t have matplotlib, numpy or scipy
      • decide not to install these separately, but just go for Python 3
    • download WinPython 3.5
So endeth the third day.

  •  install WinPython 3.5
    • use the Control Panel to associate .py files with WinPython 3.5
    • spend a LONG TIME trying to find what the path needs to be set to, to access all the different bits in different places; eventually go for
      • PYDIR =  D:\WinPython\python35\WinPython-64bit-\python-3.5.2.amd64
      • PYTHONPATH =  %PYDIR%\Lib\site-packages; %PYDIR%\Lib\site-packages\PyQt4; %PYDIR%; %PYDIR%\DLLs; %PYDIR%\Scripts; %PYDIR%\..\tools; %PYDIR%\..\tools\mingw32\bin; %PYDIR%\..\tools\R\bin\x64; %PYDIR%\..\tools\Julia\bin; %PYDIR%\Tools\scripts
      • add %PYTHONPATH% to system PATH
      • probably a bit over the top, but everything seems to work now
    • convert a couple of small utilities from python 2.7 to 3.5, using, and some hand tweaking
      • which went more easily that I had feared; main hand changes needed were removal of some code to handle Unicode strings...
    • convert the solar PV graphing utility to Python 3
      • some fiddling with csv file handling
      • strange warnings from numpy percentile function – which I will fix when I have time...
  • connect machine to home network
    • this requires updating the hosts file
    • can’t update the hosts file – being used by another process – but which one?
    • grovelling around on the web provides the culprit is ZoneAlarm
      • unlock in ZoneAlarm
      • update file
      • relock
So endeth the fourth day.

  • use mklink to recreate a symbolic link between the directory containg book cover images in my development directory, and in my website mirror directory
  • convert my book review webpage software to Python 3
    • main issue is the module to read the MS Access database
    • import pypyodbc module – “almost totally same usage as pyodbc” which I was using originally
    • download/install 32bit Microsoft Access Database Engine 2010 Redistributable
      • doesn’t work
      • apparently it need to be 32bit to match the MS Office, and 64bit to match the Python; hmmm
      • uninstall MS Office 365 32 bit, download and install MS Office 365 64 bit
      • uninstall 32bit Microsoft Access Database Engine 2010 Redistributable
      • download/install 64bit Microsoft Access Database Engine 2010 Redistributable
    • then need to edit the registry to allow it access to certain keys
    • then need to change to file location from bookdb.accdb to .\bookdb.accdb
      • sigh
    • then change every field access from row.Field_Name to row['field_name']
      • all the same functionality, but not necessarily in the same syntax
  • download/install WinMerge
    • to stop small differences in the output of the Python before and after porting...
So endeth the fifth day.

  • set up a VPN to access work stuff
    • download Pulse Secure app
    • poke the relevant holes in my ZoneAlarm firewall
    • discover from work support what I have to type into the userid box to get it to work – it’s not (just) my userid!
Normality has been restored

So endeth the sixth day.

So on the seventh day, I’ll be able to start working again!

If it wasn’t for the help of Stack Exchange, my home “sys admin”, and work support, this would all have been impossible.  I’m glad it happens only every four years or so...


  1. Anti-virus and firewalls are not necessary in Windows 10 since they already come with it!

    1. yeah, right -- a vendor with whom Windows 10 was *itself* a virus?!