Tuesday, December 29, 2015

Windows 10 Upgrade Test

I wanted to test out Windows 10 so during the xmas holidays i built a box and installed windows 7 64bit and then upgraded it to 10.

CONCLUSION:  DO NOT upgrade from windows 7 to windows 10 using the 'upgrade' option unless you have a computer with only 4 gig of ram. Why? Because you get the 32bit version and those lose access to your 8/16/32 gigs of ram and the default windows partitioning is not optimal but changing it is a pain.

Best Practice:

Create 64bit version on usb stick and boot to that to do a clean install. I made a bootable stick with 32/64 bit versions in case i need it someday.

Other Conclusion:

For technical types this is an incredibly annoying OS, it is designed for noobs, it is increasingly and constantly chatty.  Win 10 will not increase your productivity. Any having live tiles of ads/news/cat videos and social stuff on your desktop? This is a consumer/tablet release, not for people who work for a living.

But with a lot of work you can turn off and remove most of the new 'features' to get it to work the way you want. The questions is - are the new features worth the effort?  My answer was NO - there is nothing really in there to make me switch my main work machines from win 7 64bit to windows 10. Someday i will have to but there is no compelling reason to do so now. My main gripe with windows is it's awful network file operations - it takes forever to 'discover' directory listings and to manage many large files over a network. Win 10 is slightly better but not enough to make me upgrade.

Here is my journal notes in case i need to refer to them again...

Download and run the media creation tool

Select "For another PC" to create bootable flash media or download an ISO to burn to DVD with Windows Image Burner.  Now you have media for reinstalls or needed repairs.  But to run the Upgrade it must be opened in Windows 7/8.1,  right click Setup file to Run as Admin. 

To improve the Upgrade's chances turn off everything at Startup:

In Windows 7, type msconfig in Start Search Box, uncheck everything on Startup and Services tabs, after Hiding all MS Services.  Apply, restart.

In Windows 8.1, right click Task Bar to open Task Manager, disable everything in Startup Tab, Apply, Reboot.

Uninstall any anti-virus except Defender.  Bloated AV's like Norton, MacAfee, AVG and Avast need to have special Uninstallers (removal tools) for common antivirus software - ESET Knowledgebase.
Stick with built-in Defender in Windows 10 for best performance and adequate protection.  If you get infected add the inexpensive Real Time protection from the best-in-class free malware scanner Malwarebytes .  I'd also periodically scan with SUPERAntiSpyware or the more powerful AdwCleaner, also best-in-class and free.

Immediately after install, type Update in Start Search box to Check for Updates, expedite these through requested restart, then check again until no more are offered.  Next right click Start button to open Device Manager, import any drivers still missing from the PC or Device's Support Downloads webpage.  How to: Install and Update drivers in Windows 10 - Microsoft Community

It’s highly recommended to save a backup System Image of your existing OS before upgrading, which can be recovered using the Windows disk, Repair CD or Recovery flash drive in 20 minutes.   Type Backup in Start Search box, in Backup and Recovery Center choose Create a System Image.  You can also use a more flexible imaging program like free Macrium Imaging.

IF you are going to install the 64bit edition over the 32bit edition you need a Windows 10 product key. If you are goint to install over windows 7 or windows 8.1 you do not need a product key. So it is vital you do not run the upgrade option as then you lose your free upgrade if you have more than 3gig of ram. You have to make the boot media and upgrade from that to 64bit to have a free upgrade.

windows 10 upgrade

Navigate to your C:\Windows directory. Once there, you’ll want to configure Explorer to show hidden files and folders.

In Windows 7, you do this by clicking on “Tools,” then “Folder Options,” and finally “Show Hidden Files and Folders,” as shown below. In Windows 8/8.1, click on the View tab and then select the “Hidden items” check box.

Once this is done, check your Windows directory for a directory named $WINDOWS.~BT. The icon may be translucent, since the folder is normally hidden, so check carefully. You can delete this folder if you wish, but doing so won’t actually prevent Microsoft from downloading the setup program again. Once the OS has decided that you’re going to install Windows 10, it’s downright pushy about having the data locally. The only solution, according to various sources, is to actually remove a specific Windows Update: KB3035583.

Described by Microsoft as installing “the Get Windows 10 app, which helps users understand their Windows 10 upgrade options and device readiness.” It can be uninstalled by navigating to Windows Update from within the Control Panel, choosing “Programs and Features,” and then selecting the “View Installed Updates” option. Remove this update and then delete the folder, and you’ll reclaim your lost disk space.

KB 3035583 can then be blocked from installing again by hiding the update from within the Windows Update setting in Control Panel.

A 6GB OS download isn’t a big deal if you have a 500GB drive, but if you’re running an older Windows installation on a 128-256GB SSD, that can wind up being a significant chunk of space.

How to install and update Drivers

Windows Update is the starting point to resolve most common driver issues you experience after installing Windows 10.

Simply launch it from Start > Settings > Update and Recovery and click Check for Updates
If your driver was not detected or installed by Windows Update, you can try installing the driver manually if you have a compatible version. Windows 10 and previous versions of Windows such as Windows 7 share the same driver model, so it should work.

Click Device Manager
Once device manager is open, select the device, right click it and click Update Driver Software
If both Windows Update and driver update prove unsuccessful, the next option is Troubleshoot Compatibility. Troubleshoot Compatibility provides a simple way to make older drivers work under modern versions of Windows by making the driver believe it is being installed on a supported version of Windows.

The first thing you need to do is point where the setup files are located. If you are installing from a thumb drive or CD/DVD. Launch File Explorer (Windows key + E) and open the location where the setup files are stored.

Right click the setup file for the program, this can be designated as setup.exe or something similar. Click Troubleshoot Compatibility

Delete Window.old folder

If you use the upgrade option you are left with a windows.old folder of useless files as windows keeps a copy of your old version in case you want to revert.
Type free up disk space in the windows search box
Click the shortcut for free up disk space
Click Clean up System Files
Check Previews Windows Installations in the files to delete checkbox
Also - make sure you delete the RetailDemo offline content to free up 100mb of disk space.

Recovery Partition

Search for Computer Management or Disk Management to access the control panel
click on the disk - in this case 83gb were unallocated! so we converted it to a simple volume. We wanted to move our data to there - as data should always be on a seperate drive or partition from the system.  But this is difficult in 10 so we decide to resize the system partition. But there is no unallocated space next to the C: partition as the recovery partition is in the way. You cannot delete a recovery drive in disk management app.

Plug in a usb stick
Search recovery and use the recovery control panel to create a recovery drive
Select the usb stick and click create recovery drive (this formats the stick and copies the system files)
When done, click Delete the Recovery Partition to reclaim the disk space (you will have to reallocate or partition/format it using rthe disk management app)

PROBLEM: - does not offer option to delete the recovery partition.

Moving USERS folder to another drive

The folder is a system folder in 10 and Windows doesn’t support moving users profile folder out of the box. So moving is complex and not recommended.


A simple workaround is to create a new user account for yourself after running the Sysprep to relocate the Users folder, make it an administrator account, then copy your data from the original user account to the new account, and finally delete the original account.

Sunday, September 20, 2015

Install Greenstone Digital Library Software on a Apple Mac running 10.10

Version 10.10 of OSX breaks some things, this post details how to install Greenstone.

1.      Download Greenstone-2.86-MacOS-intel-Leopards.dmg from greenstone.org
(Do not get the LION version, it does not work. It used to be there were two versions, one was dynamic and the other static and the dynamic version was supposed to work on the more recent versions of OSX. Somewhere apple updates to OSX broke that and now the older version works better)
2.      For OSX 10.7 and higher, select System Preferences, click the lock and enter your password and select the Anywhere radio button under the Allow Apps Downloaded From Anywhere option
3.      Double-click the downloaded greenstone.dmg file to mount the disk image
4.      Double-click the greentstone2.86.app to install
5.      Accept all the default settings by clicking NEXT
It installs to /Users/yourusername/greenstone where yourusername is your user name
(IF it puts in usr/local/ edit the text box to be /Users/yourusername/greenstone) It is unknown why this sometimes occurs, there seems to be no constant for this behavior.

6.      When the install is finished click Go, Home and your user folder is displayed

7.      Click on the Greenstone folder and Double-Click the gli.app icon to run the Librarian Interface and you should see this error:

What this means is that the GLI relies on the ImageMagick library to process images but that it cannot seen to locate it or that the version it installed is not working. We don't know what causes this but we do have a workaround.

Replace ImageMagick

Navigate to Users/yourusername/Greenstone/bin/darwin and drag the imagemagick folder to the trash. This removes the version installed with Greenstone.


Download Imagemagick from http://cactuslab.com/imagemagick/by selecting the first download option:



Once the file is downloaded double-click the ImageMagick installer pkg file  and install ImageMagick. Do not change the defaults and it will install to /opt

Edit Greenstone Prefs

Navigate to the Greenstone/gli folder
Right-click on gli.sh and choose Open With TextEdit
Insert this text on line 108 (after fi and before # --- check that the GLI has been compiled ----)

export MAGICK_HOME="/opt/ImageMagick"

Then save the file. 


The GLI will now run and process image files. You can tick the checkbox to turn off the imagemagick warning message when the gli loads.

TESTED on OSX 10.10.3 and 10.10.5


Wednesday, September 16, 2015

Install of MAMP and OMEKA on OS X 10.10.5

MAMP for OS X downloaded from  https://www.mamp.info/en/downloads/ which has the documentation here:

https://documentation.mamp.info/en/documentation/mamp/

We are testing this as we have used it before and we had php errors with the xampp bitnami version on OS X.


  1. Download the pkg file and double-click to run the installer which installs to the Applications folder.
  2. We customize the install to de-select the mamp pro option
  3. Once installation is complete we copy the omega folder into Applications/MAMP/htdocs
  4. Now we double-click the MAMP app which loads the control panel
  5. Click Start Servers


Setup Omeka Database

The MAMP install runs a web browser and goes to http://localhost:8888 which means the web server is running on a non-standard port.

Click on Tools, phpMyadmin
Enter omega_db as the database name with a UTF8 unicode collation and click Create
Every database needs a user so we have to create one for the Omeka app (so it can be installed) and this will user account can be used by the app to create additional users inside the application. 
Note: The Linux instructions from Omeka use the mysqladmin client to set up the database.

  1. Click the SQL tab
  2. Enter the following SQL statements:

    insert into user(host, user, password)
    values('localhost','omeka_user',password('zx8180'));

    insert into db(host,db,user,Select_priv, Insert_priv, Update_priv, Delete_priv, Create_priv, Drop_priv)
    values ('localhost','omeka_db','omeka_user','Y','Y','Y','Y','Y','Y');
  3. Click GO to execute the SQL

Set Privileges

We issue this sql, which is a quick hack instead of setting up them the right way...

use mysql;
grant all privileges on omeka_db 
to 'omeka_user'@'%' identified by 'zx8180';

What is odd is when we browse the records in the user table we still don't see the correct privs associated with the omega_user account either from localhost or from the network.


Perhaps the problem with xampp was the lack of privileges, the php install script may have failed because of this. So we edit the localhost omega_user row and change the N's to Y's and then refresh the database.

Configure Apache Web Server

  1. Navigate to Applications/mamp/apache/
  2. Right-click http.conf and open in a text editor 
  3. Change the default setting in the  to be:

    AllowOverride All
    Allow from all
    Order allow,deny

Now save the file.

Set Omeka Database Configuration

This ini file is used by the app to find its database so it must match exactly what you set up in mySQL.

  1. Navigate to Applications/mamp/htdocs/omeka/
  2. Right-click on db.ini and edit with a text editor 
  3. Add the exact values for the database that you set up earlier and add port 8888 (although since apache conf looks there it is like you can leave it alone

[database]
host     = "localhost"
username = "omeka_user"
password = "zx8180"
dbname   = "omeka_db"
prefix   = "omeka_"
charset  = "utf8"
port     = "8888"

Select file,save and save the file.

Run the Omeka Installer

To install an 'amp' app, you go to its install web page, which usually runs some php scripts.

Run a web browser and go to http://localhost/omeka/install

OK same php database error message we got with xampp. 

Let's take a look at the folder permissions. snickers has read/write access to applications/mamp/htdocs/omeka but the rest are read only. Lets change that to read/write.

nope same error as with omega on xampp


php_network_getaddresses: getaddrinfo failed: nodename nor servname provided, or not known

looks like some digging in the omega docs or forums is needed!

UPDATE

Looks like apache mod_rewrite is not enabled on xampp or mamp for OSX. But it must be on xampp for windows as omega installed ok without having to manually configure mod_rewrite.

Todo

- test adding mod_rewite to apache on OS X and rerun the install

UPDATE

Not the problem as the httpd.conf file loads the rewrite module:

LoadModule rewrite_module modules/mod_rewrite.so

Reading the forums reveals problems installing omeka on mamp, particulry with imagemagick. We had solved imagemagick problems in 10.10.x before with greenstone but why go thru this again?  Several posters suggested xampp solves the mamp problems. Problem is the discussion is from 2 years ago. There was also postings of imagemagick problems with the windows install. 

Options 

- retry omeka on XAMPP but i am losing confidence in omeka as a replacement for greenstone. never had any problems installing a 'amp' app before.  

- test out the online free account option to see if a student could do a project there. The downside is they do not get the learning about installing lamp apps and the benefits of amp tech installed locally for learning. Of course having it all online will make it easier for someone to take over the course when i retire...



Install of Omega on OS X

System: Mac Pro
OSX: 10.10.5
Stack: XAMPP 5.6.12-0
Omeka: 2.3.1

Downloaded omeka 2.31 .zip file from the omega web site and unziped to Applications/XAMPP/htdocs/omeka. Htdocs is the root level of the web server.

  1. Next we navigate to /Applications/XAMPP and double-click the manager-osx icon which runs the XAMPP control panel. 
  2. Click the Manage Servers tab and START the mySQL server and START the Apache web server.
  3. Run Safari and go to http://localhost and select the phpMyAdmin link
Set up the Database and User
  1. Click the Databases tab
  2. Enter omeka_db in the create database text box
  3. Select uff8_unicode_ci from the collation pull-down menu
  4. Click CREATE
  5. Select the SQL tab
  6. Enter the following SQL:
use mysql;
insert into user(host, user, password) 
values('localhost','omeka_user',password('zx8180'));

insert into db(host,db,user,Select_priv, Insert_priv, Update_priv, Delete_priv, Create_priv, Drop_priv) 
values ('localhost','omeka_db','omeka_user','Y','Y','Y','Y','Y','Y');


Click GO and then Return to the XAMPP control panel and STOP and then START the mySQL server

Configure Apache

Navigate to Applications/XAMPP/xampfiles/apache2/conf
Right-click on httpd.conf and open in a text editor or textedit if you have to

The default order is:

AllowOverride All
Allow from all
Order allow,deny

So you do not have to change  anything!  Close the file. Next i checked the omeka folder permissions and it seems fine.


Set Omeka Database Configuration

This ini file is used by the app to find its database so it must match exactly what you set up in mySQL.
  1. Navigate to /xampp/xamppfiles/htdocs/omeka/
  2. Right-click on db.ini and edit with a text editor or textedit
  3. Add the exact values for the database that you set up earlier
[database]
host     = "localhost"
username = "omeka_user"
password = "zx8180"
dbname   = "omeka_db"
prefix   = "omeka_"
charset  = "utf8"
port     = ""

Select file,save and save the file.

Note: by leaving the port value empty it uses the default port 80. If you are running on a non-standard port you will want to change this.

So now back to the web browser and phpMyAdmin to install the omeka app.

Install Omeka

Run a web browser and go to http://localhost/omeka/install and the installer php script runs.

we get a php error

php_network_getaddresses: getaddrinfo failed: 
nodename nor servname provided, or not known

This looks like a database connect error. Wonder if this is the same problem we had on windows with the omeka_user not having priviledges?

Back to myPhpAdmin to add privileges, click on the SQL tab and we do:

use mysql;
grant all privileges on omeka_db 
to 'omeka_user'@'%' identified by 'zx8180';

and we restart the mysql server. ok back to the web browser and try the install again:

same error - looks like a problem in the php configuration?  Wondering if this OSX XAMPP which is the bitnami version has issues?  We used vanilla xampp for the windows install - let's backtrack and see if we can do a vanilla xampp for osx.

Todo

Delete existing XAMPP in applications
Download and install new non-bitnami xampp











Tuesday, September 15, 2015

Omeka 2.3.1 install on native Ubuntu 14.04 LTS



 Sources:


 Background:

This documentation details my install procedure of a LAMP stack and Omeka 2.3.1. It does not cover certain steps (like installing Unzip) which are seen in other guides because these packages were already installed on my machine.

There were 5 major steps:
  1.  Set up LAMP stack and ImageMagick
  2.  Download and install Omeka
  3. Set-up web user and permissions
  4. Create and modify database
  5.   Enable mod_rewrite (worst part)

Step 1- Set up LAMP stack and ImageMagick


1.Install PHP5:
sudo apt-get install php5

2.Install PHP-MySQL:
sudo apt-get install php5-mysql

3.Install Apache2:
sudo apt-get install apache2

4.Install MySQL server:
sudo apt-get install mysql-server

5. Install ImageMagick (image software used by Omeka):
sudo apt-get install imagemagick


To test go to your IP
(see image)


Step 2- Download and install Omeka


6. Download Omeka to home directory:
cd

wget http://omeka.org/files/omeka-2.3.1.zip

unzip omeka-2.3.1.zip

7. Move unzipped files to web directory
sudo mv omeka-2.3.1/* /var/www/

sudo mv omeka-2.3.1/.htaccess /var/www/

8. If there is an old index.html file in www remove it:
sudo rm /var/www/index.html



Step 3- Set up web user and permissions


9. Create a web group and user:
sudo groupadd webdev

sudo usermod -a -G webdev your_ubuntu_username

cd /var

sudo chown -R root.webdev www 

10. Give the newly created user permissions to directories needed:
sudo chmod 775 www

cd /var/www 

sudo find . -type d | xargs sudo chmod 775

sudo find . -type f | xargs sudo chmod 664

sudo find files -type d | xargs sudo chmod 777

sudo find files -type f | xargs sudo chmod 666



Step 4- Create and modify database


11. Open MySQL from appropriate location
mysql -u root -p

12. Create the database (keep ‘’ punctuation)
create database omeka;

grant all privileges on omeka.* to 'username from step 9'@'localhost'     identified by 'insertpasswordhere';

flush privileges;

quit;

13. Open db.ini in terminal to modify
sudo nano /var/www/db.ini

14.  Adjust values to reflect newly created settings from step 12 and save file.
[database]

host = "localhost"

username = "username"

password = "password"

dbname = "omeka"

prefix = "omeka_"



Step 5- Enable mod_rewrite in for Apache


15. Enable mod_rewrite and restart the server:
sudo a2enmod rewrite

sudo service apache2 restart

16. Open apache2.conf file in gedit (easier to see than if in nano)
sudo gedit /etc/apache2/apache2.conf 

17. Modify apache2.conf (append to the end of the file), then save and close
ServerName localhost

# Enable mod_rewrite

<IfModule mod_rewrite.c>

RewriteEngine On

</IfModule>

18. Open 000-default.conf file in gedit
sudo gedit /etc/apache2/sites-available/000-default.conf 

17. Modify 000-default.conf (append below line DocumentRoot /var/www), then save and close
<Directory ”/var/www/html”>

AllowOverride All

</Directory>

18. Restart server
sudo service apache2 restart


To test: localhost/admin/users/login/

If you see the following, you know you have a problem (check out the support forums)
Different people have solved it different ways, depending on their system:













If you see the following, you know you have succeeded:


Thursday, September 10, 2015

Install of Omeka on XAMPP

OS: Windows 7 x64
XAMPP: v 3.2.1
Omeka: v 2.3.1

The instructions for Omeka install assume a linux server but we are installing on a windows machine using XAMPP so the install is somewhat different but similar to all 'amp' applications.

Get Omeka

We download the latest version from http://omeka.org/download/. The release notes are here. We unzip the omeka-2.3.1 archive to an omeka folder at the root level of the XAMPP web server which is located at /xampp/htdocs

You have to be careful - windows native unarchiving tends to create a folder inside a folder, you need to have an omeka folder under htdocs containing the files. (7zip is a better option).


Create Omeka Database

All 'amp' apps store data in a database. So we need to create a mySQL database for omeka. This can be done using a mySQL client to connect to the mySQL server, or thru a web app like phpMyAdmin.

  1. Navigate to /xampp/xampp-control.exe and double-click to run the control panel
  2. Start the mySQL database server and the Apache web server
  3. Click on the phpMyAdmin link
  4. Click the Databases Tab
  5. Create an omeka_db database with collation of utf8_unicode_ci

NOTE: we originally named the database omeka but we noticed the Omeka documentation refers to it as omeka_db (we feel the db is redundant but...) so we redid is as omeka_db and we recommend you do as well. This database will be used by the Omeka app.

Create Omeka User

Every database needs a user so we have to create one for the Omeka app (so it can be installed) and this will user account can be used by the app to create additional users inside the application.
Note: The Linux instructions from Omeka use the mysqladmin client to set up the database.

  1. Click the SQL tab
  2. Enter the following SQL statements:

    insert into user(host, user, password)
    values('localhost','omeka_user',password('zx8180'));

    insert into db(host,db,user,Select_priv, Insert_priv, Update_priv, Delete_priv, Create_priv, Drop_priv)
    values ('localhost','omeka_db','omeka_user','Y','Y','Y','Y','Y','Y');
  3. Click GO to execute the SQL


One thing i noted about this statement is the omeka user sql does not set up privileges for connecting. By default it should be able to connect only from localhost. Normally when setting up users who have to have access from all locations we would do something like:

use mysql;
grant all privileges on omeka_db 
to 'omeka_user'@'%' identified by 'zx8180';

And when setting up a user you want to refresh/reload the database so the client picks up the changes. The easiest way to do this in XAMPP would be to STOP and then START the mySQL server. We forgot to do this step which may be the reason for the problem noted later on....

Configure Apache Web Server

  1. Navigate to /xampp/apache/conf/
  2. Right-click http.conf and open in a text editor or use notepad if you must
  3. Change the default setting in lines 222-229 to be:


    AllowOverride All
    Allow from all
    Order allow,deny

Now save the file.

Note: the ServerRoot directive is hard-coded, for example: ServerRoot "I:/xampp/apache" so this would have to be changed if later you copy the xampp folder from current drive to another
location. Also hard coded is DocumentRoot.

Set File Permissions

The Linux instructions note that the apache user must have rights to the omeka folder. This is because many linux apps create a user account in the OS that has rights only to specific items or functions, a much more secure approach than Windows with its administrator account.

  1. Navigate to  /xampp/htdocs
  2. Right-click on the omeka folder
  3. I set the properties not to be read-only

Not sure this step is even required...

Set Omeka Database Configuration

This ini file is used by the app to find its database so it must match exactly what you set up in mySQL.

  1. Navigate to /xampp/htdocs/omeka/
  2. Right-click on db.ini and edit with a text editor or notepad
  3. Add the exact values for the database that you set up earlier

[database]
host     = "localhost"
username = "omeka_user"
password = "zx8180"
dbname   = "omeka_db"
prefix   = "omeka_"
charset  = "utf8"
port     = ""

Select file,save and save the file.

Note: by leaving the port value empty it uses the default port 80. If you are running on a non-standard port you will want to change this.

Run the Omeka Installer

To install an 'amp' app, you go to its install web page, which usually runs some php scripts.

Run a web browser and go to http://localhost/omeka/install

The first time i did this i got the mySQL error message:

"Access denied for user 'omeka_user'@'localhost' (using password: YES)"

It may be that because i did not refresh the database tables?  The error message indicates that user does not have privileges to the database from localhost. We could go back to SQL and issue a statement like this:

use mysql;
grant all privileges on omeka_db 
to 'omeka_user'@'%' identified by 'zx8180';

but we can also use phpMyAdmin. 
  1. Go back to phpmyadmin 
  2. Click the users tab and slect the omeka_user@localhost entry
  3. CHECK ALL and click GO
Normally you would not do this! But we are lazy. The privileges needed by omeka_user are not extensive.


We need to research this - when we install on OSX we can do it a little differently.
  1. Use the xampp control panel to STOP and then START the mySQL server
  2. Go to http://localhost/omeka/install and you should see the install page
 

Add an admin user and password. The admin account can access the back-end or dashboard of Omeka.

Note: PHP does not have the fileinfo module loaded and thus the installer will
disable file upload validation. Research how to set this up in php before running the installer.

We accept the defaults for most of the setting. Note it asks for the ImageMagick path so we should install that before installing omeka, although we assume we can later edit the Omeka configuration to add the path.

Click INSTALL and if ok the success page is displayed
Navigate to /xampp/htdocs/omeka and delete the install folder


You can now check out the default public site that users see, or log into the back-end as the admin user.




You now have omeka running but is only accessible from localhost, the machine you are on.